}
else
{
- int invis_p, newpos, next_stop, start_charpos;
+ int invis_p;
+ EMACS_INT newpos, next_stop, start_charpos;
Lisp_Object pos, prop, overlay;
/* First of all, is there invisible text at this position? */
it->position.bytepos = CHAR_TO_BYTE (it->position.charpos);
}
setup_for_ellipsis (it, 0);
+ /* Let the ellipsis display before
+ considering any properties of the following char.
+ Fixes jasonr@gnu.org 01 Oct 07 bug. */
+ handled = HANDLED_RETURN;
}
}
}
int count, count1;
struct frame *sf;
int polling_stopped_here = 0;
+ Lisp_Object old_frame = selected_frame;
/* Non-zero means redisplay has to consider all windows on all
frames. Zero means, only selected_window is considered. */
}
retry:
+ if (!EQ (old_frame, selected_frame)
+ && FRAME_LIVE_P (XFRAME (old_frame)))
+ /* When running redisplay, we play a bit fast-and-loose and allow e.g.
+ selected_frame and selected_window to be temporarily out-of-sync so
+ when we come back here via `goto retry', we need to resync because we
+ may need to run Elisp code (via prepare_menu_bars). */
+ select_frame_for_redisplay (old_frame);
+
pause = 0;
reconsider_clip_changes (w, current_buffer);
last_escape_glyph_frame = NULL;
minimum distance from the old window start. */
pos = it.current.pos;
min_distance = INFINITY;
- while ((distance = abs (CHARPOS (start_pos) - IT_CHARPOS (it))),
+ while ((distance = eabs (CHARPOS (start_pos) - IT_CHARPOS (it))),
distance < min_distance)
{
min_distance = distance;
}
if (it->start_of_box_run_p && slice.x == 0)
- it->pixel_width += abs (face->box_line_width);
+ it->pixel_width += eabs (face->box_line_width);
if (it->end_of_box_run_p && slice.x + slice.width == img->width)
- it->pixel_width += abs (face->box_line_width);
+ it->pixel_width += eabs (face->box_line_width);
}
take_vertical_position_into_account (it);
non_selected = 1;
}
- /* Nonselected window or nonselected frame. */
+ /* Detect a nonselected window or nonselected frame. */
else if (w != XWINDOW (f->selected_window)
#ifdef HAVE_WINDOW_SYSTEM
|| f != FRAME_X_DISPLAY_INFO (f)->x_highlight_frame
if (NILP (b->cursor_type))
return NO_CURSOR;
- /* Use cursor-in-non-selected-windows for non-selected window or frame. */
- if (non_selected)
- {
- alt_cursor = b->cursor_in_non_selected_windows;
- return get_specified_cursor_type (alt_cursor, width);
- }
-
/* Get the normal cursor type for this window. */
if (EQ (b->cursor_type, Qt))
{
else
cursor_type = get_specified_cursor_type (b->cursor_type, width);
+ /* Use cursor-in-non-selected-windows instead
+ for non-selected window or frame. */
+ if (non_selected)
+ {
+ alt_cursor = b->cursor_in_non_selected_windows;
+ if (!EQ (Qt, alt_cursor))
+ return get_specified_cursor_type (alt_cursor, width);
+ /* t means modify the normal cursor type. */
+ if (cursor_type == FILLED_BOX_CURSOR)
+ cursor_type = HOLLOW_BOX_CURSOR;
+ else if (cursor_type == BAR_CURSOR && *width > 1)
+ --*width;
+ return cursor_type;
+ }
+
/* Use normal cursor if not blinked off. */
if (!w->cursor_off_p)
{
goto found;
}
else if (best_glyph == NULL
- || ((abs (g->charpos - pos)
- < abs (best_glyph->charpos - pos))
+ || ((eabs (g->charpos - pos)
+ < eabs (best_glyph->charpos - pos))
&& (right_p
? g->charpos < pos
: g->charpos > pos)))
mouse pointer enters it.
Autoselection selects the minibuffer only if it is active, and never
-unselects the minibuffer if it is active. */);
+unselects the minibuffer if it is active.
+
+When customizing this variable make sure that the actual value of
+`focus-follows-mouse' matches the behavior of your window manager. */);
Vmouse_autoselect_window = Qnil;
DEFVAR_LISP ("auto-resize-tool-bars", &Vauto_resize_tool_bars,