This topic covers the implementation details of TMultiHolidays.
Scope: cpMultiHolidays.pas; class derived from TBtnEditProperty. Prepared from the curated implementation supplied for this review on 2 October 2026.
The property serializes a/e/i/o/u list-specific surrounding text, separators, multi-day/month/year strings and hyphenation flags. Its member strings can use fixed-buffer setters. Literal XML names and defaults are detailed below.
Notation and shared helper rules: Reading this reference.
No literal rec_type value is emitted directly by the selected routines. A property envelope, an inherited writer or a delegated record can supply its identifying attributes.
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:
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.
{s + '-holidays'}/strLeft
XML representation: The text of the strLeft element.
Reading: Reads the element into strLeft[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores strLeft[iqhl] when for each iqhl from qhlA through qhlU; StrLeft[iqhl] is not empty.
{s + '-holidays'}/strRight
XML representation: The text of the strRight element.
Reading: Reads the element into strRight[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores strRight[iqhl] when for each iqhl from qhlA through qhlU; StrRight[iqhl] is not empty.
{s + '-holidays'}/strMultiHolidaysSeparator
XML representation: The text of the strMultiHolidaysSeparator element.
Reading: Reads the element into strMultiHolidaysSeparator[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores str when for each iqhl from qhlA through qhlU; strMultiHolidaysSeparator[iqhl] is not empty.
{s + '-holidays'}/StrLeftMultiDay
XML representation: The text of the StrLeftMultiDay element.
Reading: Reads the element into StrLeftMultiDay[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores StrLeftMultiDay[iqhl] when for each iqhl from qhlA through qhlU; StrLeftMultiDay[iqhl] is not empty.
{s + '-holidays'}/StrLeftMultiMonth
XML representation: The text of the StrLeftMultiMonth element.
Reading: Reads the element into StrLeftMultiMonth[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores StrLeftMultiMonth[iqhl] when for each iqhl from qhlA through qhlU; StrLeftMultiMonth[iqhl] is not empty.
{s + '-holidays'}/StrLeftMultiYear
XML representation: The text of the StrLeftMultiYear element.
Reading: Reads the element into StrLeftMultiYear[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores StrLeftMultiYear[iqhl] when for each iqhl from qhlA through qhlU; StrLeftMultiYear[iqhl] is not empty.
{s + '-holidays'}/StrRightMultiDay
XML representation: The text of the StrRightMultiDay element.
Reading: Reads the element into StrRightMultiDay[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores StrRightMultiDay[iqhl] when for each iqhl from qhlA through qhlU; StrRightMultiDay[iqhl] is not empty.
{s + '-holidays'}/StrRightMultiMonth
XML representation: The text of the StrRightMultiMonth element.
Reading: Reads the element into StrRightMultiMonth[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores StrRightMultiMonth[iqhl] when for each iqhl from qhlA through qhlU; StrRightMultiMonth[iqhl] is not empty.
{s + '-holidays'}/StrRightMultiYear
XML representation: The text of the StrRightMultiYear element.
Reading: Reads the element into StrRightMultiYear[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores StrRightMultiYear[iqhl] when for each iqhl from qhlA through qhlU; StrRightMultiYear[iqhl] is not empty.
{s + '-holidays'}/useLeftHyphenSingle
XML representation: The text of the useLeftHyphenSingle element.
Reading: Reads the element into useLeftHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores true or false according to useLeftHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; useLeftHyphenSingle[iqhl] is true.
{s + '-holidays'}/sLeftHyphenSingle
XML representation: The text of the sLeftHyphenSingle element.
Reading: Reads the element into sLeftHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores sLeftHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; useLeftHyphenSingle[iqhl] is true.
{s + '-holidays'}/useLeftHyphenMulti
XML representation: The text of the useLeftHyphenMulti element.
Reading: Reads the element into useLeftHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores true or false according to useLeftHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; useLeftHyphenMulti[iqhl] is true.
{s + '-holidays'}/sLeftHyphenMulti
XML representation: The text of the sLeftHyphenMulti element.
Reading: Reads the element into sLeftHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores sLeftHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; useLeftHyphenMulti[iqhl] is true.
{s + '-holidays'}/useRightHyphenSingle
XML representation: The text of the useRightHyphenSingle element.
Reading: Reads the element into useRightHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores true or false according to useRightHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; useRightHyphenSingle[iqhl] is true.
{s + '-holidays'}/sRightHyphenSingle
XML representation: The text of the sRightHyphenSingle element.
Reading: Reads the element into sRightHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores sRightHyphenSingle[iqhl] when for each iqhl from qhlA through qhlU; useRightHyphenSingle[iqhl] is true.
{s + '-holidays'}/useRightHyphenMulti
XML representation: The text of the useRightHyphenMulti element.
Reading: Reads the element into useRightHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores true or false according to useRightHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; useRightHyphenMulti[iqhl] is true.
{s + '-holidays'}/sRightHyphenMulti
XML representation: The text of the sRightHyphenMulti element.
Reading: Reads the element into sRightHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; the record node exists.
Writing: Stores sRightHyphenMulti[iqhl] when for each iqhl from qhlA through qhlU; useRightHyphenMulti[iqhl] is true.
Nested records and repeated elements
Operation |
XML location |
When it is processed |
Read aPropValue.mhOptions[iqhl] |
{s + '-holidays'} |
for each iqhl from qhlA through qhlU; the record node exists |
Write DataValue.mhOptions[iqhl] |
{s + '-holidays'} |
for each iqhl from qhlA through qhlU |
Initialization and reset values
TMultiHolidays.Create
Setting or temporary variable |
Initial value |
When it is assigned |
PropName |
“Holidays Concatenation Options” |
Always |
Required |
1 |
Always |
PropValue |
Default (TSL_PropValue) |
Always |
Version |
0 |
Always |
IncludedMacros |
an empty set |
Always |
lstTokensOfMacroIndex |
TStringList.Create |
Always |
ListMacroTokens |
TStringList.Create |
Always |
ListMacroTokens.Duplicates |
dupIgnore |
Always |
PropValue.mhOptions[qhl].HolidaysSaintsExclusion |
hseIfRegional (1) |
for each qhl from qhlA through qhlU |
PropValue.mhOptions[qhl].oldMultiHolidaysSeparator |
“, ” |
for each qhl from qhlA through qhlU |
PropValue.mhOptions[qhl].oldStrLeftRightHol |
an empty string |
for each qhl from qhlA through qhlU |
PropValue.mhOptions[qhl].SaintsSetId |
- 1 |
for each qhl from qhlA through qhlU |
PropValue.mhOptions[qhl].SaintsExceptions |
sehReplace (3) |
for each qhl from qhlA through qhlU |
StrLeft[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
StrRight[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
strMultiHolidaysSeparator[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
StrLeftMultiDay[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
StrLeftMultiMonth[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
StrLeftMultiYear[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
StrRightMultiDay[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
StrRightMultiMonth[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
StrRightMultiYear[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
useLeftHyphenSingle[qhl] |
false |
for each qhl from qhlA through qhlU |
sLeftHyphenSingle[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
useLeftHyphenMulti[qhl] |
false |
for each qhl from qhlA through qhlU |
sLeftHyphenMulti[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
useRightHyphenSingle[qhl] |
false |
for each qhl from qhlA through qhlU |
sRightHyphenSingle[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
useRightHyphenMulti[qhl] |
false |
for each qhl from qhlA through qhlU |
sRightHyphenMulti[qhl] |
an empty string |
for each qhl from qhlA through qhlU |
PropValue.mhOptions[qhl] |
IniSettings.MultiHolidays.DataValue.mhOptions[qhl] |
UseIniSettingsInPropertyConstructor is true; self is not IniSettings.MultiHolidays; for each qhl from qhlA through qhlU |
DataValue |
PropValue |
Always |
This routine also calls inherited Create; lstTokensOfMacroIndex.Add(''); self.FillDisplayValue. See Implementation for their order and any conditional calls.
Value namespaces used by this implementation
These are declared Pascal ordinal values. Use the ordinal only where the field serializer actually writes ord(...), an integer cast or an equivalent value. Set-marker strings and local option lists have their own representation; sentinel members in an enum are not automatically legal XML choices.
TqHolList
Ordinal |
Declared member |
0 |
qhlA |
1 |
qhlE |
2 |
qhlI |
3 |
qhlO |
4 |
qhlU |
5 |
qhlNone |
6 |
qhlInsert |
7 |
qhlXtra |
THolidaysSaintsExclusion
Ordinal |
Declared member |
0 |
hseNever |
1 |
hseIfRegional |
2 |
hseAlways |
TSaintsExceptionsHandling
Ordinal |
Declared member |
0 |
sehSkip |
1 |
sehPrepend |
2 |
sehAppend |
3 |
sehReplace |
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 |
StrLeft |
array [qhlA..qhlU] of string |
member |
StrRight |
array [qhlA..qhlU] of string |
member |
StrMultiHolidaysSeparator |
array [qhlA..qhlU] of string |
member |
StrLeftMultiDay |
array [qhlA..qhlU] of string |
member |
StrLeftMultiMonth |
array [qhlA..qhlU] of string |
member |
StrLeftMultiYear |
array [qhlA..qhlU] of string |
member |
StrRightMultiDay |
array [qhlA..qhlU] of string |
member |
StrRightMultiMonth |
array [qhlA..qhlU] of string |
member |
StrRightMultiYear |
array [qhlA..qhlU] of string |
member |
useLeftHyphenSingle |
array [qhlA..qhlU] of boolean |
member |
useLeftHyphenMulti |
array [qhlA..qhlU] of boolean |
member |
useRightHyphenSingle |
array [qhlA..qhlU] of boolean |
member |
useRightHyphenMulti |
array [qhlA..qhlU] of boolean |
member |
sLeftHyphenSingle |
array [qhlA..qhlU] of string |
member |
sLeftHyphenMulti |
array [qhlA..qhlU] of string |
member |
sRightHyphenSingle |
array [qhlA..qhlU] of string |
member |
sRightHyphenMulti |
array [qhlA..qhlU] of string |
member |
usesLeftMultiDates |
array [qhlA..qhlU] of boolean |
member |
usesRightMultiDates |
array [qhlA..qhlU] of boolean |
member |
IncludedMacros |
TSetOfMacros |
member |
lstTokensOfMacroIndex |
TStringList |
member |
ListMacroTokens |
TStringList |
member |
The Implementation toggle contains only TMultiHolidays methods. Initializers and helpers belonging to other types are identified separately below. Shared XML-helper limitations are explained in Reading this reference.