+2014-06-06 Stefan Monnier <monnier@iro.umontreal.ca>
+
+ * mouse.el (mouse-posn-property): Ignore buffer position info when the
+ even happened elsewhere.
+
2014-06-06 Mario Lang <mlang@delysid.org>
* emacs-lisp/tabulated-list.el (tabulated-list-print): Only call
2014-06-05 Michal Nazarewicz <mina86@mina86.com>
- * textmodes/tildify.el (tildify-foreach-region-outside-env): New
- function which calls a callback on portions of the buffer that are
+ * textmodes/tildify.el (tildify-foreach-region-outside-env):
+ New function which calls a callback on portions of the buffer that are
outside of ignored environments.
(tildify-build-regexp): Remove function since it is now
incorporated in `tildify-foreach-region-outside-env' where it is
2014-05-30 Ken Olum <kdo@cosmos.phy.tufts.edu> (tiny change)
- * mail/rmail.el (rmail-delete-forward, rmail-delete-backward): The
- argument COUNT is now optional, to be more backward-compatible.
+ * mail/rmail.el (rmail-delete-forward, rmail-delete-backward):
+ The argument COUNT is now optional, to be more backward-compatible.
Doc fix. (Bug#17560)
2014-05-29 Reuben Thomas <rrt@sc3d.org>
- * whitespace.el (whitespace-report-region): Simplify
- documentation.
+ * whitespace.el (whitespace-report-region):
+ Simplify documentation.
(whitespace-report-region): Allow report-if-bogus to take the
value `never', for non-interactive use.
(whitespace-report): Refer to whitespace-report-region's
/* If PT is not visible in WINDOW, move back one half of
the screen. Allow PT to be partially visible, otherwise
something like (scroll-down 1) with PT in the line before
- the partially visible one would recenter. */
+ the partially visible one would recenter. */
if (!pos_visible_p (w, PT, &x, &y, &rtop, &rbot, &rowh, &vpos))
{
}
else if (auto_window_vscroll_p)
{
- if (rtop || rbot) /* partially visible */
+ if (rtop || rbot) /* Partially visible. */
{
int px;
int dy = frame_line_height;
{
struct window *w = XWINDOW (selected_window);
struct buffer *buf = XBUFFER (w->contents);
- struct buffer *obuf = current_buffer;
bool center_p = 0;
ptrdiff_t charpos, bytepos;
EMACS_INT iarg IF_LINT (= 0);
int this_scroll_margin;
+ if (buf != current_buffer)
+ error ("`recenter'ing a window that does not display current-buffer.");
+
/* If redisplay is suppressed due to an error, try again. */
- obuf->display_error_modiff = 0;
+ buf->display_error_modiff = 0;
if (NILP (arg))
{
center_p = 1;
}
- else if (CONSP (arg)) /* Just C-u. */
+ else if (CONSP (arg)) /* Just C-u. */
center_p = 1;
else
{
iarg = XINT (arg);
}
- set_buffer_internal (buf);
-
/* Do this after making BUF current
in case scroll_margin is buffer-local. */
- this_scroll_margin =
- max (0, min (scroll_margin, w->total_lines / 4));
+ this_scroll_margin
+ = max (0, min (scroll_margin, w->total_lines / 4));
/* Handle centering on a graphical frame specially. Such frames can
have variable-height lines and centering point on the basis of
h -= it.current_y;
else
{
- /* Last line has no newline */
+ /* Last line has no newline. */
h -= line_bottom_y (&it);
it.vpos++;
}
w->optional_new_start = 1;
- w->start_at_line_beg = (bytepos == BEGV_BYTE ||
- FETCH_BYTE (bytepos - 1) == '\n');
+ w->start_at_line_beg = (bytepos == BEGV_BYTE
+ || FETCH_BYTE (bytepos - 1) == '\n');
- set_buffer_internal (obuf);
return Qnil;
}