diff options
| author | Paul Eggert | 2014-09-10 17:48:57 -0700 |
|---|---|---|
| committer | Paul Eggert | 2014-09-10 17:48:57 -0700 |
| commit | b3ed13e84d591eeb2f0dde2e7c2558e7abcc66ca (patch) | |
| tree | 747ac2d7805b50b1c83be62888a367b2f13061e2 /src/window.h | |
| parent | fe252976a18bf7bb66009fa80c1c6f02b124404f (diff) | |
| download | emacs-b3ed13e84d591eeb2f0dde2e7c2558e7abcc66ca.tar.gz emacs-b3ed13e84d591eeb2f0dde2e7c2558e7abcc66ca.zip | |
Pacify --enable-gcc-warnings when no window system is used.
These warnings found that subscript error, so they seem worthwhile.
* composite.c (char_composable_p): Simplify a bit.
* frame.c (x_set_frame_parameters): Add an IF_LINT.
* frame.c (x_set_horizontal_scroll_bars, x_set_scroll_bar_height):
* frame.h (FRAME_HAS_HORIZONTAL_SCROLL_BARS):
* window.c (set_window_scroll_bars):
Use USE_HORIZONTAL_SCROLL_BARS for simplicity.
* frame.h [! USE_HORIZONTAL_SCROLL_BARS]:
Ignore -Wsuggest-attribute=const.
* window.h (USE_HORIZONTAL_SCROLL_BARS): New macro.
(WINDOW_HAS_HORIZONTAL_SCROLL_BAR): Use it.
Diffstat (limited to 'src/window.h')
| -rw-r--r-- | src/window.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/window.h b/src/window.h index 7e1c7d619b9..ea5dddc9fc8 100644 --- a/src/window.h +++ b/src/window.h | |||
| @@ -785,11 +785,17 @@ wset_next_buffers (struct window *w, Lisp_Object val) | |||
| 785 | (WINDOW_HAS_VERTICAL_SCROLL_BAR_ON_LEFT (W) \ | 785 | (WINDOW_HAS_VERTICAL_SCROLL_BAR_ON_LEFT (W) \ |
| 786 | || WINDOW_HAS_VERTICAL_SCROLL_BAR_ON_RIGHT (W)) | 786 | || WINDOW_HAS_VERTICAL_SCROLL_BAR_ON_RIGHT (W)) |
| 787 | 787 | ||
| 788 | /* Say whether horizontal scroll bars are currently enabled for window | ||
| 789 | W. Horizontal scrollbars exist for toolkit versions only. */ | ||
| 790 | #if (defined (HAVE_WINDOW_SYSTEM) \ | 788 | #if (defined (HAVE_WINDOW_SYSTEM) \ |
| 791 | && ((defined (USE_TOOLKIT_SCROLL_BARS) && !defined (HAVE_NS)) \ | 789 | && ((defined (USE_TOOLKIT_SCROLL_BARS) && !defined (HAVE_NS)) \ |
| 792 | || defined (HAVE_NTGUI))) | 790 | || defined (HAVE_NTGUI))) |
| 791 | # define USE_HORIZONTAL_SCROLL_BARS true | ||
| 792 | #else | ||
| 793 | # define USE_HORIZONTAL_SCROLL_BARS false | ||
| 794 | #endif | ||
| 795 | |||
| 796 | /* Say whether horizontal scroll bars are currently enabled for window | ||
| 797 | W. Horizontal scrollbars exist for toolkit versions only. */ | ||
| 798 | #if USE_HORIZONTAL_SCROLL_BARS | ||
| 793 | #define WINDOW_HAS_HORIZONTAL_SCROLL_BAR(W) \ | 799 | #define WINDOW_HAS_HORIZONTAL_SCROLL_BAR(W) \ |
| 794 | ((WINDOW_PSEUDO_P (W) || MINI_NON_ONLY_WINDOW_P (W)) \ | 800 | ((WINDOW_PSEUDO_P (W) || MINI_NON_ONLY_WINDOW_P (W)) \ |
| 795 | ? false \ | 801 | ? false \ |