Hello,
I have a problem with derived Styles.
- BaseStyle (MyHeading1): Contains NumberFormat (which leads to a hanging indent)
- Derived Style (MyHeading2): BassedOn BaseStyle with NumberFormat removed
The Problem is:
- when I open the dotx in word, the derived style doesn’t have any indent (as I expected) but
- if I use the Aspose API to access the properties, the derived style contains indents
public void run() {
try {
Document dot = new Document(“D:\Temp\MyDot.dotx”);
StyleCollection styles = dot.getStyles();
for (int i = 0; i < styles.getCount(); i++) {
Style style = styles.get(i);
System.out.println("Name: " + style.getName());
ParagraphFormat pFormat = style.getParagraphFormat();
if (pFormat == null) {
continue;
}
System.out.println("leftIndent: " + pFormat.getLeftIndent());
System.out.println("FirstLineIndet: " + pFormat.getFirstLineIndent());
}
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
Is there any workaround to get the true indent of the derived style?
So long,
Tom