![]() ![]() |
GoFiler Legato Script Reference
Legato v 1.6k Application v 6.6a
|
| Table of Contents | < < Previous | Next >> |
Chapter Eleven — SGML Functions (continued)
Overview
The SGMLTWIPSToValue function converts a integer value of TWIPS to a pvalue.
Syntax/Parameters
Syntax
PVALUE = SGMLTWIPSToValue ( int value, PVALUE units, [boolean round] );
Parameters
value
An int specifying measurement in TWIPS (twentieth of points).
units
A PVALUE (dword) to use as a base for the units. The value portion is ignored.
round
A boolean to indicate whether to round the value to whole units. The default is FALSE.
Return Value
A PVALUE (dword) as the result of the translation or PT_UNTRANSLATED on error. The GetLastError function will return ERROR_SYNTAX.
Remarks
A TWIP, or twentieth of a point, is 1/20 of a printer's point, or equivalently 1/1440 of an inch. It is the standard unit of measure for positional and spacing values in SGML/XML-based document layout for applications such as Microsoft Word or Open Office (.docx).
SGMLTWIPSToValue converts a length expressed in twips into its equivalent CSS supported units, as such, the unit parameter must be a unit measurement such as PT_IN or PT_MM.
Units can also be expressed in border keywords using the PT_KEYWORD:
PT_KEYWORD | PK_BORDER_THIN Thin
PT_KEYWORD | PK_BORDER_MEDIUM Medium
PT_KEYWORD | PK_BORDER_THICK Thick
The function assumes the keyword ordinal values are for border-width group of CSS properties. Since the context is not checked, other property ordinal values will return unpredictable results.
Related Functions
Platform Support
Go13, Go16, GoFiler Complete, GoFiler Corporate, GoFiler, GoFiler Lite, GoXBRL
Legato IDE, Legato Basic
Page revised 2026-09-14
| Table of Contents | < < Previous | Next >> |
© 2012-2026 Novaworks, LLC. All rights reserved worldwide. Unauthorized use, duplication or transmission is prohibited by law. Portions of the software are protected by US Patents 10,095,672, 10,706,221 and 11,210,456. Novaworks, GoFiler™ and Legato™ are registered trademarks of Novaworks, LLC. EDGAR® is a federally registered trademark of the U.S. Securities and Exchange Commission. Novaworks is not affiliated with or approved by the U.S. Securities and Exchange Commission. All other trademarks are the property of their respective owners. Use of the features specified in this language are subject to terms, conditions and limitations of the Software License Agreement.