summaryrefslogtreecommitdiff
path: root/src/XawIm.c
diff options
context:
space:
mode:
authorAlexander Gottwald <alexander.gottwald@s1999.tu-chemnitz.de>2005-02-11 10:53:09 +0000
committerAlexander Gottwald <alexander.gottwald@s1999.tu-chemnitz.de>2005-02-11 10:53:09 +0000
commit9a9e4ed7a8530a77937efd695c6123d886fe6677 (patch)
tree6fa5c1fae2367eb93edf6ada3beada3f95f2bb00 /src/XawIm.c
parentfcde358d5e3b62bcf1d5e488e8021db8340eef5f (diff)
downloadxorg-lib-libXaw-CYGWIN.tar.gz
Import changes from XORG-6.8.2CYGWIN-6_8_2-MERGECYGWIN
Diffstat (limited to 'src/XawIm.c')
-rw-r--r--src/XawIm.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/XawIm.c b/src/XawIm.c
index 69c2f99..06f94ef 100644
--- a/src/XawIm.c
+++ b/src/XawIm.c
@@ -808,8 +808,10 @@ CreateIC(Widget w, XawVendorShellExtPart *ve)
pe_a[pe_cnt] = (XPointer) p->font_set; pe_cnt++;
st_a[st_cnt] = (XPointer) XNFontSet; st_cnt++;
st_a[st_cnt] = (XPointer) p->font_set; st_cnt++;
- height = maxAscentOfFontSet(p->font_set)
- + maxDescentOfFontSet(p->font_set);
+ if (p->font_set) {
+ height = maxAscentOfFontSet(p->font_set)
+ + maxDescentOfFontSet(p->font_set);
+ }
height = SetVendorShellHeight(ve, height);
}
if (p->flg & CIFg) {
@@ -938,7 +940,7 @@ SetICValues(Widget w, XawVendorShellExtPart *ve, Bool focus)
XPointer ic_a[20], pe_a[20], st_a[20];
int ic_cnt = 0, pe_cnt = 0, st_cnt = 0;
XawTextMargin *margin;
- int height;
+ int height = 0;
if ((ve->im.xim == NULL) || ((p = GetIcTableShared(w, ve)) == NULL) ||
(p->xic == NULL)) return;
@@ -965,8 +967,10 @@ SetICValues(Widget w, XawVendorShellExtPart *ve, Bool focus)
pe_a[pe_cnt] = (XPointer) p->font_set; pe_cnt++;
st_a[st_cnt] = (XPointer) XNFontSet; st_cnt++;
st_a[st_cnt] = (XPointer) p->font_set; st_cnt++;
- height = maxAscentOfFontSet(p->font_set)
- + maxDescentOfFontSet(p->font_set);
+ if (p->font_set) {
+ height = maxAscentOfFontSet(p->font_set)
+ + maxDescentOfFontSet(p->font_set);
+ }
height = SetVendorShellHeight(ve, height);
}
if (p->flg & CIFg) {