Use consistent font when displaying menu equivalent keys on Haiku
* src/haiku_support.cc (DrawContent): Set plain font when drawing key text.
This commit is contained in:
parent
310bcda934
commit
2886520160
1 changed files with 8 additions and 2 deletions
|
@ -1679,11 +1679,17 @@ class EmacsMenuItem : public BMenuItem
|
|||
|
||||
if (key)
|
||||
{
|
||||
BRect r = menu->Frame ();
|
||||
int w = menu->StringWidth (key);
|
||||
BRect r = Frame ();
|
||||
int w;
|
||||
|
||||
menu->PushState ();
|
||||
menu->ClipToRect (r);
|
||||
menu->SetFont (be_plain_font);
|
||||
w = menu->StringWidth (key);
|
||||
menu->MovePenTo (BPoint (BE_RECT_WIDTH (r) - w - 4,
|
||||
menu->PenLocation ().y));
|
||||
menu->DrawString (key);
|
||||
menu->PopState ();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue