diff options
| author | Dmitry Antipov | 2013-09-12 10:29:13 +0400 |
|---|---|---|
| committer | Dmitry Antipov | 2013-09-12 10:29:13 +0400 |
| commit | 8ffbc36b766d463cb4d86b6c2e5c9054a9c91234 (patch) | |
| tree | 6e329dd7188fb66063e59dd59483ed35853ae56c /src | |
| parent | a6ae021fd380c089f25ebbc341fb1c989827ae32 (diff) | |
| download | emacs-8ffbc36b766d463cb4d86b6c2e5c9054a9c91234.tar.gz emacs-8ffbc36b766d463cb4d86b6c2e5c9054a9c91234.zip | |
* xterm.c (x_set_scroll_bar_thumb) [USE_LUCID && !HAVE_XAW3D]: Clip
scroll bar values to prevent thumb from disappear and update comment.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/xterm.c | 15 |
2 files changed, 17 insertions, 3 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index e1276f54d03..88aa22b30dc 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2013-09-12 Dmitry Antipov <dmantipov@yandex.ru> | ||
| 2 | |||
| 3 | * xterm.c (x_set_scroll_bar_thumb) [USE_LUCID && !HAVE_XAW3D]: Clip | ||
| 4 | scroll bar values to prevent thumb from disappear and update comment. | ||
| 5 | |||
| 1 | 2013-09-11 Glenn Morris <rgm@gnu.org> | 6 | 2013-09-11 Glenn Morris <rgm@gnu.org> |
| 2 | 7 | ||
| 3 | * emacs.c (usage_message): Possessive apostrophe tweak. | 8 | * emacs.c (usage_message): Possessive apostrophe tweak. |
diff --git a/src/xterm.c b/src/xterm.c index 7ad790edd61..cd60915e056 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -4798,12 +4798,21 @@ x_set_toolkit_scroll_bar_thumb (struct scroll_bar *bar, int portion, int positio | |||
| 4798 | top = max (0, min (1, top)); | 4798 | top = max (0, min (1, top)); |
| 4799 | else | 4799 | else |
| 4800 | top = old_top; | 4800 | top = old_top; |
| 4801 | #if ! defined (HAVE_XAW3D) | ||
| 4802 | /* With Xaw, 'top' values too closer to 1.0 may | ||
| 4803 | cause the thumb to disappear. Fix that. */ | ||
| 4804 | top = min (top, 0.99f); | ||
| 4805 | #endif | ||
| 4801 | /* Keep two pixels available for moving the thumb down. */ | 4806 | /* Keep two pixels available for moving the thumb down. */ |
| 4802 | shown = max (0, min (1 - top - (2.0f / height), shown)); | 4807 | shown = max (0, min (1 - top - (2.0f / height), shown)); |
| 4808 | #if ! defined (HAVE_XAW3D) | ||
| 4809 | /* Likewise with too small 'shown'. */ | ||
| 4810 | shown = max (shown, 0.01f); | ||
| 4811 | #endif | ||
| 4803 | 4812 | ||
| 4804 | /* If the call to XawScrollbarSetThumb below doesn't seem to work, | 4813 | /* If the call to XawScrollbarSetThumb below doesn't seem to |
| 4805 | check that your system's configuration file contains a define | 4814 | work, check that 'NARROWPROTO' is defined in src/config.h. |
| 4806 | for `NARROWPROTO'. See s/freebsd.h for an example. */ | 4815 | If this is not so, most likely you need to fix configure. */ |
| 4807 | if (top != old_top || shown != old_shown) | 4816 | if (top != old_top || shown != old_shown) |
| 4808 | { | 4817 | { |
| 4809 | if (bar->dragging == -1) | 4818 | if (bar->dragging == -1) |