diff options
| author | Jan Djärv | 2009-12-13 15:39:28 +0000 |
|---|---|---|
| committer | Jan Djärv | 2009-12-13 15:39:28 +0000 |
| commit | 36acb2a70642e7395b3fa8f45291c7828718b392 (patch) | |
| tree | 342175657f5a9a406355bcd2dab8426ad4efd570 /src | |
| parent | b8f0067758d1710e580f55f60ab70cd073f7fa79 (diff) | |
| download | emacs-36acb2a70642e7395b3fa8f45291c7828718b392.tar.gz emacs-36acb2a70642e7395b3fa8f45291c7828718b392.zip | |
Set the extended window manager hint for tooltip windows.
* xfns.c (x_create_tip_frame): Set the extended window manager hint for
tooltip windows.
* xterm.h (struct x_display_info): Add Xatom_net_window_type_tooltip and
Xatom_net_window_type.
* xterm.c (x_term_init): Initialize Xatom_net_window_type_tooltip and
Xatom_net_window_type.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 11 | ||||
| -rw-r--r-- | src/xfns.c | 5 | ||||
| -rw-r--r-- | src/xterm.c | 6 | ||||
| -rw-r--r-- | src/xterm.h | 4 |
4 files changed, 24 insertions, 2 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 692db938e61..a143e1d5739 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,5 +1,16 @@ | |||
| 1 | 2009-12-13 Pat Thoyts <patthoyts@users.sourceforge.net> (tiny change) | ||
| 2 | |||
| 3 | * xfns.c (x_create_tip_frame): Set the extended window manager hint for | ||
| 4 | tooltip windows. | ||
| 5 | |||
| 1 | 2009-12-13 Jan Djärv <jan.h.d@swipnet.se> | 6 | 2009-12-13 Jan Djärv <jan.h.d@swipnet.se> |
| 2 | 7 | ||
| 8 | * xterm.h (struct x_display_info): Add Xatom_net_window_type_tooltip and | ||
| 9 | Xatom_net_window_type. | ||
| 10 | |||
| 11 | * xterm.c (x_term_init): Initialize Xatom_net_window_type_tooltip and | ||
| 12 | Xatom_net_window_type. | ||
| 13 | |||
| 3 | * xterm.c (my_log_handler): New function. | 14 | * xterm.c (my_log_handler): New function. |
| 4 | (x_term_init): Set my_log_handler as log handler during gtk_init | 15 | (x_term_init): Set my_log_handler as log handler during gtk_init |
| 5 | so we can filter out buggy messages. (bug #5120). | 16 | so we can filter out buggy messages. (bug #5120). |
diff --git a/src/xfns.c b/src/xfns.c index 27d0b025a24..b886a3ff674 100644 --- a/src/xfns.c +++ b/src/xfns.c | |||
| @@ -4825,6 +4825,7 @@ x_create_tip_frame (dpyinfo, parms, text) | |||
| 4825 | { | 4825 | { |
| 4826 | XSetWindowAttributes attrs; | 4826 | XSetWindowAttributes attrs; |
| 4827 | unsigned long mask; | 4827 | unsigned long mask; |
| 4828 | Atom type = FRAME_X_DISPLAY_INFO (f)->Xatom_net_window_type_tooltip; | ||
| 4828 | 4829 | ||
| 4829 | BLOCK_INPUT; | 4830 | BLOCK_INPUT; |
| 4830 | mask = CWBackPixel | CWOverrideRedirect | CWEventMask; | 4831 | mask = CWBackPixel | CWOverrideRedirect | CWEventMask; |
| @@ -4849,6 +4850,10 @@ x_create_tip_frame (dpyinfo, parms, text) | |||
| 4849 | f->border_width, | 4850 | f->border_width, |
| 4850 | CopyFromParent, InputOutput, CopyFromParent, | 4851 | CopyFromParent, InputOutput, CopyFromParent, |
| 4851 | mask, &attrs); | 4852 | mask, &attrs); |
| 4853 | XChangeProperty (FRAME_X_DISPLAY (f), tip_window, | ||
| 4854 | FRAME_X_DISPLAY_INFO (f)->Xatom_net_window_type, | ||
| 4855 | XA_ATOM, 32, PropModeReplace, | ||
| 4856 | (unsigned char *)&type, 1); | ||
| 4852 | UNBLOCK_INPUT; | 4857 | UNBLOCK_INPUT; |
| 4853 | } | 4858 | } |
| 4854 | 4859 | ||
diff --git a/src/xterm.c b/src/xterm.c index dee6190e755..7f9f6f3c05e 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -10445,7 +10445,11 @@ x_term_init (display_name, xrm_option, resource_name) | |||
| 10445 | = XInternAtom (dpyinfo->display, "_NET_WM_STATE_MAXIMIZED_VERT", False); | 10445 | = XInternAtom (dpyinfo->display, "_NET_WM_STATE_MAXIMIZED_VERT", False); |
| 10446 | dpyinfo->Xatom_net_wm_state_sticky | 10446 | dpyinfo->Xatom_net_wm_state_sticky |
| 10447 | = XInternAtom (dpyinfo->display, "_NET_WM_STATE_STICKY", False); | 10447 | = XInternAtom (dpyinfo->display, "_NET_WM_STATE_STICKY", False); |
| 10448 | 10448 | dpyinfo->Xatom_net_window_type | |
| 10449 | = XInternAtom (dpyinfo->display, "_NET_WM_WINDOW_TYPE", False); | ||
| 10450 | dpyinfo->Xatom_net_window_type_tooltip | ||
| 10451 | = XInternAtom (dpyinfo->display, "_NET_WM_WINDOW_TYPE_TOOLTIP", False); | ||
| 10452 | |||
| 10449 | dpyinfo->cut_buffers_initialized = 0; | 10453 | dpyinfo->cut_buffers_initialized = 0; |
| 10450 | 10454 | ||
| 10451 | dpyinfo->x_dnd_atoms_size = 8; | 10455 | dpyinfo->x_dnd_atoms_size = 8; |
diff --git a/src/xterm.h b/src/xterm.h index 1ad2a097016..6c6de8d901d 100644 --- a/src/xterm.h +++ b/src/xterm.h | |||
| @@ -355,10 +355,12 @@ struct x_display_info | |||
| 355 | size_t x_dnd_atoms_size; | 355 | size_t x_dnd_atoms_size; |
| 356 | size_t x_dnd_atoms_length; | 356 | size_t x_dnd_atoms_length; |
| 357 | 357 | ||
| 358 | /* Extended window manager hints, Atoms supported by the window manager */ | 358 | /* Extended window manager hints, Atoms supported by the window manager and |
| 359 | atoms for settig the window type. */ | ||
| 359 | Atom *net_supported_atoms; | 360 | Atom *net_supported_atoms; |
| 360 | int nr_net_supported_atoms; | 361 | int nr_net_supported_atoms; |
| 361 | Window net_supported_window; | 362 | Window net_supported_window; |
| 363 | Atom Xatom_net_window_type, Xatom_net_window_type_tooltip; | ||
| 362 | 364 | ||
| 363 | /* Atoms dealing with maximization and fullscreen */ | 365 | /* Atoms dealing with maximization and fullscreen */ |
| 364 | Atom Xatom_net_wm_state, Xatom_net_wm_state_fullscreen_atom, | 366 | Atom Xatom_net_wm_state, Xatom_net_wm_state_fullscreen_atom, |