Browse Source

Add 10 pixels to tooltip because of Retina text width bug

tags/v0.6.1
Andrew Belt 6 years ago
parent
commit
751568f31f
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      src/ui/Tooltip.cpp

+ 1
- 1
src/ui/Tooltip.cpp View File

@@ -10,7 +10,7 @@ Tooltip::Tooltip() {

void Tooltip::draw(NVGcontext *vg) {
// Wrap size to contents
box.size.x = bndLabelWidth(vg, -1, text.c_str());
box.size.x = bndLabelWidth(vg, -1, text.c_str()) + 10.0;
box.size.y = bndLabelHeight(vg, -1, text.c_str(), INFINITY);

bndTooltipBackground(vg, 0.0, 0.0, box.size.x, box.size.y);


Loading…
Cancel
Save