Detecting indent of text in bulleted list items

Hi there

What property can be used detect the indent of text in a series of bulleted list items in a presentation?. When I write out the file having made modifications to the paragraphs comprising the items, the indentation is lost.

Thanks

Eric

Hello Eric,

To get or set bullet indent you can use Paragraph.BulletOffset. For the text indent there is Paragraph.TextOffset property.

Hi Alexey

Thanks for your reply. For some reason, Aspose.Slides is reporting a value of 0 for both the paragraph.bulletOffset and Paragraph.TextOffset properties, even though the text in the bullets is clearly indented with respect to the bullet character/number. I have attached the file if you want to test it yourself in case you get a different result.

Thanks

Eric

TextOffset == 0 means text should be rendered immediately after bullet without offset.

Real text offset in a paragraph with bullet can be calculated by this formula:
Math.Max ( BulletOffset + bulletWidth, TextOffset )

Hi Alexey

Thanks for your reply. What class is bulletWidth a property of ? I couldnt find it in the paragraph class?

Thanks

Eric

Hi Eric,

I have forwarded your question to Mr. Alexey. It is possible that he meant some other property / value.

Hello Eric,

That is internal calculated variable and part of our rendering engine. You probably would like to have it as public property?

Hi Alexey,

Yes that would be great. At the moment the bulletoffset and textoffset values for those paragraphs are set to zero so they are not providing me with the information needed to reproduce the paragraphs later on.
This issue is reproducible if you open the presentation using Aspose.Slides and then immediately save it without modifying the paragraphs. Also notice the heading text on page two “Using the pitchbook template” is larger than on in input using the same method.

Thanks

Eric

Hello Eric,

You can reproduce paragraphs if you set TextOffset property to the same value as in source paragraph. 0 in your case. Created paragraph will have exactly the same text offset.

I have understood the problem. You open presentation with PowerPoint 2007? Now please open it in PowerPoint 2003 and you will see how presentation should look. PowerPoint 2007 simply save incorrect information about text to the PPT file in your case.