Need to make sure we don't create text containers with negative dimensions.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@27766 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
rfm 2009-02-03 15:56:51 +00:00
parent 54195911db
commit 180170e45a
4 changed files with 38 additions and 4 deletions

View file

@ -1005,6 +1005,11 @@ static float scrollerWidth;
/* Prepare the contentRect by insetting the borders. */
contentRect = NSInsetRect(_bounds, border.width, border.height);
if (contentRect.size.width < 0 || contentRect.size.height < 0)
{
NSWarnMLog(@"given too small a size to tile", 0);
return;
}
[self _synchronizeHeaderAndCornerView];