TCPDF::Write( $h, $txt, $link = '', $fill = false, $align = '', $ln = false, $stretch, $firstline = false, $firstblock = false, $maxh, $wadj, $margin = '' )
This method prints text from the current position.
Description Description
Parameters Parameters
- $h
-
(Required) (float) Line height
- $txt
-
(Required) (string) String to print
- $link
-
(Optional) (mixed) URL or identifier returned by AddLink()
Default value: ''
- $fill
-
(Optional) (boolean) Indicates if the cell background must be painted (true) or transparent (false).
Default value: false
- $align
-
(Optional) (string) Allows to center or align the text. Possible values are:<ul><li>L or empty string: left align (default value)</li><li>C: center</li><li>R: right align</li><li>J: justify</li></ul>
Default value: ''
- $ln
-
(Optional) (boolean) if true set cursor at the bottom of the line, otherwise set cursor at the top of the line.
Default value: false
- $stretch
-
(Required) (int) font stretch mode: <ul><li>0 = disabled</li><li>1 = horizontal scaling only if text is larger than cell width</li><li>2 = forced horizontal scaling to fit cell width</li><li>3 = character spacing only if text is larger than cell width</li><li>4 = forced character spacing to fit cell width</li></ul> General font stretching and scaling values will be preserved when possible.
- $firstline
-
(Optional) (boolean) if true prints only the first line and return the remaining string.
Default value: false
- $firstblock
-
(Optional) (boolean) if true the string is the starting of a line.
Default value: false
- $maxh
-
(Required) (float) maximum height. It should be >= $h and less then remaining space to the bottom of the page, or 0 for disable this feature.
- $wadj
-
(Required) (float) first line width will be reduced by this amount (used in HTML mode).
- $margin
-
(Optional) (array) margin array of the parent container
Default value: ''
Return Return
(mixed) Return the number of cells or the remaining string if $firstline = true.
Source Source
File: includes/lib/tcpdf/tcpdf.php
Changelog Changelog
Version | Description |
---|---|
1.5 | Introduced. |