aboutsummaryrefslogtreecommitdiffstats
path: root/src/xfns.c
diff options
context:
space:
mode:
authorGerd Moellmann <[email protected]>2000-03-08 14:48:16 +0000
committerGerd Moellmann <[email protected]>2000-03-08 14:48:16 +0000
commit08ac8554879dbb254972cc7e40e0ec62d807a533 (patch)
tree3bf2ceeda8a9b9a81c3efb3b4dd606e755dbd472 /src/xfns.c
parent8256e31b785fe5a31c5973c4448b36a9a7afbe2b (diff)
(x_set_cursor_type): If ARG is nil, give frame no cursor.
Diffstat (limited to 'src/xfns.c')
-rw-r--r--src/xfns.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/xfns.c b/src/xfns.c
index 7f88e22703..0282f651d0 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -1695,12 +1695,16 @@ x_set_cursor_type (f, arg, oldval)
FRAME_DESIRED_CURSOR (f) = BAR_CURSOR;
f->output_data.x->cursor_width = 2;
}
- else if (CONSP (arg) && EQ (XCAR (arg), Qbar)
- && INTEGERP (XCDR (arg)))
+ else if (CONSP (arg)
+ && EQ (XCAR (arg), Qbar)
+ && INTEGERP (XCDR (arg))
+ && XINT (XCDR (arg)) >= 0)
{
FRAME_DESIRED_CURSOR (f) = BAR_CURSOR;
f->output_data.x->cursor_width = XINT (XCDR (arg));
}
+ else if (NILP (arg))
+ FRAME_DESIRED_CURSOR (f) = NO_CURSOR;
else
/* Treat anything unknown as "box cursor".
It was bad to signal an error; people have trouble fixing