]> source.dussan.org Git - tigervnc.git/commitdiff
Get correct text width for overlay
authorPierre Ossman <ossman@cendio.se>
Fri, 24 Feb 2017 08:23:47 +0000 (09:23 +0100)
committerPierre Ossman <ossman@cendio.se>
Fri, 24 Feb 2017 08:23:47 +0000 (09:23 +0100)
Incoming width specifies wrapping width, and we do not want any wrapping.

vncviewer/DesktopWindow.cxx

index acb0a729cb26f50da64908d691e1398cd08f78fd..8fdd59b7efb130109d1e84eca0b797dc20149818 100644 (file)
@@ -484,6 +484,7 @@ void DesktopWindow::setOverlay(const char* text, ...)
 #endif
 
   fl_font(FL_HELVETICA, FL_NORMAL_SIZE * 2);
+  w = 0;
   fl_measure(textbuf, w, h);
 
   // Margins