Menu

Using FoxyPreviewer v3.00

THIS PAGE IS WORK IN PROGRESS - TO BE UPDATED


FoxyPreviewer 3.0 is 100% compatible with the previous versions, but still needs some testings. By default the behavior of the new version will produce no enhancement to v2.99.

To see the enhancements you'll need to update some properties as you will see below:


1 - The most waited feature was a "Fix" for VFP9 reports that made the report preview and Print truncated on the right side when the Screen Resolution scaling is set to higher than 125%

In FoxyPreviewer 3.00 the trick is to set the new RenderMode property to 2, like below:


DO FOXYPREVIEWER.APP  && Only once at system startup 
_Screen.oFoxyPreviewer.nRenderMode = 2 && High DPI Friendly
REPORT FORM (_SAMPLES + "Solution\Reports\Colors.frx") PREVIEW


Below you can see the report truncated and then the same showing perfectly after the property is set.





2 - The Printing Preferences window brings several printing options, just like all other applications do:



3 - PDF rendering

A very significant enhancement was made in the original PDF rendering. You will notice that the default PDF generation by HARU Free PDF library is now almost 3 times faster!

Apart from that, a new PDF render mode was introduced, allowing us to use the Win10 new features to generate our PDFs. The new "PdfType" property allows us to generate PDF documents even faster, with the advantage of creating output files almost exactly the same as the original report. The only downside is that these new PDFs will be bigger than the previous generated by Haru.

You can try:

DO FOXYPREVIEWER.APP  && Only once at system startup 
_Screen.oFoxyPreviewer.nPdfType = 2 && 1=Default(Haru) 2=Using Win10  3=Custom render
REPORT FORM (_SAMPLES + "Solution\Reports\Wrapping.frx") PREVIEW


4 - Toolbar appearance

You can always change your button images by setting some basic properties, as previously documented. In version 3.00 we can go further, using any true type font, just like Windows 10, using the SEGOE MDL2 ASSETS font:

New buttons using SEGOE MDL2 ASSETS icons, the ones used by WIN10



You can customize the toolbar, using any icon, from any available font, selecting the main, mouse over and disabled color




DO FOXYPREVIEWER.APP  && Only once at system startup 

_Screen.oFoxyPreviewer.nButtonSize = 2 && 1=Default 16x16 ; 2=Big 32x32
_Screen.oFoxyPreviewer.nButtonStyle = 2 && 0=Default images; 1=Font buttons 2=Font buttons, white backgrounds

REPORT FORM (_SAMPLES + "Solution\Reports\Wrapping.frx") PREVIEW
Using nButtonStyle = 1

Using nButtonStyle = 2

You can also define a specific color when the mouse is over a button and the disabled colors:



DO FOXYPREVIEWER.APP  && Only once at system startup 

_Screen.oFoxyPreviewer.nButtonSize = 2 && 1=Default 16x16 ; 2=Big 32x32
_Screen.oFoxyPreviewer.nButtonStyle   = 1 && 0=Default images; 1=Font buttons 2=Font buttons, white backgrounds

_Screen.oFoxyPreviewer.nButtonForeColor      = RGB(60,60,60)    && Dark grey
_Screen.oFoxyPreviewer.nButtonMouseOverColor = RGB(0,128,192)   && Blue
_Screen.oFoxyPreviewer.nButtonDisabledColor  = RGB(200,200,200) && Light grey

REPORT FORM (_SAMPLES + "Solution\Reports\Wrapping.frx") PREVIEW


What about choosing other buttons, from other fonts?
No problem at all!

DO FOXYPREVIEWER.APP  && Only once at system startup 

_Screen.oFoxyPreviewer.nButtonStyle = 1
_Screen.oFoxyPreviewer.nButtonSize = 2

_Screen.oFoxyPreviewer.cImgFirst        = "<UC>E96F</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgFirstBig     = "<UC>E96F</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgLast         = "<UC>E970</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgLastBig      = "<UC>E970</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgPrev         = "<UC>E76B</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgPrevBig      = "<UC>E76B</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgNext         = "<UC>E76c</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgNextBig      = "<UC>E76C</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgGotoPg       = "<UC>E7C3</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgGotoPgBig    = "<UC>E7C3</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgSave         = "<UC>E105</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgSaveBig      = "<UC>E105</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgEmail        = "<UC>E119</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgEmailBig     = "<UC>E119</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgPrint        = "<UC>E2F6</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgPrintBig     = "<UC>E2F6</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgPrintPref    = "<UC>f56d</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgPrintPrefBig = "<UC>f56d</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgSetup        = "<UC>E115</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgSetupBig     = "<UC>E115</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgMiniatures    = "<UC>E7C5</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgMiniaturesBig = "<UC>E7C5</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgSearch    = "<UC>e721</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgSearchBig = "<UC>e721</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgClose     = "<UC>f3b1</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgCloseBig  = "<UC>f3b1</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.cImgClose2    = "<UC>ef2c</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"
_Screen.oFoxyPreviewer.cImgClose2Big = "<UC>ef2c</UC><FONTNAME>SEGOE MDL2 ASSETS</FONTNAME>"

