diff options
| author | Stefan Monnier | 2004-11-16 15:41:41 +0000 |
|---|---|---|
| committer | Stefan Monnier | 2004-11-16 15:41:41 +0000 |
| commit | 94c4db3c609d6c84f8ffe413736819e1af7e1a87 (patch) | |
| tree | aa51877ef36e937884dfa9e762a67a4e9e0c37aa | |
| parent | dda01a4c9c8b1c35026c6a60ecd73d9ec1dea5ed (diff) | |
| download | emacs-94c4db3c609d6c84f8ffe413736819e1af7e1a87.tar.gz emacs-94c4db3c609d6c84f8ffe413736819e1af7e1a87.zip | |
(get_glyph_string_clip_rect, init_glyph_string): Check it's
a window before using XWINDOW.
| -rw-r--r-- | src/xdisp.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index e4e303941ef..2620485bbe3 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -1789,7 +1789,8 @@ get_glyph_string_clip_rect (s, nr) | |||
| 1789 | 1789 | ||
| 1790 | /* If drawing a tool-bar window, draw it over the internal border | 1790 | /* If drawing a tool-bar window, draw it over the internal border |
| 1791 | at the top of the window. */ | 1791 | at the top of the window. */ |
| 1792 | if (s->w == XWINDOW (s->f->tool_bar_window)) | 1792 | if (WINDOWP (s->f->tool_bar_window) |
| 1793 | && s->w == XWINDOW (s->f->tool_bar_window)) | ||
| 1793 | r.y -= FRAME_INTERNAL_BORDER_WIDTH (s->f); | 1794 | r.y -= FRAME_INTERNAL_BORDER_WIDTH (s->f); |
| 1794 | } | 1795 | } |
| 1795 | 1796 | ||
| @@ -17294,7 +17295,8 @@ init_glyph_string (s, OPTIONAL_HDC (hdc) char2b, w, row, area, start, hl) | |||
| 17294 | s->y = WINDOW_TO_FRAME_PIXEL_Y (w, row->y); | 17295 | s->y = WINDOW_TO_FRAME_PIXEL_Y (w, row->y); |
| 17295 | 17296 | ||
| 17296 | /* Display the internal border below the tool-bar window. */ | 17297 | /* Display the internal border below the tool-bar window. */ |
| 17297 | if (s->w == XWINDOW (s->f->tool_bar_window)) | 17298 | if (WINDOWP (s->f->tool_bar_window) |
| 17299 | && s->w == XWINDOW (s->f->tool_bar_window)) | ||
| 17298 | s->y -= FRAME_INTERNAL_BORDER_WIDTH (s->f); | 17300 | s->y -= FRAME_INTERNAL_BORDER_WIDTH (s->f); |
| 17299 | 17301 | ||
| 17300 | s->ybase = s->y + row->ascent; | 17302 | s->ybase = s->y + row->ascent; |