aboutsummaryrefslogtreecommitdiffstats
path: root/src/androidterm.h
diff options
context:
space:
mode:
authorPo Lu2024-04-23 15:57:45 +0800
committerPo Lu2024-04-23 15:57:45 +0800
commitcd7456e00d719d32c203c71b4e23c98b0c4e1967 (patch)
tree496bdb8d0a1f49aa4668d68c08e2f9309fd1868a /src/androidterm.h
parentb9c191d690fd5d1480858469df23cc4509996fae (diff)
downloademacs-cd7456e00d719d32c203c71b4e23c98b0c4e1967.tar.gz
emacs-cd7456e00d719d32c203c71b4e23c98b0c4e1967.zip
Enable configuring Emacs for "pseudo-grayscale" systems on Android
* doc/emacs/android.texi (Android Windowing): Document how to configure Emacs for monochrome displays. * src/androidfns.c (Fx_display_visual_class): Return Qstatic_gray when n_planes is smaller than 24. (Fandroid_get_connection): Set n_planes by the value of android_display_planes. (syms_of_androidfns): <Qstatic_gray>: New function. * src/androidterm.c (android_alloc_nearest_color): Allocate monochrome colors similarly to the X server. (android_query_colors): Fix typos. (android_draw_fringe_bitmap): Create bitmaps of n_image_planes depth. (android_term_init): Initialize n_image_planes to 24. (syms_of_androidterm) <android_display_planes>: New variable. * src/androidterm.h (struct android_display_info): New field `n_image_planes'. * src/image.c (n_planes) [HAVE_ANDROID]: Define to n_image_planes.
Diffstat (limited to 'src/androidterm.h')
-rw-r--r--src/androidterm.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/androidterm.h b/src/androidterm.h
index fd4cc99f641..24eb2c30f12 100644
--- a/src/androidterm.h
+++ b/src/androidterm.h
@@ -77,8 +77,9 @@ struct android_display_info
77 /* Mouse highlight information. */ 77 /* Mouse highlight information. */
78 Mouse_HLInfo mouse_highlight; 78 Mouse_HLInfo mouse_highlight;
79 79
80 /* Number of planes on this screen. Always 24. */ 80 /* Number of planes on this screen, and the same for the purposes of
81 int n_planes; 81 image processing. */
82 int n_planes, n_image_planes;
82 83
83 /* Mask of things causing the mouse to be grabbed. */ 84 /* Mask of things causing the mouse to be grabbed. */
84 int grabbed; 85 int grabbed;