Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 9 Current »

There are five types of effects: real size, fit to paper, normal size, change paper and fit to paper and change.

Real size
 The size of the content does not change

Fit to paper 
 The content will be resized to fit the new paper size.

Normal size 
 The size of the content will be adjusted according to the selected scale in percentage. Subsequently, the new position of the content on the page can be determined.

Change paper
 Sets the paper size, you can also specify a new paper orientation. Subsequently, the new position of the content on the page can be determined.

Fit to paper and change
 Combine "Fit To Paper" and "Change paper".

For simpler settings, you can use the appropriate methods described below.

Print and export has separate effect settings.

The effect parameter object

Methods:

NameDescriptionXFRX
version
SetRealSize

This method set real size.

22.0
SetFitToPaper

This method set color.

Parameters:

m.liPaperIndexFit – Paper size index with content size adjustment.

22.0
SetNormalSize

This method set font.

Parameters:

m.lnSize – new contents's size in percent

m.lcRelativePos – define new position of content, values can be: "left", "center", "right", "top", "middle", "bottom" or their combination sepparated by comma.


22.0
SetChangePaper

This method set horizontal and vertical aligment.

Parameters:

m.liPaperIndexChange – Paper size index for paper's change.

m.luOrientaion  – orientation;   values: "portrait" (0), "landscape" (1), "reverse" (2), "nochange" (3)

m.lcRelativePos – define new position of content, values can be: "left", "center", "right", "top", "middle", "bottom" or their combination sepparated by comma.

22.0
SetFindAndChange

This method set text orientation.

Parameters:

m.liPaperIndexFit – Paper size index with content size adjustment.

m.liPaperIndexChange – Paper size index for paper's change.

m.luOrientaion  – orientation;   values: "portrait" (0), "landscape" (1), "reverse" (2), "nochange" (3)

m.lcRelativePos – define new position of content, values can be: "left", "center", "right", "top", "middle", "bottom" or their combination sepparated by comma.

22.0

Properties:

NameType DescriptionXFRX
version
iHAlignnumberHorizontal alignment. Values are: 0 - left,  1 - center, 2 - right.22.0
iVAlignnumberVertical alignment. Values are:  0 - top, 1 - middle, 2 - bottom.22.0
iOrientationnumberPaper orientation. Values are: 0 - portrait, 1 - landscape, 2 - reverse, 3 - nochange22.0
iPaperIndexChangenumberPaper size index for paper's change.22.0
iPaperIndexFitnumber

Paper size index with content size adjustment.

22.0
lAutoSizebooleanAuto size flag. If value is true, then content will be calculated by page size.22.0
nSizenumberNew content size in percents.22.0
lShowPreviewnumberShow preview of effect.22.0
iTypenumberType effect: 0 - real size, 1 - fit to paper, 2 - normal size, 3 - change paper, 4 - fit and change paper22.0

Effect examples

USE invoices 
ORDER customer 
LOCAL m.loSession, m.lnRetval, m.loXFF, m.loPreview, m.loScripts 
m.loSession=EVALUATE([xfrx("XFRX#LISTENER")]) 
m.lnRetVal = m.loSession.SetParams("",,,,,,"XFF") && no name = just in memory 
IF m.lnRetVal = 0 
   REPORT FORM invoices OBJECT m.loSession 
   m.loXFF = m.loSession.oxfDocument 
   * 
   * initialize the previewer 
   * SET CLASSLIB TO xfrxlib ADDITIVE 
   m.loPreview = CREATEOBJECT("frmMPPreviewer") 
   m.loPreview.windowType = 0 
   m.loPreview.iBook = 0 

   WITH loPreview.oExportOptions
   .oEffect.lShowPreview=.T.
   .oEffect.SetFitToPaper(11) && fit to paper to A5
   ENDWITH

   m.loPreview.PreviewXFF(loXFF) 
   m.loPreview.show(1) 

ENDIF 

  • No labels