addTextBox
addTextBox
BASIC / ADVANCED / PREMIUM
Inserts a text box into the PowerPoint presentation.
Description
public addTextBox($position, $textBoxStyles = array(), $options = array())
This method inserts text boxes into the PowerPoint presentation.
Parameters
position
Text box position.
Key | Type | Description |
---|---|---|
coordinateX | int | EMUs (English Metric Unit). |
coordinateY | int | EMUs (English Metric Unit). |
sizeX | int | EMUs (English Metric Unit). |
sizeY | int | EMUs (English Metric Unit). |
order | int | Set the display order. Default after existing contents. 0 is the first order position. If the order position doesn't exist add after existing contents. |
Coordinate and size values must be set.
textBoxStyles
Key | Type | Description |
---|---|---|
autofit | string | autofit (default), noautofit, shrink. |
border | array |
|
columns | array |
|
descr | string | Descr value. |
fill | array |
|
margin | array |
|
rotation | int | Rotation. |
textDirection | string | horz, vert, vert270, wordArtVert, eaVert, mongolianVert, wordArtVertRtl. |
verticalAlign | string | top, middle, bottom, topCentered, middleCentered, bottomCentered. |
wrap | string | square, none. |
options
Key | Type | Description |
---|---|---|
name | string | Text box internal name. If not set, a random name is generated. |
Exceptions
Position not valid.
Release notes
- phppptx 1.0:
- new method.