Index

CDTDocV8

PropAdd

The PropAdd function adds a PowerDoc property to the PowerDoc object referenced by obj. A property is one of the basic PowerDoc field types.

Parameters

ParameterDescription

obj

Object's index in the Power Engine document.

name

A numerical value that identifies the property to be added. Can be a user-defined value or one of the following predefined PowerDoc values:

Basic PowerDoc Properties PowerDoc Properties For Form Controls
  • pdAlign
  • pdAlignEnd
  • pdAlphaTreatment
  • pdAngleAlpha
  • pdAngleRotation
  • pdAngleTheta
  • pdAttribs
  • pdBackground
  • pdBoundingBox
  • pdChannelFilter
  • pdDeviceMode
  • pdDh
  • pdDw
  • pdDx
  • pdDy
  • pdDynamicDw
  • pdEdges
  • pdEffectsArr
  • pdEP
  • pdFnDraw
  • pdFontDataBytes
  • pdFontDataCaching
  • pdFontDataFormat
  • pdFontDataHinting
  • pdFontDataNumber
  • pdFontDh
  • pdFontDw
  • pdFontIndex
  • pdFontUniqueID
  • pdGlobalDirection
  • pdGlyphStart
  • pdGradientType
  • pdHinting
  • pdID
  • pdImageDataGray
  • pdImageDataGrayAlpha
  • pdImageDataMono
  • pdImageDataRGB
  • pdImageDataRGBAlpha
  • pdIndentLeft
  • pdIndentRight
  • pdKerning
  • pdLineDashSize
  • pdLineEnd
  • pdLineEndSize
  • pdLineEndTheta
  • pdLineMiscFlags
  • pdLinePerimeterGrow
  • pdLineSegment
  • pdLineShift
  • pdLineStart
  • pdLineStartSize
  • pdLineStartTheta
  • pdLineThickness
  • pdLineTreatment
  • pdMarginBottom
  • pdMarginLeft
  • pdMarginRight
  • pdMarginTop
  • pdMask
  • pdMerge
  • pdMMContributions
  • pdName
  • pdNh
  • pdNhHead
  • pdNhFoot
  • pdPowerGlyphStatus
  • pdNw
  • pdOrderingArr
  • pdPatternGroup
  • pdPatternItem
  • pdPatternROP
  • pdPictureNumber
  • pdPitch
  • pdPolyArrC
  • pdPolyArrI
  • pdPolyArrX_08
  • pdPolyArrX_16
  • pdPolyArrX_24
  • pdPolyArrX_32
  • pdPolyArrY_08
  • pdPolyArrY_16
  • pdPolyArrY_24
  • pdPolyArrY_32
  • pdPolyFillRule
  • pdPosArrI
  • pdPosArrX_08
  • pdPosArrX_16
  • pdPosArrX_24
  • pdPosArrX_32
  • pdPosArrY_08
  • pdPosArrY_16
  • pdPosArrY_24
  • pdPosArrY_32
  • pdPositioning
  • pdPowerGlyphAttribs
  • pdQuality
  • pdRadius
  • pdRadiusHor
  • pdRadiusVer
  • pdRangeBB
  • pdRangeGG
  • pdRangeRR
  • pdRasterizer
  • pdRelativeDirection
  • pdRelativeOrientation
  • pdRGBT
  • pdRotation
  • pdRoundX
  • pdRoundY
  • pdRowInvertArr
  • pdShadowDx
  • pdShadowDy
  • pdSkewHor
  • pdSkewVer
  • pdSmoothing
  • pdSpacingBaseline
  • pdSpacingFactor
  • pdSpacingFont
  • pdSpacingLetter
  • pdSpacingRow
  • pdStitching
  • pdT
  • pdTabStopFlags
  • pdTabStopPositions
  • pdTextAreaDh
  • pdTextAreaDw
  • pdTextAreaEdgeLeft
  • pdTextAreaEdgeRight
  • pdTextAreaRowType
  • pdTextAreaType
  • pdTextAreaVAlign
  • pdTextAreaVAlignEnd
  • pdTextBreakFlags
  • pdTextEncoding
  • pdTextHyphenBits
  • pdTextLanguage
  • pdTextMiscAttribs
  • pdTextMiscAttribs2
  • pdTextShaping
  • pdTextShapingParam0
  • pdTextString_08
  • pdTextString_16
  • pdTextString_24
  • pdTextString_32
  • pdTransformMatrix
  • pdUnderline
  • pdUnderlineParam0
  • pdUnderlineParam1
  • pdUnderlineParam2
  • pdUnderlineParam3
  • pdUnderlineParam4
  • pdUserSpecificContent
  • pdVAlignRow
  • pdWrapType
  • pd3DModelData
  • pd3DPos
  • pd3DRot
  • pd3DMul
  • pd3DBuff
  • pd3DProj
  • pd3DMiscBits
  • pd3DRasterizer
  • pd3DQuality
  • pd3DShading
  • pd3DCulling
  • pd3DClipping
  • pd3DTransformMode
  • pd3DTranspThreshold
  • pd3DMaxDepth
  • pd3DBkg
  • pd3DEnv
  • pdxByteCode
  • pdxMagnitude
  • pdxMediaClipID
  • pdxMediaDataBytes
  • pdxMediaDataFormat
  • pdxMediaDescriptor
  • pdxMediaInfoCurrentFrame
  • pdxMediaInfoCurrentTime
  • pdxMediaInfoDuration
  • pdxMediaInfoFPS
  • pdxMediaInfoFramesCount
  • pdxMediaNextCommand
  • pdxMediaNextFrame
  • pdxMediaNextTime
  • pdxMediaPlayState
  • pdxMediaReserved1
  • pdxMediaReserved2
  • pdxMediaStartTime
  • pdxNh
  • pdxNw
  • pdxOriginLocation
  • pdxReserved1
  • pdxSourceCode
  • pdxVAlignCell
  • pdxVAlignRow
  • fcAlign
  • fcAlignEnd
  • fcCnfButtonNormal
  • fcCnfButtonPushed
  • fcCnfCharBox
  • fcCnfCheckBoxNormal
  • fcCnfCheckBoxPushed
  • fcCnfCheckBoxSelected
  • fcCnfCtrlStyleOnFocus
  • fcCnfLib
  • fcCnfRadioButtonNormal
  • fcCnfRadioButtonPushed
  • fcCnfRadioButtonSelected
  • fcCnfSliderNormal
  • fcCnfSliderPushed
  • fcConnectionID
  • fcDh
  • fcDw
  • fcGroupID
  • fcItemFirst
  • fcListColOffset
  • fcListMultiSelect
  • fcListSelectedItems
  • fcLockStatus
  • fcName
  • fcOnCtrlChange
  • fcOnCtrlFocusLose
  • fcOnCtrlFocusReceive
  • fcOnCtrlHold
  • fcOnCtrlPush
  • fcOnCtrlRelease
  • fcOnCtrlScroll
  • fcResizeGuideIndexHor
  • fcResizeGuideIndexVer
  • fcRowFirst
  • fcRowCount
  • fcSliderCoverage
  • fcSliderLimit
  • fcSliderPosition
  • fcSliderFlags
  • fcState
  • fcTabOrderID
  • fcTextScrollType
  • fcTextWrapType
  • fcUserParam
  • fcUserString
  • fcValue_08
  • fcValue_16
  • fcValue_24
  • fcValue_32

