listStyle = styles.newListStyle();
// <style:style style:name="Numbering_20_Symbols"
// style:display-name="Numbering Symbols" style:family="text" />
getOrCreateStyleByName(documentStyles, styles, "Numbering_20_Symbols", OdfStyleFamily.Text);
for (int i = 0; i < 10; i++) {
TextListLevelStyleNumberElement listLevelElement = listStyle.newTextListLevelStyleNumberElement(
DEFAULT_NUM_FORMAT, i + 1);
// get from default style element
listLevelElement.setTextStyleNameAttribute("Numbering_20_Symbols");
listLevelElement.setStyleNumSuffixAttribute(DEFAULT_NUM_SUFFIX);
// different from number decorator.
listLevelElement.setTextDisplayLevelsAttribute(i + 1);
StyleListLevelPropertiesElement styleListLevelPropertiesElement = listLevelElement
.newStyleListLevelPropertiesElement();
if (DEFAULT_TEXT_SPACE_BEFORE_ATTRIBUTES[i] != null) {
styleListLevelPropertiesElement
.setTextSpaceBeforeAttribute(DEFAULT_TEXT_SPACE_BEFORE_ATTRIBUTES[i]);
}
styleListLevelPropertiesElement.setTextMinLabelWidthAttribute(DEFAULT_TEXT_MIN_LABEL_WIDTH);
StyleTextPropertiesElement styleTextPropertiesElement = listLevelElement
.newStyleTextPropertiesElement("true");
styleTextPropertiesElement.setStyleFontNameAttribute(DEFAULT_FONT_NAME);
}
// listStyle.setStyleNameAttribute(DEFAULT_NAME);
}