This topic covers the implementation details of TAllScriptColors.
Scope: cpAllScriptColors.pas; class derived from TBtnEditProperty. Prepared from the curated implementation supplied for this review on 2 October 2026.
ScriptColorsOptions contains EnableChecking and Threshold. TScriptColorsOptionsRec.Initialize sets true and 25 respectively; the reader calls it before reading. The threshold’s human-facing unit and valid range require the checking/UI consumer, not its integer serializer.
Notation and shared helper rules: Reading this reference.
Literal rec_type values emitted within these routines: TScriptColorsOptionsRec. Nested values may belong to child wrappers rather than this owner itself; the attribute entries below give their exact locations.
Inherited implementation: TBtnEditProperty. Follow it when the ordered behavior invokes inherited methods; inherited fields are not repeated as locally owned fields.
Structures used directly by this XML implementation:
TScriptColorsOptionsRec (supporting record documented below).
Exact XML fields and attributes
The paths below start at this record or property node. A slash identifies a child element; @ identifies an attribute. Curly braces mark a variable index or expression, not literal XML text. Initial values describe initialization; they do not establish what an omitted individual element does. The Implementation toggle below contains the supplied routines for exact branch order and conversions.
ScriptColorsOptions/EnableChecking
Turns checking on or off.
XML representation: The text of the EnableChecking element.
Initial value: true. The reader initializes the supporting options record before reading these fields.
Reading: Reads the element into ScriptColorsOptions.EnableChecking.
Writing: Stores true or false according to ScriptColorsOptions.EnableChecking whenever the writer reaches this field.
ScriptColorsOptions/Threshold
The integer threshold used by the check. The serializer does not define its unit or permitted range.
XML representation: The text of the Threshold element.
Initial value: 25. The reader initializes the supporting options record before reading these fields.
Reading: Reads the element into ScriptColorsOptions.Threshold.
Writing: Stores the numeric value of ScriptColorsOptions.Threshold whenever the writer reaches this field.
ScriptColorsOptions/@rec_type
XML representation: The rec_type attribute.
Writing: Stores the literal text “TScriptColorsOptionsRec” whenever the writer reaches this field.
Initialization and reset values
TAllScriptColors.Create
Setting or temporary variable |
Initial value |
When it is assigned |
PropName |
“All Colors in Script” |
Always |
Required |
0 |
Always |
PropValue |
Default (TSL_PropValue) |
Always |
DataValue |
PropValue |
Always |
This routine also calls inherited Create; FillDisplayValue. See Implementation for their order and any conditional calls.
Supporting initializers and helpers supplied with the owner
These supporting records are used directly by this owner or by an initializer it calls. Their relevant supplied routines appear in separate Supporting implementation toggles below.
TScriptColorsOptionsRec.Initialize
Setting or temporary variable |
Initial value |
When it is assigned |
self |
Default (TScriptColorsOptionsRec) |
Always |
EnableChecking |
true |
Always |
Threshold |
25 |
Always |
Storage declarations relevant to interpretation
These are in-memory member and property types, not a list of mandatory XML children. They retain array bounds, fixed buffers and selector types. The field reference above defines what is actually serialized.
Name |
Declared type / bounds |
Kind |
ScriptColorsOptions |
TScriptColorsOptionsRec |
member |
TScriptColorsOptionsRec member shape
Member |
Declared type |
EnableChecking |
boolean |
Threshold |
integer |
The Implementation toggle contains only TAllScriptColors methods. Initializers and helpers belonging to other types are identified separately below. Shared XML-helper limitations are explained in Reading this reference.
Supporting implementation — TScriptColorsOptionsRec
The following routines belong to TScriptColorsOptionsRec, a supporting type used by this implementation. They are not methods of TAllScriptColors.
Declaration — TScriptColorsOptionsRec
Supporting implementation — TScriptColorsOptionsRec