mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-22 13:10:59 +00:00
Add extra pixels to tooltip
This commit is contained in:
parent
58359b8de3
commit
e9548dd057
2 changed files with 9 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
2021-10-27 Gregory John Casamento <greg.casamento@gmail.com>
|
||||
|
||||
* Source/GSToolTips.m: Add extra pixels so that tool tip doesn't
|
||||
overrun the window.
|
||||
|
||||
2021-10-25 Riccardo Mottola <rm@gnu.org>
|
||||
|
||||
* Source/NSTextStorage.m:
|
||||
|
|
|
@ -649,10 +649,12 @@ static BOOL restoreMouseMoved;
|
|||
rect = [toolTipText boundingRectWithSize: NSMakeSize(300, 1e7)
|
||||
options: 0];
|
||||
textSize = rect.size;
|
||||
// This extra pixel is needed, otherwise the last line gets cut off.
|
||||
textSize.height += 1;
|
||||
}
|
||||
|
||||
// Need to fudge the result just a bit due to occasionally cutoff characters...
|
||||
textSize.width += 1;
|
||||
textSize.height += 1;
|
||||
|
||||
/* Create window just off the current mouse position
|
||||
* Constrain it to be on screen, shrinking if necessary.
|
||||
*/
|
||||
|
|
Loading…
Reference in a new issue