mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-24 20:49:13 +00:00
Made a check for line range stricter ... apparently because of a bug
elsewhere, the stricter check is needed to prevent a crash git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@13202 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
9e4dc40eb9
commit
8564eb7342
1 changed files with 4 additions and 1 deletions
|
@ -477,6 +477,9 @@ static NSCharacterSet *invSelectionWordGranularitySet;
|
|||
[[aTextContainer textView] sizeToFit];
|
||||
[[aTextContainer textView] invalidateTextContainerOrigin];
|
||||
|
||||
/* FIXME - it was reported that at this point lineRange is no longer
|
||||
* correct ... looks like sizeToFit / invalidateTextContainerOrigin
|
||||
* migth cause additional relayout. */
|
||||
[self setNeedsDisplayForLineRange: lineRange
|
||||
inTextContainer: aTextContainer];
|
||||
}
|
||||
|
@ -740,7 +743,7 @@ forStartOfGlyphRange: (NSRange)glyphRange
|
|||
inTextContainer: (NSTextContainer *)aTextContainer
|
||||
{
|
||||
if ([_lineLayoutInformation count]
|
||||
&& redrawLineRange.location < [_lineLayoutInformation count]
|
||||
&& NSMaxRange (redrawLineRange) < [_lineLayoutInformation count]
|
||||
&& redrawLineRange.length)
|
||||
{
|
||||
_GNULineLayoutInfo *firstInfo
|
||||
|
|
Loading…
Reference in a new issue