From 05c0bfc8f87c62001f9dadef70453364ccbe1590 Mon Sep 17 00:00:00 2001 From: fluxgen Date: Tue, 10 Aug 2004 11:58:22 +0000 Subject: Minor fix --- src/FbTk/XFontImp.cc | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/FbTk/XFontImp.cc b/src/FbTk/XFontImp.cc index 0a1ea7d..195730d 100644 --- a/src/FbTk/XFontImp.cc +++ b/src/FbTk/XFontImp.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: XFontImp.cc,v 1.7 2004/06/07 11:46:05 rathnor Exp $ +// $Id: XFontImp.cc,v 1.8 2004/08/10 11:58:22 fluxgen Exp $ #include "XFontImp.hh" #include "App.hh" @@ -90,10 +90,9 @@ void XFontImp::drawText(Drawable w, int screen, GC gc, const char *text, size_t } unsigned int XFontImp::textWidth(const char * const text, unsigned int size) const { - if (text == 0) - return 0; - if (m_fontstruct == 0) + if (text == 0 || m_fontstruct == 0) return 0; + // check rotated font? if (m_rotfont != 0) return rotTextWidth(text, size); -- cgit v0.11.2