Character Attributes

[Top]  [Chapter]  [Previous]  [Next]

WPAT_CharFont = 1; // Set the index of the font.

 

The font index can be claculated using CurrPar.ParStrCommand(1,fontname,0). But usually you will not change the font index directly since you can use the method CurrAttr.SetFontFace to specify a font name.

 

WPAT_CharCharset = 2; // the CharSet of the font. Use IWPParInterface.ConvertFontnameToIndex to create an index value!

 

WPAT_CharFontSize = 3; // FontSize in pt*100

WPAT_CharWidth = 4; // Character scaling value (display similar to WPAT_CharSpacing)

WPAT_CharEffect = 5; // Special character effects and character styles

FLAG: WPEFF_CUSTOM1 = 1; // wpcustN - 63 Custom tags for whatever fixed styles you want to develop

FLAG: WPEFF_CUSTOMMASK = 63; // The following are bits

FLAG: WPEFF_SHADOW = 64; // \shad

FLAG: WPEFF_INSET = 128; // \embo

FLAG: WPEFF_OUTSET = 256; // \impr

FLAG: WPEFF_OUTLINE = 512; // \outl

FLAG: WPEFF_FRAME = 1024; // \chbrdr - only default \brdrs\brdrw10

FLAG: WPEFF_ANIMbit1 = 2048; // \animtext1

FLAG: WPEFF_ANIMbit2 = 4096; // \animtext2

FLAG: WPEFF_ANIMbit3 = 8192; // \animtext4

FLAG: WPEFF_ANIMMask = 8192 + 2048 + 4096;

 

Character styles are stored in 2 properties, one is the mask the other switches on and off:

WPAT_CharStyleMask = 6; // always used together with WPAT_CharStyleON to allow the combination of styles

WPAT_CharStyleON = 7; // Switch one or multiple of the following Styles on  (WPSTY_BOLD ... )

 

FLAG: WPSTY_BOLD = 1; // Bit 1 bold

FLAG: WPSTY_ITALIC = 2; // Bit 2 italic

FLAG: WPSTY_UNDERLINE = 4; // Bit 3 underlined (solod)

FLAG: WPSTY_STRIKEOUT = 8; // Bit 4 strikeout

FLAG: WPSTY_SUPERSCRIPT = 16; // Bit 5 superscript

FLAG: WPSTY_SUBSCRIPT = 32; // Bit 6 subscript

FLAG: WPSTY_HIDDEN = 64; // Bit 7 hidden text

FLAG: WPSTY_UPPERCASE = 128; // Bit 8 all uppercase

FLAG: WPSTY_SMALLCAPS = 256; // Bit 9 all uppercase but non-captitals are 20% larger

FLAG: WPSTY_LOWERCASE = 512; // Bit 10 all lowercase

FLAG: WPSTY_NOPROOF = 1024; // Bit 11 \noproof - disable spellcheck for this

FLAG: WPSTY_DBLSTRIKEOUT = 2048; // Bit 12 strikeout - double solid line

FLAG: WPSTY_BUTTON = 4096; // button - not used!

FLAG: WPSTY_PROTECTED = 8192; // protected text - can be optionally handled as shaded text

FLAG: WPSTY_USERDEFINED = 16384; // Bit 15 user defined flag

{* bit 16 must be unused }

 

WPAT_CharColor = 8; // The text color (as index in palette - see Convert Utility)

Using ParStrCommand(3, color_string, 0) it is possible to convert a color name into an index value.

WPAT_CharBGColor = 9; // The text background color (as index in palette - see Convert Utility)

WPAT_CharSpacing = 10; // "Letter-Spacing" in twips, 0..$8000 = EXPAND, $8001- $FFFF = COMPRESS

WPAT_CharLevel = 11; // Move Character up or down - in half points (RTF: \up \dn }

// 0..$8000 = UP, $8001- $FFFF = down

WPAT_CharHighlight = 12; // {reserved} Highlight mode (different styles and colors)

WPAT_UnderlineMode = 13; // Underlining mode, 0=off, 1=solid, 2=double, 3= dotted ...

FLAG: WPUND_Standard = 1; // Underline Style 1

FLAG: WPUND_Dotted = 2;

FLAG: WPUND_Dashed = 3;

FLAG: WPUND_Dashdotted = 4;

FLAG: WPUND_Dashdotdotted = 5;

FLAG: WPUND_Double = 6;

FLAG: WPUND_Heavywave = 7;

FLAG: WPUND_Longdashed = 8;

FLAG: WPUND_Thick = 9;

FLAG: WPUND_Thickdotted = 10;

FLAG: WPUND_Thickdashed = 11;

FLAG: WPUND_Thickdashdotted = 12;

FLAG: WPUND_Thickdashdotdotted = 13;

FLAG: WPUND_Thicklongdashed = 14;

FLAG: WPUND_Doublewave = 15;

FLAG: WPUND_WordUnderline = 16;

FLAG: WPUND_wave = 17;

FLAG: WPUND_curlyunderline = 18; // only used for spellcheck

FLAG: WPUND_NoLine = 200; // Dont draw line !!!! When imported from RTF!

WPAT_UnderlineColor = 14; // Underlining color, 0=text color, otherwise colorindex +1 -  - see Convert Utility

WPAT_TextLanguage = 15; // {reserved} Language of the text

WPAT_CharStyleSheet = 16; // CharacterStyle (index in ParStyles)

 

NOTE: gray symbols are reserved for future versions of TextDynamic!

 


[characterattributes.htm]    Copyright © 2007 by WPCubed GmbH