Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
5ee6f629
Commit
5ee6f629
authored
Jun 14, 2009
by
David Reitter
Browse files
nsmenu.m (EmacsTooltip: setText): set height of tooltip.
parent
4b7f335c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
src/ChangeLog
src/ChangeLog
+4
-0
src/nsmenu.m
src/nsmenu.m
+8
-1
No files found.
src/ChangeLog
View file @
5ee6f629
2009-06-14 Sidney Markowitz <sidney@sidney.com>
* nsmenu.m (EmacsTooltip: setText): set height of tooltip.
2009-06-14 Adrian Robert <Adrian.B.Robert@gmail.com>
* nsfont.m (ns_attribute_value): Remove.
...
...
src/nsmenu.m
View file @
5ee6f629
...
...
@@ -1439,7 +1439,14 @@ - (void) setText: (char *)text
{
NSString
*
str
=
[
NSString
stringWithUTF8String
:
text
];
NSRect
r
=
[
textField
frame
];
r
.
size
.
width
=
[[[
textField
font
]
screenFont
]
widthOfString
:
str
]
+
8
;
NSSize
textSize
=
[
str
sizeWithAttributes
:
[
NSDictionary
dictionaryWithObject
:
[[
textField
font
]
screenFont
]
forKey:
NSFontAttributeName
]];
NSSize
padSize
=
[[[
textField
font
]
screenFont
]
boundingRectForFont
].
size
;
r
.
size
.
width
=
textSize
.
width
+
padSize
.
width
/
2
;
r
.
size
.
height
=
textSize
.
height
+
padSize
.
height
/
2
;
[
textField
setFrame
:
r
];
[
textField
setStringValue
:
str
];
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment