I'm iterating through the paragraphs of a Writer document and search for list numbering by checking for numbering rules and then possible outline numbering, i.e. something like:
Code: Select all
oParaEnum = ThisComponent.getText().createEnumeration()
Do While oParaEnum.hasMoreElements()
oPara = oParaEnum.nextElement()
If oPara.supportsService("com.sun.star.text.Paragraph") Then
If Not isEmpty(oPara.NumberingRules) Then
If Not oPara.NumberingRules.NumberingIsOutline Then
REM handle list item
...
End If
End If
End If
Loop
I noticed the label is part of the String property, but I only want the label. (OK, I guess I could iterate through the text content, assemble a text content string and subtract that from the one I get by getString(), but somehow I'm hoping to find a simpler way.)
Any ideas?
Thanks,
Andreas
OpenOffice 2.4 on Windows XP
OpenOffice 2.3 on Suse 10.3