Ticket #2462: justify_correction_2.patch

File justify_correction_2.patch, 800 bytes (added by boyanl, 15 years ago)
  • modules/org.sophie2.base.model.text/src/main/java/org/sophie2/base/model/text/layout/LineBreakUtil.java

    ### Eclipse Workspace Patch 1.0
    #P sophie
     
    155155                                                                (c == CommonChar.SPACE || 
    156156                                                                c == CommonChar.TAB || 
    157157                                                                c == CommonChar.LINE_BREAK)) { 
    158                                                         c = text.unitAt(ind++).getChar(); 
     158                                                        ++ind; 
     159                                                        if (ind >= requiredEnd) 
     160                                                                break; 
     161                                                        c = text.unitAt(ind).getChar(); 
    159162                                                } 
    160163                                                         
    161164                                                whitespaceBreaks.add(ind);