summaryrefslogtreecommitdiff
path: root/src/drivers/Xlib
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2016-04-17 18:07:11 +0000
committerMatthias Melcher <fltk@matthiasm.com>2016-04-17 18:07:11 +0000
commit6818216c3047b7eea83138670f7bb6d02e7314b2 (patch)
tree62c929995781bacf4455228e30d93f81e9bcec05 /src/drivers/Xlib
parente2495a760a7c5987724467923b9beb57c50ccfeb (diff)
Fixes for Linux for recent commits.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11645 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/drivers/Xlib')
-rw-r--r--src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx31
1 files changed, 17 insertions, 14 deletions
diff --git a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx
index 2181e43e0..fbda18630 100644
--- a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx
+++ b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx
@@ -28,6 +28,9 @@
#include <X11/extensions/Xrender.h>
#endif
+extern XIC fl_xim_ic;
+extern char fl_is_over_the_spot;
+
/*
* By linking this module, the following static method will instantiate the
@@ -119,14 +122,14 @@ void Fl_Xlib_Graphics_Driver::fixloop() { // remove equal points from closed pa
}
// FIXME: should be members of Fl_Xlib_Graphics_Driver
-static XRectangle spot;
-static int spotf = -1;
-static int spots = -1;
+XRectangle fl_spot;
+int fl_spotf = -1;
+int fl_spots = -1;
void Fl_Xlib_Graphics_Driver::reset_spot(void)
{
- spot.x = -1;
- spot.y = -1;
+ fl_spot.x = -1;
+ fl_spot.y = -1;
//if (fl_xim_ic) XUnsetICFocus(fl_xim_ic);
}
@@ -145,16 +148,16 @@ void Fl_Xlib_Graphics_Driver::set_spot(int font, int size, int X, int Y, int W,
if (!fl_xim_ic || !fl_is_over_the_spot) return;
//XSetICFocus(fl_xim_ic);
- if (X != spot.x || Y != spot.y) {
- spot.x = X;
- spot.y = Y;
- spot.height = H;
- spot.width = W;
+ if (X != fl_spot.x || Y != fl_spot.y) {
+ fl_spot.x = X;
+ fl_spot.y = Y;
+ fl_spot.height = H;
+ fl_spot.width = W;
change = 1;
}
- if (font != spotf || size != spots) {
- spotf = font;
- spots = size;
+ if (font != fl_spotf || size != fl_spots) {
+ fl_spotf = font;
+ fl_spots = size;
change = 1;
if (fs) {
XFreeFontSet(fl_display, fs);
@@ -186,7 +189,7 @@ void Fl_Xlib_Graphics_Driver::set_spot(int font, int size, int X, int Y, int W,
preedit_attr = XVaCreateNestedList(0,
- XNSpotLocation, &spot,
+ XNSpotLocation, &fl_spot,
XNFontSet, fs, NULL);
XSetICValues(fl_xim_ic, XNPreeditAttributes, preedit_attr, NULL);
XFree(preedit_attr);