_Screen.oFoxyPreviewer.nButtonSpecialEffect = 1 && 0-3d, 1-Plain, 2-Hot tracking

REPORT FORM (_SAMPLES + "Solution\Reports\Wrapping.frx") PREVIEW



Your users can also change interactively almost all behaviors, by using the settings form directly from the preview:



5 - Using a scrollable container as the preview form, withe the toolbar frozen at the top, like all other modern previewers, using the "nPreviewMode" property:


DO FOXYPREVIEWER.APP  && Only once at system startup 
_Screen.oFoxyPreviewer.nPreviewMode = 2 && 1=Toolbar; 2=Scrollable container
REPORT FORM (_SAMPLES + "Solution\Reports\Colors.frx") PREVIEW


6 - Generating outputs without previewing

FoxyPreviewer 3 definitely retires the "OBJECT TYPE" modes.

Now you can simply use the "TO FILE" clause, and FP will use the file extension to determine automatically what report listener will be internally run.

You can still use the "TO FILE ....... PREVIEW" to have an alternative previewer. For instance, if ADOBE READER (R) is your default PDF viewer, your report will be shown automatically in it.

REPORT FORM (_SAMPLES + "Solution\Reports\Colors.frx") TO FILE "123.pdf" PREVIEW
REPORT FORM (_SAMPLES + "Solution\Reports\Colors.frx") TO FILE "123.xls" PREVIEW
REPORT FORM (_SAMPLES + "Solution\Reports\Colors.frx") TO FILE "123.htm" PREVIEW
REPORT FORM (_SAMPLES + "Solution\Reports\Colors.frx") TO FILE "123.doc" PREVIEW
REPORT FORM (_SAMPLES + "Solution\Reports\Colors.frx") TO FILE "123.txt" PREVIEW


7 - Sharing your PDF reports with other Apps. This has never been so simple! Just click on the "Share" button in the preview, and drop your file to your WhatsApp, Telegram or even a Windows folder!

FP3 activates this button by default. If you wish to cancel this feature, just set one property:

_Screen.oFoxyPreviewer.lShowShareBtn = .F. && Shows or hides the Share btn



8 - User Control

You can start FoxyPreviewer3 at any desired folder. This will allow you to have your specific user files at the desired location. Here are some options for you to tart FoxyPreviewer:


Option 1:
DO FOXYPREVIEWER WITH "RELEASE"
DO FOXYPREVIEWER WITH "CLEAN"
DO FOXYPREVIEWER WITH "d:\Users\John" && Path
DO FOXYPREVIEWER WITH "CLEAN", "d:\Users\John" && Path
DO FOXYPREVIEWER WITH "CLEAN", "d:\Users\John", "John" && Path and User - 3 parameters


Option 2:
* Using tags for all possibilities, with room for new options in the future
DO FOXYPREVIEWER.APP WITH "<CLEAN/><PATH>d:\Users\Steve</Path><USER>Steve</USER>"


      The currently available parameters are:

      Release - To release FoxyPreviewer completely, clearing memory, and restoring to the original printing environment
      Clean - A faster initialization, loading only the needed ReportListeners for all the outputs. The good and old "OBJECT TYPE" mode will not be available, but "REPORT FORM YourReport.Frx TO FILE xxxxxx.pdf" will do the same job. Recommended setting. It was not set as default to keep backwards compatibility.
      Path - The path where the file "FoxyPreviewer_Settings.dbf" will be stored
      User - New parameter, to allow having different "FoxyPreviewer_Settings.dbf" available in the same folder, for instance: we can have the files: FoxyPreviewer_Settings_John.dbf and FoxyPreviewer_Settings_Chris in the same folder. One for each user, at the same location, or wherever you like.
      Reset - Resets the current Settings table for the current user. This file can also be deleted - FP will recreate it on the next run.




THIS PAGE IS WORK IN PROGRESS - TO BE UPDATED