![]() |
![]()
| ![]() |
![]()
NAMErender_text - Convert a format string to a new video object. SYNOPSISvid, lineheights, width, height, ascent
dststore, message, vspacing, tspacing, tabs ) DESCRIPTIONRender a format string into a texture assigned to a new video object. Return this object along with a table of individual line-heights. The optional dststore can be used to update a previous result from render_text, which cuts down on costs for dynamic allocation and recreating or rebuilding related vid hierarchies, with the caveat that custom texture coordinates from cropping and similar operations may still need to be reapplied. Render behavior varies with the type of message , which can be string or a n-indexed table of strings. Anything else is a terminal state transition. If message is a string, all contents will be treated as a format string which is dangerous with user supplied content as escaping and dynamic string construction is costly. If message is a table of strings, strings at odd indices will be treated as format strings and even indices are treated as raw UTF 8. Vspacing indicates the default padding between lines, and tspacing the horizontal spacing between tabs. If vspacing is set to nil or 0, the added padding will be taken from the font. Each formatting sequence is initiated with a single backslash, followed with a command code (see table below). Stateful commands (b, i, u) can be negated with a preluding exclamation point. NOTES
SEE ALSO:text_dimensions(3)
|