Parameters
The following parameters can be used in FlexPaper
| SwfFile (String) | The document FlexPaper should open | |
| Scale (Number) | The initial zoom factor that should be used. Should be a number above 0 (1=100%) | |
| ZoomTransition (String) | The zoom transition that should be used when zooming in FlexPaper. It uses the same Transition modes as the Tweener. The default value is easeOut. Some examples: easenone, easeout, linear, easeoutquad | |
| ZoomTime (Number) | The time it should take for the zoom to reach the new zoom factor. Should be 0 or greater. | |
| ZoomInterval (Number) | The interval which the zoom slider should be using. Basically how big the "step" should be between each zoom factor. The default value is 0.1. Should be a positive number. | |
| FitPageOnLoad (Boolean) | Fits the page on initial load. Same effect as using the fit-page button in the toolbar. | |
| FitWidthOnLoad (Boolean) | Fits the width on initial load. Same effect as using the fit-width button in the toolbar. | |
| localeChain (String) | Sets the locale (language) to use. The following languages are currently supported:
en_US (English) fr_FR (French) zh_CN (Chinese, Simple) es_ES (Spanish) pt_BR (Brazilian Portugese) ru_RU (Russian) fi_FN (Finnish) de_DE (German) nl_NL (Netherlands) tr_TR (Turkish) se_SE (Swedish) pt_PT (Portugese) el_EL (Greek) da_DN (Danish) cz_CS (Czech) it_IT (Italian) pl_PL (Polish) pv_FN (Finnish) hu_HU (Hungarian) |
|
| FullScreenAsMaxWindow (Boolean) | With this set to true, clicking on fullscreen will open a new browser window with FlexPaper maximized instead of using true fullscreen. This is a preferred setting when using FlexPaper as flash standalone as the security limitations of the Flash player disables (for security reasons) most of the input controls in true fullscreen. | |
| ProgressiveLoading (Boolean) | Will load and display the document progressively when set to true as opposed to downloading the complete document before displaying the pages. Documents need to be converted to at least Flash version 9 for this to work (-T 9 flag using PDF2SWF) | |
| MaxZoomSize (Number) | Sets the maximum allowed zoom level | |
| MinZoomSize (Number) | Sets the minimum allowed zoom level | |
| SearchMatchAll (Boolean) | When set to true, the viewer highlights all matches when performing searches in a document. | |
| InitViewMode (String) | Sets the start-up view mode. For example "Portrait" or "TwoPage". | |
| ViewModeToolsVisible (Boolean) | Shows or hides view modes from the tool bar | |
| ZoomToolsVisible (Boolean) | Shows or hides zoom tools from the tool bar | |
| NavToolsVisible (Boolean) | Shows or hides nav tools from the tool bar | |
| CursorToolsVisible (Boolean) | Shows or hides cursor tools from the tool bar | |
| SearchToolsVisible (Boolean) | Shows or hides search tools from the tool bar |
The parameters are passed using flashvars or by setting properties on the flexpaper component inside flex, depending on your choice of usage. The code block below shows an example of how the parameters can be passed using the pre-compiled flash version
var fp = new FlexPaperViewer(
'FlexPaperViewer',
'viewerPlaceHolder', { config : {
SwfFile : "Paper.swf",
Scale : 0.6,
ZoomTransition : "easeOut",
ZoomTime : 0.5,
ZoomInterval : 0.1,
FitPageOnLoad : false,
FitWidthOnLoad : false,
FullScreenAsMaxWindow : true,
ProgressiveLoading : true,
MinZoomSize : 0.2,
MaxZoomSize : 5,
SearchMatchAll : false,
InitViewMode : 'Portrait',
ViewModeToolsVisible : true,
ZoomToolsVisible : true,
NavToolsVisible : true,
CursorToolsVisible : true,
SearchToolsVisible : true,
localeChain : "en_US"
}});