value

The value of the property. It can be supplied as native binary data or as a standard null-terminated C/C++ string that Power Engine will transparently convert to a PowerDoc property value in the native binary format (Power Engine will internally use the MakeBinary function to perform this conversion).

For more information, see Guidelines For Creating PowerDoc Objects.

len (or Format Identifier)

When value is supplied as native binary data, this parameter is a positive integer that specifies the length of the binary data in bytes. If, however, value represents a null-terminated C/C++ string to be converted to the native binary format, this parameter is a Format Identifier (which is always a negative integer). For a list of possible format identifiers, please see Note 1.

Return Value

If the function was successful, the return value is 1. Otherwise, the function returns 0 (bad input) or -1 (memory error).

Comments

To avoid unexpected rendering results, properties must be assigned to PowerDoc objects in accordance with D-Type's Guidelines For Creating PowerDoc Objects.

Note 1

Currently supported PowerDoc format identifiers:

PD_BYTE_SIGNED — a string converted to a single signed byte

Operating Range:
-128 to 127
Valid Examples:
"80",  "-50",  "0",  "100",  "-100"
Invalid Examples:
"-500",  "130",  "3.8",  "0.002",  "5E4"

PD_ARR_BYTE_SIGNED — a string converted to an array of signed bytes

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
-128 to 127 for each array element
Valid Examples:
"20, 40, 60, 80",  "-10 -20 -30 0 50 80 90"
Invalid Examples:
"-500, 130, 3.8",  "0.00 5E4 -2"

