Skip to content

Commit

Permalink
Use status window pad settings to calculate width
Browse files Browse the repository at this point in the history
Reported in pekwm#171
  • Loading branch information
pclouds committed Aug 16, 2024
1 parent 8f3e4fe commit c79984a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/StatusWindow.cc
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,9 @@ StatusWindow::draw(const std::string &text, bool do_center, Geometry *gm)
Theme::TextDialogData *sd = _theme->getStatusData();
PFont *font = sd->getFont();

width = font->getWidth(text) + 10;
width = font->getWidth(text)
+ sd->getPad(PAD_LEFT)
+ sd->getPad(PAD_RIGHT);
width = width - (width % 10);
height = font->getHeight()
+ sd->getPad(PAD_UP)
Expand Down

0 comments on commit c79984a

Please sign in to comment.