Components | All | New | MacOS | Windows | Linux | iOS | ||||
Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old |
DynaPDF.SetTextRect
The function defines the output rectangle that is used to output formatted text by the function DynaPDF.WriteFText.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
DynaPDF | 3.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
MBS( "DynaPDF.SetTextRect"; PDF; PosX; PosY; Width; Height ) More
Parameters
Parameter | Description | Example |
---|---|---|
The PDF reference returned from DynaPDF.New. | ||
PosX | X-Coordinate of output rectangle | $x |
PosY | Y-Coordinate of output rectangle | $y |
Width | Width of output rectangle | $w |
Height | Height of output rectangle or -1. | $h |
Result
Returns OK or error message.
Description
The function defines the output rectangle that is used to output formatted text by the function DynaPDF.WriteFText.See also SetTextRect function in DynaPDF manual.
Examples
Write some text in a rectangle area:
#Add page with some text
Set Variable [$r; Value:MBS("DynaPDF.AppendPage"; $pdf)]
Set Variable [$r; Value:MBS("DynaPDF.SetTextRect"; $pdf; 100; 100; 400; 200)]
Set Variable [$r; Value:MBS("DynaPDF.SetFont"; $pdf; "Times"; 1; 40; 1; "cp1252")]
Set Variable [$r; Value:MBS("DynaPDF.WriteFText"; $pdf; "Center"; "Just a test PDF.")]
Set Variable [$r; Value:MBS("DynaPDF.EndPage"; $pdf)]
See also
- DynaPDF.EndPage
- DynaPDF.GetFTextHeight
- DynaPDF.GetFTextHeightEx
- DynaPDF.GetTextRise
- DynaPDF.GetTextWidth
- DynaPDF.New
- DynaPDF.RotateCoords
- DynaPDF.SetFont
- DynaPDF.SetPageBreakExpression
- DynaPDF.WriteStyledText
Example Databases
- DynaPDF/Add Weblinks
- DynaPDF/Create Text as PDFA
- DynaPDF/Live Styled Text
- DynaPDF/Multi Column Output
- DynaPDF/Place Picture
- DynaPDF/Styled Text
- DynaPDF/Watermark pages
- DynaPDF/WriteFText
- DynaPDF/ZUGFeRD/ZUGFeRD Invoice
- DynaPDF/ZUGFeRD 2.0/ZUGFeRD 2.0 Invoice
Blog Entries
This function checks for a license.
Created 18th August 2014, last changed 27th May 2017
