NumberStyle enumeration

NumberStyle enumeration

Specifies the number style for a list, footnotes and endnotes, page numbers.

Members

NameDescription
ArabicArabic numbering (1, 2, 3, …)
UppercaseRomanUpper case Roman (I, II, III, …)
LowercaseRomanLower case Roman (i, ii, iii, …)
UppercaseLetterUpper case Letter (A, B, C, …)
LowercaseLetterLower case letter (a, b, c, …)
OrdinalOrdinal (1st, 2nd, 3rd, …)
NumberNumbered (One, Two, Three, …)
OrdinalTextOrdinal (text) (First, Second, Third, …)
HexHexadecimal: 8, 9, A, B, C, D, E, F, 10, 11, 12
ChicagoManualChicago Manual of Style: *, †, †
KanjiIdeograph-digital
KanjiDigitJapanese counting
AiueoHalfWidthAiueo
IrohaHalfWidthIroha
ArabicFullWidthFull-width Arabic: 1, 2, 3, 4
ArabicHalfWidthHalf-width Arabic: 1, 2, 3, 4
KanjiTraditionalJapanese legal
KanjiTraditional2Japanese digital ten thousand
NumberInCircleEnclosed circles
DecimalFullWidthDecimal full width: 1, 2, 3, 4
AiueoAiueo full width
IrohaIroha full width
LeadingZeroLeading Zero (01, 02,…, 09, 10, 11,…, 99, 100, 101,…)
BulletBullet (check the character code in the text)
GanadaKorean Ganada
ChosungKorea Chosung
GB1Enclosed full stop
GB2Enclosed parenthesis
GB3Enclosed circle Chinese
GB4Ideograph enclosed circle
Zodiac1Ideograph traditional
Zodiac2Ideograph Zodiac
Zodiac3Ideograph Zodiac traditional
TradChinNum1Taiwanese counting
TradChinNum2Ideograph legal traditional
TradChinNum3Taiwanese counting thousand
TradChinNum4Taiwanese digital
SimpChinNum1Chinese counting
SimpChinNum2Chinese legal simplified
SimpChinNum3Chinese counting thousand
SimpChinNum4Chinese (not implemented)
HanjaReadKorean digital
HanjaReadDigitKorean counting
HangulKorea legal
HanjaKorea digital2
Hebrew1Hebrew-1
Arabic1Arabic alpha
Hebrew2Hebrew-2
Arabic2Arabic abjad
HindiLetter1Hindi vowels
HindiLetter2Hindi consonants
HindiArabicHindi numbers
HindiCardinalTextHindi descriptive (cardinals)
ThaiLetterThai letters
ThaiArabicThai numbers
ThaiCardinalTextThai descriptive (cardinals)
VietCardinalTextVietnamese descriptive (cardinals)
NumberInDashPage number format: - 1 -, - 2 -, - 3 -, - 4 -
LowercaseRussianLowercase Russian alphabet
UppercaseRussianUppercase Russian alphabet
NoneNo bullet or number.
CustomCustom number format. It is supported by DOCX format only.

Examples

Shows how to apply custom list formatting to paragraphs when using DocumentBuilder.

let doc = new aw.Document();

// A list allows us to organize and decorate sets of paragraphs with prefix symbols and indents.
// We can create nested lists by increasing the indent level. 
// We can begin and end a list by using a document builder's "ListFormat" property. 
// Each paragraph that we add between a list's start and the end will become an item in the list.
// Create a list from a Microsoft Word template, and customize the first two of its list levels.
let list = doc.lists.add(aw.Lists.ListTemplate.NumberDefault);

let listLevel = list.listLevels.at(0);
listLevel.font.color = "#FF0000";
listLevel.font.size = 24;
listLevel.numberStyle = aw.NumberStyle.OrdinalText;
listLevel.startAt = 21;
listLevel.numberFormat = "\u0000";

listLevel.numberPosition = -36;
listLevel.textPosition = 144;
listLevel.tabPosition = 144;

listLevel = list.listLevels.at(1);
listLevel.alignment = aw.Lists.ListLevelAlignment.Right;
listLevel.numberStyle = aw.NumberStyle.Bullet;
listLevel.font.name = "Wingdings";
listLevel.font.color = "#0000FF";
listLevel.font.size = 24;

// This NumberFormat value will create star-shaped bullet list symbols.
listLevel.numberFormat = "\uf0af";
listLevel.trailingCharacter = aw.Lists.ListTrailingCharacter.Space;
listLevel.numberPosition = 144;

// Create paragraphs and apply both list levels of our custom list formatting to them.
let builder = new aw.DocumentBuilder(doc);

builder.listFormat.list = list;
builder.writeln("The quick brown fox...");
builder.writeln("The quick brown fox...");

builder.listFormat.listIndent();
builder.writeln("jumped over the lazy dog.");
builder.writeln("jumped over the lazy dog.");

builder.listFormat.listOutdent();
builder.writeln("The quick brown fox...");

builder.listFormat.removeNumbers();

builder.document.save(base.artifactsDir + "Lists.CreateCustomList.docx");

See Also