jaragunde opened a new pull request, #1561:
URL: https://github.com/apache/poi/pull/1561

   XWPFRun could add breaks but not read them back. getBreak(int) returns the 
BreakType of the break at the given position, the same enum that 
addBreak(BreakType) takes. A break without a type attribute returns 
TEXT_WRAPPING, the default in the spec. An invalid position returns null.
   
   A run can hold any number of breaks mixed with text and tabs. The position 
counts break elements only, so it is not related to the positions used by 
getText(int). getNumberOfBreaks() returns how many breaks the run has, like 
getNumberOfTexts() does for text.
   
   getBreakClear(int) returns the clear attribute of the break at the given 
position as a BreakClear, the same enum that addBreak(BreakClear) takes. A 
break without a clear attribute returns NONE, the default in the spec. An 
invalid position returns null.
   
   getBreaks() returns the types of all the breaks in the run, in the order 
they are stored, so element i is the same as getBreak(i). Like getBreak(int), a 
break without a type is returned as TEXT_WRAPPING. The list is unmodifiable, as 
with XWPFParagraph.getRuns(). It is built on each call and does not change when 
breaks are added to the run later.
   
   Generated by Claude Code with human review and testing.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to