comparison src/xterm.c @ 33958:f86c06451792

(note_mouse_highlight): Change the cursor shape on the vertical border between windows.
author Gerd Moellmann <gerd@gnu.org>
date Tue, 28 Nov 2000 13:45:56 +0000
parents 047804baee1c
children 8702e88a1669
comparison
equal deleted inserted replaced
33957:1436ae066de4 33958:f86c06451792
6502 *y = FRAME_TO_WINDOW_PIXEL_Y (w, *y); 6502 *y = FRAME_TO_WINDOW_PIXEL_Y (w, *y);
6503 } 6503 }
6504 } 6504 }
6505 6505
6506 6506
6507 /* Take proper action when mouse has moved to the mode or top line of 6507 /* Take proper action when mouse has moved to the mode or header line of
6508 window W, x-position X. MODE_LINE_P non-zero means mouse is on the 6508 window W, x-position X. MODE_LINE_P non-zero means mouse is on the
6509 mode line. X is relative to the start of the text display area of 6509 mode line. X is relative to the start of the text display area of
6510 W, so the width of bitmap areas and scroll bars must be subtracted 6510 W, so the width of bitmap areas and scroll bars must be subtracted
6511 to get a position relative to the start of the mode line. */ 6511 to get a position relative to the start of the mode line. */
6512 6512
6522 6522
6523 if (mode_line_p) 6523 if (mode_line_p)
6524 row = MATRIX_MODE_LINE_ROW (w->current_matrix); 6524 row = MATRIX_MODE_LINE_ROW (w->current_matrix);
6525 else 6525 else
6526 row = MATRIX_HEADER_LINE_ROW (w->current_matrix); 6526 row = MATRIX_HEADER_LINE_ROW (w->current_matrix);
6527 6527
6528 if (row->enabled_p) 6528 if (row->enabled_p)
6529 { 6529 {
6530 struct glyph *glyph, *end; 6530 struct glyph *glyph, *end;
6531 Lisp_Object help, map; 6531 Lisp_Object help, map;
6532 int x0; 6532 int x0;
6534 /* Find the glyph under X. */ 6534 /* Find the glyph under X. */
6535 glyph = row->glyphs[TEXT_AREA]; 6535 glyph = row->glyphs[TEXT_AREA];
6536 end = glyph + row->used[TEXT_AREA]; 6536 end = glyph + row->used[TEXT_AREA];
6537 x0 = - (FRAME_LEFT_SCROLL_BAR_WIDTH (f) * CANON_X_UNIT (f) 6537 x0 = - (FRAME_LEFT_SCROLL_BAR_WIDTH (f) * CANON_X_UNIT (f)
6538 + FRAME_X_LEFT_FLAGS_AREA_WIDTH (f)); 6538 + FRAME_X_LEFT_FLAGS_AREA_WIDTH (f));
6539
6539 while (glyph < end 6540 while (glyph < end
6540 && x >= x0 + glyph->pixel_width) 6541 && x >= x0 + glyph->pixel_width)
6541 { 6542 {
6542 x0 += glyph->pixel_width; 6543 x0 += glyph->pixel_width;
6543 ++glyph; 6544 ++glyph;
6646 { 6647 {
6647 /* Mouse is on the mode or top line. */ 6648 /* Mouse is on the mode or top line. */
6648 note_mode_line_highlight (w, x, portion == 1); 6649 note_mode_line_highlight (w, x, portion == 1);
6649 return; 6650 return;
6650 } 6651 }
6652 else if (portion == 2)
6653 XDefineCursor (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f),
6654 f->output_data.x->horizontal_drag_cursor);
6651 else 6655 else
6652 XDefineCursor (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), 6656 XDefineCursor (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f),
6653 f->output_data.x->text_cursor); 6657 f->output_data.x->text_cursor);
6654 6658
6655 /* Are we in a window whose display is up to date? 6659 /* Are we in a window whose display is up to date?