PD_BYTE_UNSIGNED — a string converted to a single unsigned byte

Operating Range:
0 to 255
Valid Examples:
"120",  "50",  "0",  "100"
Invalid Examples:
"-2",  "350",  "3.8",  "0.002",  "5E4"

PD_ARR_BYTE_UNSIGNED — a string converted to an array of unsigned bytes

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
0 to 255 for each array element
Valid Examples:
"20, 40, 160, 220",  "100 200 250 180"
Invalid Examples:
"0 -20 0 520 50 280 -90",  "0.00 5E4 -2"

PD_WORD_SIGNED — a string converted to a signed 2-byte integer

Operating Range:
-32,768 to 32,767
Valid Examples:
"1000",  "-30150",  "0",  "-100"
Invalid Examples:
"-40000",  "40000",  "3.8",  "0.002",  "5E4"

PD_ARR_WORD_SIGNED — a string converted to an array of signed 2-byte integers

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
-32,768 to 32,767 for each array element
Valid Examples:
"0, 600, 25000, -30000, -50 31000",  "-200 20000"
Invalid Examples:
"0 60000 2e2 -0.6",  "33000, -33000"

PD_WORD_UNSIGNED — a string converted to an unsigned 2-byte integer

Operating Range:
0 to 65,535
Valid Examples:
"20000",  "50",  "0",  "100"
Invalid Examples:
"-50",  "150000",  "3.8",  "0.002",  "5E4"

PD_ARR_WORD_UNSIGNED — a string converted to an array of unsigned 2-byte integers

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
0 to 65,535 for each array element
Valid Examples:
"1, 2, 3",  "50000 60000 120 5000"
Invalid Examples:
"-1, -2, -3, -4",  "0.5 -2E2 70000"

PD_TRIO_SIGNED — a string converted to a signed 3-byte integer

Operating Range:
-8,388,608 to 8,388,607
Valid Examples:
"10000",  "-300800",  "0",  "-100"
Invalid Examples:
"-9000000",  "9000000",  "3.8",  "0.002",  "5E4"

PD_ARR_TRIO_SIGNED — a string converted to an array of signed 3-byte integers

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
-8,388,608 to 8,388,607 for each array element
Valid Examples:
"0, 600, 25000, -30000, -50 31000",  "-200 20000"
Invalid Examples:
"0 15000000 2e2 -0.6",  "9000000, -9000000"

PD_TRIO_UNSIGNED — a string converted to an unsigned 3-byte integer

Operating Range:
0 to 16,777,216
Valid Examples:
"14000000",  "50",  "0",  "100"
Invalid Examples:
"-50",  "17000000",  "3.8",  "0.002",  "5E4"

PD_ARR_TRIO_UNSIGNED — a string converted to an array of unsigned 3-byte integers

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
0 to 16,777,216 for each array element
Valid Examples:
"1, 2, 3",  "50000 60000 120 5000"
Invalid Examples:
"-1, -2, -3, -4",  "0.5 -2E2 17000000"

PD_LONG_SIGNED — a string converted to a signed 4-byte integer

Operating Range:
-2,147,483,648 to 2,147,483,647
Valid Examples:
"1555000",  "-4110000",  "0",  "-100"
Invalid Examples:
"-5000000000",  "3000000000",  "3.8",  "0.002",  "5E4"

PD_ARR_LONG_SIGNED — a string converted to an array of signed 4-byte integers

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
-2,147,483,648 to 2,147,483,647 for each array element
Valid Examples:
"-1500400200, 2000000000, 80",  "0 0 0 0 0"
Invalid Examples:
"2147483648, 0",  "0.001 -3.2 5E7 2000"

PD_LONG_UNSIGNED — a string converted to an unsigned 4-byte integer

