XFRX version 12.6

Release date: 01 August 2008

New features / Updates

  • Full justification is now supported in PDF, Word output, picture export and the XFRX previewer
    Add <FJ> into the comments of the fields you want to full justify.
  • Absolute layout boxes in Word output are now automatically expandable
  • Picture rotation is now supported in VFP 9.0, using the new SP2 designer user interface
  • XFRX Previewer
    • Hyperlink decoration can now be suppressed on the printer output
      A new property has been added to the XFCont, cntXFRXMultipage and frmMPPreviewer classes: UnderlineHyperlinksOnPrint. You can use the following values:
        0 - no decoration for hyperlinks
        1 - display "normal" hyperlinks in blue, but do not decorate custom event hyperlinks (green)
        2 - (default value) decorate both blue and green hyperlinks

      To support this, the PrintDocument method of the XFRX#DRAW class has a new parameter, tnUnderlineHyperlinksOnPrint, with the same values and logic.
    • Custom buttons can now be added to the XFRX previewer toolbar at runtime
      This feature is implemented using the extension handler mechanism: A new method is now supported - ToolbarOnInit, which is invoked at the time the toolbar is initialized. In this method the extension handler can add new buttons to the previewer and their click events can be bound with other methods in the extension handler. A new property is now supported, too - oPreviewContainer. If it is available, the previewer will automatically fill it with the XFCont object reference for easier access to the previewer properties in the custom buttons click event methods.

      Example:

      
      
      use demoreps\sales
      local loSession, lnRetval, loXFF, loPreview, loScripts
      loSession=EVALUATE([xfrx("XFRX#LISTENER")])
      lnRetVal = loSession.SetParams(,,,,,,"XFF") && no name = just in memory
      If lnRetVal = 0
      	REPORT FORM demoreps\sales object loSession
      	*
      	* the XFRX#DRAW object reference is stored in oxfDocument property
      	*
      	loXFF = loSession.oxfDocument
      	*
      	* initialize the previewer 
      	*
      	SET PATH TO xfrxlib
      	SET CLASSLIB TO xfrxlib ADDITIVE 
      	loPreview = CREATEOBJECT("frmMPPreviewer")
      	*
      	* setup the extension handler
      	*
      	loPreview.oExtensionHandler = CREATEOBJECT("SampleExtensionHandler")
      	loPreview.windowtype = 1 
      	loPreview.iTool = 2 && embedded toolbar
      *	loPreview.iTool = 1 && standard toolbar
      	loPreview.PreviewXFF(loXFF)
      	loPreview.show(1)
      ENDIF
      
      DEFINE CLASS SampleExtensionHandler as Custom
      
      	oPreviewContainer = null
      
      	PROCEDURE ToolbarOnInit
      	LPARAMETERS toToolbar
      	LOCAL button
      	IF toToolbar.AddObject("mybutton", "commandbutton")
      		BINDEVENT(toToolbar.mybutton, "click" , this, "ButtonClicked")		
      		toToolbar.mybutton.tabindex = 1
      		toToolbar.mybutton.Visible = .t.
      		IF UPPER(totoolbar.BaseClass)!="TOOLBAR"
      			toToolbar.mybutton.left = toToolbar.cmdQuit.left
      			toToolbar.cmdQuit.left = toToolbar.mybutton.left + toToolbar.mybutton.width
      		ENDIF		
      	endif
      
      	PROCEDURE ButtonClicked
      	LOCAL lcString
      	lcString = "this.oPreviewContainer.Name: "+this.oPreviewContainer.Name+CHR(13)
      	lcString = lcString + "current page: "+TRANSFORM(this.oPreviewContainer.nPageNo)+CHR(13)
      	lcString = lcString + "XFRX#DRAW Object: "+this.oPreviewContainer.oXFRXWriter.Name+CHR(13)
      	lcString = lcString + "Page count: "+TRANSFORM(this.oPreviewContainer.oXFRXWriter.PageCount)+CHR(13)
      	WAIT WINDOW lcString
      *	
      *	this.oPreviewContainer.oXFRXWriter.PrintDocument(...)
      *	this.oPreviewContainer.oXFRXWriter.SavePicture(...)
      ENDDEFINE
                              

Bugs fixed

  • "SET NULL ON" problem has been fixed
  • A problem with previewer crashing on Windows Vista has been fixed
  • Dynamic background is now supported in VFP 9