diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 14 | ||||
| -rw-r--r-- | src/xterm.c | 29 |
2 files changed, 18 insertions, 25 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 53469408d71..258948bf5d3 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,7 +1,19 @@ | |||
| 1 | 2005-03-31 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * xterm.c [HAVE_XAW3D]: Include ThreeD.h for XtNbeNiceToColormap. | ||
| 4 | (x_create_toolkit_scroll_bar): Test XtNbeNiceToColormap before using it. | ||
| 5 | Use XtNtopShadowPixel and XtNbottomShadowPixel. | ||
| 6 | (x_set_toolkit_scroll_bar_thumb): Remove ugly old hack that didn't | ||
| 7 | really work and that breaks with some versions of Xaw3d. | ||
| 8 | |||
| 1 | 2005-03-31 Kenichi Handa <handa@m17n.org> | 9 | 2005-03-31 Kenichi Handa <handa@m17n.org> |
| 2 | 10 | ||
| 3 | * coding.c (syms_of_coding): Fix previous change. | 11 | * coding.c (syms_of_coding): Fix previous change. |
| 4 | 12 | ||
| 13 | 2005-03-30 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 14 | |||
| 15 | * fileio.c (search_embedded_absfilename): Fix last change. | ||
| 16 | |||
| 5 | 2005-03-25 Kenichi Handa <handa@m17n.org> | 17 | 2005-03-25 Kenichi Handa <handa@m17n.org> |
| 6 | 18 | ||
| 7 | * coding.c (syms_of_coding): Suggest to use set-coding-category in | 19 | * coding.c (syms_of_coding): Suggest to use set-coding-category in |
| @@ -30,7 +42,7 @@ | |||
| 30 | 42 | ||
| 31 | 2005-03-26 Lennart Borgman <lennart.borgman.073@student.lu.se> | 43 | 2005-03-26 Lennart Borgman <lennart.borgman.073@student.lu.se> |
| 32 | 44 | ||
| 33 | * w32term.h (x_output): add focus_state. | 45 | * w32term.h (x_output): Add focus_state. |
| 34 | 46 | ||
| 35 | * w32term.c (x_focus_changed, w32_detect_focus_change): New functions. | 47 | * w32term.c (x_focus_changed, w32_detect_focus_change): New functions. |
| 36 | (w32_read_socket) [WM_SETFOCUS]: Call w32_detect_focus_change. | 48 | (w32_read_socket) [WM_SETFOCUS]: Call w32_detect_focus_change. |
diff --git a/src/xterm.c b/src/xterm.c index 609ffefcbbe..fcc4c67743a 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -130,9 +130,7 @@ extern void _XEditResCheckMessages (); | |||
| 130 | #ifdef HAVE_XAW3D | 130 | #ifdef HAVE_XAW3D |
| 131 | #include <X11/Xaw3d/Simple.h> | 131 | #include <X11/Xaw3d/Simple.h> |
| 132 | #include <X11/Xaw3d/Scrollbar.h> | 132 | #include <X11/Xaw3d/Scrollbar.h> |
| 133 | #define ARROW_SCROLLBAR | 133 | #include <X11/Xaw3d/ThreeD.h> |
| 134 | #define XAW_ARROW_SCROLLBARS | ||
| 135 | #include <X11/Xaw3d/ScrollbarP.h> | ||
| 136 | #else /* !HAVE_XAW3D */ | 134 | #else /* !HAVE_XAW3D */ |
| 137 | #include <X11/Xaw/Simple.h> | 135 | #include <X11/Xaw/Simple.h> |
| 138 | #include <X11/Xaw/Scrollbar.h> | 136 | #include <X11/Xaw/Scrollbar.h> |
| @@ -4547,6 +4545,7 @@ x_create_toolkit_scroll_bar (f, bar) | |||
| 4547 | f->output_data.x->scroll_bar_bottom_shadow_pixel = pixel; | 4545 | f->output_data.x->scroll_bar_bottom_shadow_pixel = pixel; |
| 4548 | } | 4546 | } |
| 4549 | 4547 | ||
| 4548 | #ifdef XtNbeNiceToColormap | ||
| 4550 | /* Tell the toolkit about them. */ | 4549 | /* Tell the toolkit about them. */ |
| 4551 | if (f->output_data.x->scroll_bar_top_shadow_pixel == -1 | 4550 | if (f->output_data.x->scroll_bar_top_shadow_pixel == -1 |
| 4552 | || f->output_data.x->scroll_bar_bottom_shadow_pixel == -1) | 4551 | || f->output_data.x->scroll_bar_bottom_shadow_pixel == -1) |
| @@ -4570,16 +4569,17 @@ x_create_toolkit_scroll_bar (f, bar) | |||
| 4570 | pixel = f->output_data.x->scroll_bar_top_shadow_pixel; | 4569 | pixel = f->output_data.x->scroll_bar_top_shadow_pixel; |
| 4571 | if (pixel != -1) | 4570 | if (pixel != -1) |
| 4572 | { | 4571 | { |
| 4573 | XtSetArg (av[ac], "topShadowPixel", pixel); | 4572 | XtSetArg (av[ac], XtNtopShadowPixel, pixel); |
| 4574 | ++ac; | 4573 | ++ac; |
| 4575 | } | 4574 | } |
| 4576 | pixel = f->output_data.x->scroll_bar_bottom_shadow_pixel; | 4575 | pixel = f->output_data.x->scroll_bar_bottom_shadow_pixel; |
| 4577 | if (pixel != -1) | 4576 | if (pixel != -1) |
| 4578 | { | 4577 | { |
| 4579 | XtSetArg (av[ac], "bottomShadowPixel", pixel); | 4578 | XtSetArg (av[ac], XtNbottomShadowPixel, pixel); |
| 4580 | ++ac; | 4579 | ++ac; |
| 4581 | } | 4580 | } |
| 4582 | } | 4581 | } |
| 4582 | #endif | ||
| 4583 | 4583 | ||
| 4584 | widget = XtCreateWidget (scroll_bar_name, scrollbarWidgetClass, | 4584 | widget = XtCreateWidget (scroll_bar_name, scrollbarWidgetClass, |
| 4585 | f->output_data.x->edit_widget, av, ac); | 4585 | f->output_data.x->edit_widget, av, ac); |
| @@ -4725,30 +4725,11 @@ x_set_toolkit_scroll_bar_thumb (bar, portion, position, whole) | |||
| 4725 | XawScrollbarSetThumb (widget, top, shown); | 4725 | XawScrollbarSetThumb (widget, top, shown); |
| 4726 | else | 4726 | else |
| 4727 | { | 4727 | { |
| 4728 | #ifdef HAVE_XAW3D | ||
| 4729 | ScrollbarWidget sb = (ScrollbarWidget) widget; | ||
| 4730 | int scroll_mode = 0; | ||
| 4731 | |||
| 4732 | /* `scroll_mode' only exists with Xaw3d + ARROW_SCROLLBAR. */ | ||
| 4733 | if (xaw3d_arrow_scroll) | ||
| 4734 | { | ||
| 4735 | /* Xaw3d stupidly ignores resize requests while dragging | ||
| 4736 | so we have to make it believe it's not in dragging mode. */ | ||
| 4737 | scroll_mode = sb->scrollbar.scroll_mode; | ||
| 4738 | if (scroll_mode == 2) | ||
| 4739 | sb->scrollbar.scroll_mode = 0; | ||
| 4740 | } | ||
| 4741 | #endif | ||
| 4742 | /* Try to make the scrolling a tad smoother. */ | 4728 | /* Try to make the scrolling a tad smoother. */ |
| 4743 | if (!xaw3d_pick_top) | 4729 | if (!xaw3d_pick_top) |
| 4744 | shown = min (shown, old_shown); | 4730 | shown = min (shown, old_shown); |
| 4745 | 4731 | ||
| 4746 | XawScrollbarSetThumb (widget, top, shown); | 4732 | XawScrollbarSetThumb (widget, top, shown); |
| 4747 | |||
| 4748 | #ifdef HAVE_XAW3D | ||
| 4749 | if (xaw3d_arrow_scroll && scroll_mode == 2) | ||
| 4750 | sb->scrollbar.scroll_mode = scroll_mode; | ||
| 4751 | #endif | ||
| 4752 | } | 4733 | } |
| 4753 | } | 4734 | } |
| 4754 | } | 4735 | } |