From 010ff656ec07201a811571830de04bfa2c85676a Mon Sep 17 00:00:00 2001 From: Felix Domke Date: Mon, 23 Mar 2009 00:31:55 +0100 Subject: [PATCH 1/1] add some debug assertions --- lib/gdi/font.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/gdi/font.cpp b/lib/gdi/font.cpp index 450269f0..6a6007ee 100644 --- a/lib/gdi/font.cpp +++ b/lib/gdi/font.cpp @@ -510,7 +510,12 @@ int eTextPara::renderString(const char *string, int rflags) if (!current_font) return -1; - + + if (!current_face) + eFatal("eTextPara::renderString: no current_face"); + if (!current_face->size) + eFatal("eTextPara::renderString: no current_face->size"); + if (cursor.y()==-1) { cursor=ePoint(area.x(), area.y()+(current_face->size->metrics.ascender>>6)); -- 2.30.2