Date: Fri, 29 Mar 2024 08:21:31 -0700 (PDT) Message-ID: <1319310830.537.1711725691698@wiki.srpcs.com> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_536_1319310295.1711725691697" ------=_Part_536_1319310295.1711725691697 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html
Multivalues describing a font pattern.
OLE control Font properties follow the same format as FONT properties in= OpenInsight. The multivalue font structure is @SVM delimited and has the f= ollowing structure:
POS | Name | Type | Description |
---|---|---|---|
<1, 1, 1> | Name | Text | The face name of the font, e.g., "Arial" |
<1, 1, 2> | Height | Integer= | Positive point size value or negative GDI value<= /td> |
<1, 1, 3> | Weight | Integer= | The font's weight: 400 for normal or 700 for bol= d |
<1, 1, 4> | Italic | Boolean= | True for italic text |
<1, 1, 5> | Underline | Boolean= | True for underlined text |
<1, 1, 6> | Width | Integer= | The font's average character width (usually 0)= td> |
<1, 1, 7> | Character Set | Integer= | The font's character set (usually 0) |
<1, 1, 8> | Pitch and Family | Integer= | The font's pitch and family (usually 24) |
<1, 1, 9> | Strikethrough | Boolean= | True for strikethrough text |
<1, 1, 10> | Out Precision | Integer= | The font' output precision. (usually 0) |
<1, 1, 11> | Clip Precision | Integer= | The font' clipping precision. (usually 0) |
<1, 1, 12> | Quality | Integer= | The font's output quality. (usually 0) |
For more information, see Microsoft's documentation regardin= g the C/C++ LOGFONT structure.
There are two differences in the way OLE controls process the font struc= ture. First, blank sub-values are interpreted as "leave alone," i.e., you c= an pass data to only those elements you wish to change. For example, the fo= llowing code only changes the font's weight to bold (700).
// Set the current= font to bold=20 Set_Property(@Window:".OLE_CTRL", "OLE.Font", @SVM:@SVM:700)
The second difference has to do with setting the font's height. Normally, =
the font's height is set in "logical units," a Microsoft convention. A posi=
tive value in this field says you want some space between lines of text whi=
le a negative value means you want to use a specific "logical" height. Howe=
ver, OI developers usually only care about point size. We like to say, "Ari=
al, 8 pt." -- not, "Arial, -11". Therefore, OLE controls will treat positiv=
e values as point sizes. So you can set an OLE control's font size to 8 pt.=
in two ways:
// Set the current= font to 8 pt.=20 Set_Property(@Window:".OLE_CTRL", "OLE.Font", @SVM:8)=20 Set_Property(@Window:".OLE_CTRL", "OLE.Font", @SVM:-11)