Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
d75a4842
Commit
d75a4842
authored
Sep 10, 2006
by
Kim F. Storm
Browse files
(get_window_cursor_type): Use hollow cursor on
non-transparent images.
parent
1d7b95f5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
src/xdisp.c
src/xdisp.c
+4
-2
No files found.
src/xdisp.c
View file @
d75a4842
...
...
@@ -21248,14 +21248,16 @@ get_window_cursor_type (w, glyph, width, active_cursor)
if (cursor_type == FILLED_BOX_CURSOR)
{
/* Using a block cursor on large images can be very annoying.
So use a hollow cursor for "large" images. */
So use a hollow cursor for "large" images.
If image is not transparent (no mask), also use hollow cursor. */
struct image *img = IMAGE_FROM_ID (f, glyph->u.img_id);
if (img != NULL && IMAGEP (img->spec))
{
/* Arbitrarily, interpret "Large" as >32x32 and >NxN
where N = size of default frame font size.
This should cover most of the "tiny" icons people may use. */
if (img->width > max (32, WINDOW_FRAME_COLUMN_WIDTH (w))
if (!img->mask
|| img->width > max (32, WINDOW_FRAME_COLUMN_WIDTH (w))
|| img->height > max (32, WINDOW_FRAME_LINE_HEIGHT (w)))
cursor_type = HOLLOW_BOX_CURSOR;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment