1 person found this helpful
Are you sure?
A plugin is not an option, as the thing is intended to run out-of-the-box on every reader above version 9. I was hoping there was at least some kind of "page-refresh" or "page-redraw"-event I could catch. So there is nothing to check when a change occurrs in the zoomfactor (except for the obvious timer - which I consider a rather dirty workaround)?
Maybe I should actually report this text-issue as an acrobat-bug and use a timer in the meantime.
Thanx for the advice anyhow.
Here's a list of events that you can attach code to: http://livedocs.adobe.com/acrobat_sdk/9.1/Acrobat9_1_HTMLHelp/JS_API_AcroJS.88.565.html
I agree the timer idea is less than ideal, but it's all you've got to work with.
This page is exactly what I found after digging into the documentation, and I checked all the events, but found none to suit my needs. However I hoped for some secret acrobat knowledge ^^.
Well, I got the timer working and it does the job for now. In case someone is interested, what I did was (in the document-script):
var lastZoom = this.zoom;
lastZoom = this.zoom;
var zoomChecker = app.setInterval('checkZoom()',500);"
As you're talking about reflowing SWF content rather than PDF pages, you can simply add a listener in your ActionScript for the stage resize event.
That would indeed be a more elegant solution. I have tested adding (in my flash-AS-class)
private function test(e:Event)
But it doesn't work in Acrobat (in the Flash-player it does!) It seems the event isn't triggered by zoom-actions in acrobat.
Yes it works, but you'll need to make sure your stage scaling mode is set correctly
stage.scaleMode = flash.display.StageScaleMode.NO_SCALE;
You then deal with the resizing of your content within the event handler. Using the other modes (SHOW_ALL, NO_BORDER, EXACT_FIT) the stage is never resized as far as the timeline is concerned, rather the Player engine adapts it to suit.
I see. Thanx for the tip!
The event-handler does work now, but I run into a new problem: my flash-annotation is now excluded from the zoom. By "deal with the resizing of your content within the event handler" do you mean I should counteract this by running through all elements on my stage and adjusting the size according to the new stage-size?
P.s.: I just checked and in ReaderX the RMA is not shown at all now! I didn't notice yet, as I still do most of the work with 9ProExtended (I have access to AcrobatX, but only very limited - I have to use a colleagues' workstation to do so).
Message was edited by: ForrestGimp
OK, so for my case I have returned to the simple-and-dirty solution.
If you want to view the results (and some more of the cool stuff we made) you can check them out on http://www.docunamic.de/referenzen/
The page is only available in german for now, but downloading should be possible anyhow . There's quite a few examples for video-, flash- and 3D-PDFs. Enjoy!
P.S. Feel free to post any comments!
1 person found this helpful
Yes, if the SWF is using NO_SCALE it's up to you to reposition or scale the elements on the stage, by reacting to the stage resize events. You could simply scale the entire lot, or reposition them individually.
Rich Media annotations will work the same in Acrobat and Reader 9 and X, so if yours is not displaying properly in Reader X there is a problem with the document. Which file is it on your website?
You're right, there was a problem with the file.... I can't recall what it was, or how I fixed it, but it was just a minor issue. Anyway, it is the file you can download under http://www.docunamic.de/files/9912/9847/9610/docunamic_video_pdf_seeberger.pdf that originally gave me trouble. When switching languages it worked just fine, but once I started zooming the PDF parts of the text sometimes disappeared like described above.The version you can download has the fix applied, but if necessary I can provide a simplified version to illustrate the problem.
It seems like the Zoomfactor of the PDF is not consistently applied to the scaling of flash-text. That's the basic issue.