We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Default paragraph format

How can I access the paragraph format of a Paragraph in Aspose Slides for Java?

My use case: Find all portions in a paragraph that differ from the paragraph format and compute the difference.

Paragraph has a method equalFormatting(Paragraph), but how do I access the formatting itself, or compare it to the formatting of a Portion?

Regards,
Harald

Hi Harald,


Please visit this documentation link for accessing various Paragraph format properties. Please share, if I may help you further.

Many Thanks,

That does not answer my question. The page you linked only accesses paragraph formats via the first portion of the paragraph. The format of the first portion may differ from the paragraph format.

In a paragraph like this

A phrase with a highlighted word.

how do you know whether
a) the paragraph format is bold and one word has a different format
b) the paragraph format is standard and all words but one have a different character format (bold) ?

Regards,
Harald

Hi Harald,


The text that you have shared is in one paragraph. However, the paragraph has collection of portions inside it. The properties that you are looking for actually resides in portions. The paragraph text that you have shared is actually divided in three portions based on change in font related properties. “A phrase with a” resides in portion 1. The text, “highlighted” resides in portion 2 and “word.” resides in portion 3. In order to view the properties, you may need to visit each portion object. Hope it will clear the concept to you. For further assistance, please visit link 1 and link 2. The theory presented will elaborate things further to you.

Many Thanks,