Operating Range:
0 to 4,294,967,295
Valid Examples:
"120",  "50",  "0",  "4000000000"
Invalid Examples:
"-50",  "5000000000",  "3.8",  "0.002",  "5E4"

PD_ARR_LONG_UNSIGNED — a string converted to an array of unsigned 4-byte integers

Individual elements of the array should be seprated by a single comma and/or space character.

Operating Range:
0 to 4,294,967,295 for each array element
Valid Examples:
"500, 4294967295, 0",  "100 100 100 100 100 100 100 100 100"
Invalid Examples:
"-1, -2, -3",  "0.2 abc 8123222100",  "500, 4294967296, 0"

PD_ASC — a string of ASCII characters converted to an array of bytes

Valid Examples:
"test",  "1e345fg6",  "x y z",  "- / $ \ +"

PD_HEX — a string of 2-digit HEX values converted to an array of bytes.
(when applicable, the expected length of the array will be indicated)

Although PD_HEX is a general purpose format, it is used as the default storage format only for properties whose value strings cannot be conveniently represented in any other way (for example: bitmap's pixels or other binary data).

Valid Examples:
"23A4E8",  "23 A4 E8",  "23 a4 e8",  "F2 e5 14 C4 e8"
Invalid Examples:
"23 A4 E",  "12mk34",  "-50 e8",  "a2.05"

PD_DEFAULT — a string converted to the property's default storage format.

Depending on the property in question, this can be any of the above format identifiers.

PD_ARR_BYTE_SIGNED_COMPRESS — Same as PD_ARR_BYTE_SIGNED but indicates that the supplied array of bytes should be compressed using compression method 006.

PD_ARR_BYTE_UNSIGNED_COMPRESS — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 006.

PD_ARR_WORD_SIGNED_COMPRESS — Same as PD_ARR_WORD_SIGNED but indicates that the supplied array of bytes should be compressed using compression method 004.

PD_ARR_WORD_UNSIGNED_COMPRESS — Same as PD_ARR_WORD_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 004.

PD_ARR_TRIO_SIGNED_COMPRESS — Same as PD_ARR_TRIO_SIGNED but indicates that the supplied array of bytes should be compressed using compression method 002.

PD_ARR_TRIO_UNSIGNED_COMPRESS — Same as PD_ARR_TRIO_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 002.

PD_ARR_LONG_SIGNED_COMPRESS — Same as PD_ARR_LONG_SIGNED but indicates that the supplied array of bytes should be compressed using compression method 000.

PD_ARR_LONG_UNSIGNED_COMPRESS — Same as PD_ARR_LONG_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 000.

PD_ARR_COMPRESS_METHOD_000 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 000.

PD_ARR_COMPRESS_METHOD_002 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 002.

PD_ARR_COMPRESS_METHOD_004 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 004.

PD_ARR_COMPRESS_METHOD_006 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 006.

PD_ARR_COMPRESS_METHOD_008 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 008.

PD_ARR_COMPRESS_METHOD_009 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 009.

PD_ARR_COMPRESS_METHOD_010 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 010.

PD_ARR_COMPRESS_METHOD_011 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 011.

PD_ARR_COMPRESS_METHOD_012 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 012.

PD_ARR_COMPRESS_METHOD_015 — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes should be compressed using compression method 015.

PD_HEX_COMPRESS_METHOD_000 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 000.

PD_HEX_COMPRESS_METHOD_002 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 002.

PD_HEX_COMPRESS_METHOD_004 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 004.

PD_HEX_COMPRESS_METHOD_006 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 006.

PD_HEX_COMPRESS_METHOD_008 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 008.

PD_HEX_COMPRESS_METHOD_009 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 009.

PD_HEX_COMPRESS_METHOD_010 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 010.

PD_HEX_COMPRESS_METHOD_011 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 011.

PD_HEX_COMPRESS_METHOD_012 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 012.

PD_HEX_COMPRESS_METHOD_015 — Same as PD_HEX but indicates that the supplied array of bytes should be compressed using compression method 015.

PD_ARR_COMPRESSED — Same as PD_ARR_BYTE_UNSIGNED but indicates that the supplied array of bytes is already compressed using one of the above compression methods.

PD_HEX_COMPRESSED — Same as PD_HEX but indicates that the supplied array of bytes is already compressed using one of the above compression methods.



 

Index