
PowerDoc Objects
PowerFont
Overview
Just like a regular outline font is a collection of glyph shapes, a PowerFont is a collection of PowerGlyph designs. In this collection, each PowerGlyph design is represented by exactly one PowerFont Record object. The index of the specified PowerRecord is also the index of the corresponding PowerGlyph design.
Designated Rendering Function: NONE
Links
pdPowerFontRecordPtr (1092)
Also appears in: PowerFont Record
Link to the PowerFontRecord object.
This link in used to establish a link to the next PowerFont record.
Properties
pdDw (1029) PD_LONG_SIGNED
Also appears in: PowerFont Record, Library Polyline, Library Shape, Line, Rectangle, Circle/Ellipse, Pattern, Grid, Gradient, Gradient (As Fast Rectangle), Gradient (As Inverter), Bitmap Image, Library Bitmap Image, 3D Model
In general, this property represents the width of a line, shape or some other object in document units. Most objects assume a positive width. However, some objects (e.g. lines) can have either a positive or a negative width. In these cases, this property also indicates the direction.
This property may also be used for some other more specific purposes. For example, in PowerFonts it refers to the font's base width (or horizontal units per em-square). Similarly, in PowerFont records this property serves as the advance width of a glyph.
Sample values:
500 = Width of 500 document units
-200 = Width of -200 document units
pdDh (1030) PD_LONG_SIGNED
Also appears in: Library Polyline, Library Shape, Line, Rectangle, Circle/Ellipse, Pattern, Grid, Gradient, Gradient (As Fast Rectangle), Gradient (As Inverter), Bitmap Image, Library Bitmap Image, 3D Model
In general, this property represents the height of a line, shape or other object in document units. Most objects assume a positive height. But some objects (e.g. lines) can have either a positive or a negative height. In these cases, the height property also indicates the direction.
This property may also be used for some other more specific purposes. For example, in PowerFonts this property refers to the font's base height (or vertical units per em-square).
Sample values:
400 = Height of 400 document units
-100 = Height of -100 document units
pdBoundingBox (1089) PD_ARR_LONG_SIGNED
Bounding box in document units (4 elements, each element is 4 bytes long). The elements represent XMin, YMin, XMax and YMax coordinates of the bounding box.
Exception: The bounding box associated with a PowerFont is flipped in the Y direction. This means its coordinates are actually (XMin, -YMax, XMax, -YMin).
Sample values:
"-50, -50, 350, 350"
Example
C/C++
DT_ID_SLONG obj[15];
obj[0] = pdObjAdd(pd, 0, "Surface Style");
obj[1] = pdObjAdd(pd, 0, "Outline Style");
obj[2] = pdObjAdd(pd, 0, "TextLine Body Style");
obj[3] = pdObjAdd(pd, 0, "Line Definition");
obj[4] = pdObjAdd(pd, 0, "LibShape");
obj[5] = pdObjAdd(pd, 0, "LibShape");
obj[6] = pdObjAdd(pd, 0, "TextLine Typography");
obj[7] = pdObjAdd(pd, 0, "Text Layout");
obj[8] = pdObjAdd(pd, 0, "TextLine");
obj[9] = pdObjAdd(pd, 0, "Group Member #0");
obj[10] = pdObjAdd(pd, 0, "Group Member #1");
obj[11] = pdObjAdd(pd, 0, "Group Member #2");
obj[12] = pdObjAdd(pd, 0, "Group");
obj[13] = pdObjAdd(pd, 0, "PowerFont Record #0");
obj[14] = pdObjAdd(pd, 0, "PowerFont");
pdPropAdd(pd, obj[0], pdRGBT, "FF004000", PD_HEX);
pdPropAdd(pd, obj[1], pdRGBT, "00000000", PD_HEX);
pdPropAdd(pd, obj[2], pdRGBT, "FFFFFF00", PD_HEX);
pdLinkAdd(pd, obj[3], pdStylePtr, obj[1]);
pdPropAdd(pd, obj[3], pdLineThickness, "400", PD_WORD_SIGNED);
pdLinkAdd(pd, obj[4], pdOutlinePtr, obj[3]);
pdPropAdd(pd, obj[4], pdID, "56", PD_WORD_UNSIGNED);
pdPropAdd(pd, obj[4], pdDw, "300", PD_LONG_SIGNED);
pdPropAdd(pd, obj[4], pdDh, "300", PD_LONG_SIGNED);
pdLinkAdd(pd, obj[5], pdBodyPtr, obj[0]);
pdPropAdd(pd, obj[5], pdID, "56", PD_WORD_UNSIGNED);
pdPropAdd(pd, obj[5], pdDw, "270", PD_LONG_SIGNED);
pdPropAdd(pd, obj[5], pdDh, "270", PD_LONG_SIGNED);
pdLinkAdd(pd, obj[6], pdBodyPtr, obj[2]);
pdPropAdd(pd, obj[6], pdFontIndex, "0", PD_WORD_SIGNED);
pdPropAdd(pd, obj[6], pdFontDw, "95", PD_WORD_SIGNED);
pdPropAdd(pd, obj[6], pdFontDh, "130", PD_WORD_SIGNED);
pdPropAdd(pd, obj[6], pdSkewHor, "0", PD_WORD_SIGNED);
pdPropAdd(pd, obj[6], pdSkewVer, "0", PD_WORD_SIGNED);
pdPropAdd(pd, obj[6], pdRotation, "0", PD_WORD_SIGNED);
pdPropAdd(pd, obj[7], pdKerning, "1", PD_BYTE_UNSIGNED);
pdPropAdd(pd, obj[7], pdAlign, "0", PD_BYTE_UNSIGNED);
pdPropAdd(pd, obj[7], pdAlignEnd, "0", PD_BYTE_UNSIGNED);
pdPropAdd(pd, obj[7], pdRelativeDirection, "0", PD_BYTE_UNSIGNED);
pdLinkAdd(pd, obj[8], pdTypographyPtr, obj[6]);
pdLinkAdd(pd, obj[8], pdTextLayoutPtr, obj[7]);
pdPropAdd(pd, obj[8], pdTextString_08, "STOP", PD_ASC);
pdLinkAdd(pd, obj[9], pdGroupMemberPtr, obj[10]);
pdLinkAdd(pd, obj[9], pdFnDrawObjectPtr, obj[4]);
pdPropAdd(pd, obj[9], pdFnDraw, "18", PD_WORD_SIGNED);
pdPropAdd(pd, obj[9], pdDx, "0", PD_LONG_SIGNED);
pdPropAdd(pd, obj[9], pdDy, "-300", PD_LONG_SIGNED);
pdLinkAdd(pd, obj[10], pdGroupMemberPtr, obj[11]);
pdLinkAdd(pd, obj[10], pdFnDrawObjectPtr, obj[5]);
pdPropAdd(pd, obj[10], pdFnDraw, "18", PD_WORD_SIGNED);
pdPropAdd(pd, obj[10], pdDx, "15", PD_LONG_SIGNED);
pdPropAdd(pd, obj[10], pdDy, "-285", PD_LONG_SIGNED);
pdLinkAdd(pd, obj[11], pdFnDrawObjectPtr, obj[8]);
pdPropAdd(pd, obj[11], pdFnDraw, "1", PD_WORD_SIGNED);
pdPropAdd(pd, obj[11], pdDx, "19", PD_LONG_SIGNED);
pdPropAdd(pd, obj[11], pdDy, "-102", PD_LONG_SIGNED);
pdLinkAdd(pd, obj[12], pdGroupMemberPtr, obj[9]);
pdLinkAdd(pd, obj[13], pdFnDrawObjectPtr, obj[12]);
pdPropAdd(pd, obj[13], pdDw, "350", PD_LONG_SIGNED);
pdLinkAdd(pd, obj[14], pdPowerFontRecordPtr, obj[13]);
pdPropAdd(pd, obj[14], pdBoundingBox, "-50, -50, 350, 350", PD_ARR_LONG_SIGNED);
pdPropAdd(pd, obj[14], pdDw, "300", PD_LONG_SIGNED);
pdPropAdd(pd, obj[14], pdDh, "300", PD_LONG_SIGNED);
INTEGRAL DSL
local o = @(label = "") CDTObj(::my.doc, label);
local p = @(id, str, len = PD_DEFAULT) CDTProp(id, str, len);
local s = @(id, str) CDTPropStr(id, str);
local i = @(id, num) CDTPropInt(id, num);
local l = @(id, obj) CDTLink(id, obj);
local obj_0 = o("Surface Style");
local obj_1 = o("Outline Style");
local obj_2 = o("TextLine Body Style");
local obj_3 = o("Line Definition");
local obj_4 = o("LibShape");
local obj_5 = o("LibShape");
local obj_6 = o("TextLine Typography");
local obj_7 = o("Text Layout");
local obj_8 = o("TextLine");
local obj_9 = o("Group Member #0");
local obj_10 = o("Group Member #1");
local obj_11 = o("Group Member #2");
local obj_12 = o("Group");
local obj_13 = o("PowerFont Record #0");
local obj_14 = o("PowerFont");
obj_0 + s(pdRGBT, "FF004000");
obj_1 + s(pdRGBT, "00000000");
obj_2 + s(pdRGBT, "FFFFFF00");
obj_3 + l(pdStylePtr, obj_1);
obj_3 + i(pdLineThickness, 400);
obj_4 + l(pdOutlinePtr, obj_3);
obj_4 + i(pdID, 56);
obj_4 + i(pdDw, 300);
obj_4 + i(pdDh, 300);
obj_5 + l(pdBodyPtr, obj_0);
obj_5 + i(pdID, 56);
obj_5 + i(pdDw, 270);
obj_5 + i(pdDh, 270);
obj_6 + l(pdBodyPtr, obj_2);
obj_6 + i(pdFontIndex, 0);
obj_6 + i(pdFontDw, 95);
obj_6 + i(pdFontDh, 130);
obj_6 + i(pdSkewHor, 0);
obj_6 + i(pdSkewVer, 0);
obj_6 + i(pdRotation, 0);
obj_7 + i(pdKerning, 1);
obj_7 + i(pdAlign, 0);
obj_7 + i(pdAlignEnd, 0);
obj_7 + i(pdRelativeDirection, 0);
obj_8 + i(pdTypographyPtr, obj_6);
obj_8 + i(pdTextLayoutPtr, obj_7);
obj_8 + s(pdTextString_08, "STOP");
obj_9 + l(pdGroupMemberPtr, obj_10);
obj_9 + l(pdFnDrawObjectPtr, obj_4);
obj_9 + i(pdFnDraw, 18);
obj_9 + i(pdDx, 0);
obj_9 + i(pdDy, -300);
obj_10 + l(pdGroupMemberPtr, obj_11);
obj_10 + l(pdFnDrawObjectPtr, obj_5);
obj_10 + i(pdFnDraw, 18);
obj_10 + i(pdDx, 15);
obj_10 + i(pdDy, -285);
obj_11 + l(pdFnDrawObjectPtr, obj_8);
obj_11 + i(pdFnDraw, 1);
obj_11 + i(pdDx, 19);
obj_11 + i(pdDy, -102);
obj_12 + l(pdGroupMemberPtr, obj_9);
obj_13 + l(pdFnDrawObjectPtr, obj_12);
obj_13 + i(pdDw, 350);
obj_14 + l(pdPowerFontRecordPtr, obj_13);
obj_14 + p(pdBoundingBox, "-50, -50, 350, 350", PD_ARR_LONG_SIGNED);
obj_14 + i(pdDw, 300);
obj_14 + i(pdDh, 300);
