Class TWPCharAttrInterface

Hierarchy

System.TObject | TWPCharAttrInterface

Description

TWPCharAttrInterface is the interface class to the TWPCharAttr record. It always works on one TWPCharAttr record which must be passed as 'var' to the Get and Set methods. The other var is the return value. All Get functions return a boolean value which is set to TRUE *if* the TWPCharAttr actually defines that property
TWPCharAttrInterface creates an abstraction layer between the compressed TWPCharAttr record and the program code. Please also see the similar TWPCursorCharAttrInterface which is used for read and write access to attribute at the cursor position (similar to CPAttr^ in WPTools 4).
Note: The procedure SetCharStyles is defined as class procedure which makes it possible to call it directly, not using an instance of TWPCharAttrInterface.

Methods

Create(RTFProps:TWPRTFProps)

Destroy

Procedure ExcludeStyle(ca:TWPCharAttr; Element:TOneWrtStyle)

Function GetBGColor(ca:TWPCharAttr; Color:TColor) : Boolean

Function GetBGColorNr(ca:TWPCharAttr; ColorNr:Integer) : Boolean

Function GetCharAttr(Index:Cardinal; ca:TWPCharAttr) : Boolean

Function GetCharLevel(ca:TWPCharAttr; CharlevelPC:Integer) : Boolean

Function GetCharSpacing(ca:TWPCharAttr; DistanceTW:Integer) : Boolean

Function GetCharStyleSheet(ca:TWPCharAttr; StyleSheetNr:Integer) : Boolean

Function GetCharWidth(ca:TWPCharAttr; CharwidthPC:Integer) : Boolean

Function GetColor(ca:TWPCharAttr; Color:TColor) : Boolean

Function GetColorNr(ca:TWPCharAttr; ColorNr:Integer) : Boolean

Function GetFont(ca:TWPCharAttr; FontNr:Integer) : Boolean

Function GetFontCharset(ca:TWPCharAttr; CharSet:Integer) : Boolean

Function GetFontName(ca:TWPCharAttr; FontName:TFontName) : Boolean

Function GetFontSize(ca:TWPCharAttr; FontSize:Single) : Boolean

Function GetHighlightMode(ca:TWPCharAttr; Mode:Integer) : Boolean

Function GetIndex(ca:TWPCharAttr) : Integer

Function GetTextEffect(ca:TWPCharAttr; Mode:Integer) : Boolean

Function GetTextLanguage(ca:TWPCharAttr; Mode:Integer) : Boolean

Function GetUnderlineColor(ca:TWPCharAttr; Color:TColor) : Boolean

Function GetUnderlineColorNr(ca:TWPCharAttr; ColorNr:Integer) : Boolean

Function GetUnderlineMode(ca:TWPCharAttr; Mode:Integer) : Boolean

Procedure IncludeStyle(ca:TWPCharAttr; Element:TOneWrtStyle)

Procedure SetBGColor(ca:TWPCharAttr; Color:TColor)

Procedure SetBGColorNr(ca:TWPCharAttr; ColorNr:Integer)

Procedure SetBGColorString(ca:TWPCharAttr; ColorName:string)

Procedure SetCharLevel(ca:TWPCharAttr; CharlevelPC:Integer)

Procedure SetCharSpacing(ca:TWPCharAttr; DistanceTW:Integer)

Procedure SetCharStyles(ca:TWPCharAttr; WPSTY_mask:Integer; WPSTY_on:Integer)

Procedure SetCharStyleSheet(ca:TWPCharAttr; StyleSheetNr:Integer)

Procedure SetCharWidth(ca:TWPCharAttr; CharwidthPC:Integer)

Procedure SetColor(ca:TWPCharAttr; Color:TColor)

Procedure SetColorNr(ca:TWPCharAttr; ColorNr:Integer)

Procedure SetColorString(ca:TWPCharAttr; ColorName:string)

Procedure SetFont(ca:TWPCharAttr; FontNr:Integer)

Procedure SetFontCharSet(ca:TWPCharAttr; CharSet:Integer)

Procedure SetFontName(ca:TWPCharAttr; FontName:string)

Procedure SetFontSize(ca:TWPCharAttr; FontSize:Single)

Procedure SetHighlightMode(ca:TWPCharAttr; Mode:Integer)

Procedure SetTextEffect(ca:TWPCharAttr; Mode:Integer)

Procedure SetTextLanguage(ca:TWPCharAttr; Mode:Integer)

Procedure SetUnderlineColor(ca:TWPCharAttr; Color:TColor)

Procedure SetUnderlineColorNr(ca:TWPCharAttr; ColorNr:Integer)

Procedure SetUnderlineColorString(ca:TWPCharAttr; ColorName:string)

Procedure SetUnderlineMode(ca:TWPCharAttr; Mode:Integer)

Used or referenced by

-Property TWPRTFProps.AttrInterface : TWPCharAttrInterface