From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ivan Andrus Newsgroups: gmane.emacs.bugs Subject: bug#9324: 24.0.50; Movement past end of screen causes weird jump Date: Fri, 19 Aug 2011 20:38:09 +0200 Message-ID: <9ACB0EEF-FA00-4644-9D76-727BFDD9CECF@gmail.com> References: <00373C62-5B35-44BB-8770-CC91E8161366@gmail.com> <87bovm5ssx.fsf@gmail.com> <8362ltst7w.fsf@gnu.org> <04093F70-5A0B-4123-8C18-38FAAD2A6DEC@gmail.com> <831uwhsmx7.fsf@gnu.org> <0FDD993E-173A-482A-937B-8DE5E330D4F4@gmail.com> <83ty9dqq54.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: multipart/mixed; boundary=Apple-Mail-9-464440245 X-Trace: dough.gmane.org 1313779156 21845 80.91.229.12 (19 Aug 2011 18:39:16 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 19 Aug 2011 18:39:16 +0000 (UTC) Cc: 9324@debbugs.gnu.org, antoine.levitt@gmail.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Aug 19 20:39:06 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QuTyA-0008OR-3a for geb-bug-gnu-emacs@m.gmane.org; Fri, 19 Aug 2011 20:39:02 +0200 Original-Received: from localhost ([::1]:60882 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QuTy9-00040M-2B for geb-bug-gnu-emacs@m.gmane.org; Fri, 19 Aug 2011 14:39:01 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:36237) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QuTy6-000401-L8 for bug-gnu-emacs@gnu.org; Fri, 19 Aug 2011 14:38:59 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QuTy5-00021S-5X for bug-gnu-emacs@gnu.org; Fri, 19 Aug 2011 14:38:58 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:35209) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QuTy4-00021O-Tu for bug-gnu-emacs@gnu.org; Fri, 19 Aug 2011 14:38:56 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1QuU06-0001n1-Jr; Fri, 19 Aug 2011 14:41:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ivan Andrus Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 19 Aug 2011 18:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 9324 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 9324-submit@debbugs.gnu.org id=B9324.13137792396847 (code B ref 9324); Fri, 19 Aug 2011 18:41:02 +0000 Original-Received: (at 9324) by debbugs.gnu.org; 19 Aug 2011 18:40:39 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QuTzh-0001mL-In for submit@debbugs.gnu.org; Fri, 19 Aug 2011 14:40:38 -0400 Original-Received: from mail-fx0-f44.google.com ([209.85.161.44]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QuTzP-0001ln-TX for 9324@debbugs.gnu.org; Fri, 19 Aug 2011 14:40:29 -0400 Original-Received: by fxe6 with SMTP id 6so2148616fxe.3 for <9324@debbugs.gnu.org>; Fri, 19 Aug 2011 11:38:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :message-id:references:to:x-mailer; bh=evJVTo6/nyVuHrK9UiyHPXn5H9R52HUK0fR09s2Z3sM=; b=q2ofptlAcOMny7Eb1lPJrlIfaovtBD8v19J3yXbvbyvro9XpPDJgRTlkTsRViw1S1o 5tDTuBmpA5KUxZ7uUPjN0DV2le4lkh3N+9Ll9fTzBuo/1QIP77ZT85mCTrbeN2gLIrZq +jT2cjCWG00Nr+ECBdmkfaumxgQqbPy2luePo= Original-Received: by 10.223.14.146 with SMTP id g18mr122099faa.3.1313779093034; Fri, 19 Aug 2011 11:38:13 -0700 (PDT) Original-Received: from [10.0.2.16] (catv-80-99-177-48.catv.broadband.hu [80.99.177.48]) by mx.google.com with ESMTPS id i16sm2770184faa.45.2011.08.19.11.38.10 (version=SSLv3 cipher=OTHER); Fri, 19 Aug 2011 11:38:12 -0700 (PDT) In-Reply-To: <83ty9dqq54.fsf@gnu.org> X-Mailer: Apple Mail (2.1084) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Fri, 19 Aug 2011 14:41:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 1) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:50162 Archived-At: --Apple-Mail-9-464440245 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii On Aug 19, 2011, at 7:15 PM, Eli Zaretskii wrote: >> From: Ivan Andrus >> Date: Fri, 19 Aug 2011 18:19:47 +0200 >> Cc: antoine.levitt@gmail.com, >> 9324@debbugs.gnu.org >>=20 >> In case you are interested in what happens in my contaminated emacs, = if I run C-x =3D after (forward-sexp) then it says a left parenthesis, = but if I use `(progn (forward-sexp)(what-cursor-position))` then it says = the next character is C-j. Furthermore, changing it to (prog2 = (forward-sexp) (what-cursor-position) (redisplay)) causes it to work = properly (i.e. no bug). >=20 > If invoking `redisplay' fixes the problem, it means some display > optimization is misfiring. But there are quite a few of those > optimizations, so without a reproducible test case, it's really hard > to say where to look. >=20 >> I guess I'm probably on my own on this one, since even I can't = reproduce it reliably in emacs -Q, so what functions that I should start = debugging? >=20 > I agree with Antoine: if you can reliably reproduce this with your > ~/..emacs, bisect it to find the minimal customizations necessary to > reproduce the problem, then post that information here. Okay, I think I can reliably reproduce it now. Sorry it took so long to = get it right. Anyway it seems to require both = highlight-parentheses-mode and hl-sexp-mode as well as a custom = mode-line face. I invoke it with: emacs -Q -l = ~/.emacs.d/elpa/highlight-parentheses-1.0.1/highlight-parentheses.el -l = ~/.emacs.d/local/hl-sexp.el ~/vcs/emacs/bug-example-3.el Thanks for your patience and pointers, Ivan --Apple-Mail-9-464440245 Content-Disposition: attachment; filename=bug-example-3.el Content-Type: application/octet-stream; name="bug-example-3.el" Content-Transfer-Encoding: 7bit 208. look at docs for `mouse-autoselect-window' to see if there is a better value that I should be using 209. Look at occur (C-h f occur RET) to see how to make a nice menu buffer, thing-amagig 210. make isearch ignore diactritics by default (until one is used or something) 211. use `declare-function' to silence warnings in init.el 212. Change all key bindings to C-c C-f for compiling/linting/syntax checking, C-c C-d for debugging, and C-c C-v for viewing/running 213. Make `to-do' update an org file which contains all the todos 214. Make a `find-nearby' to find 2 things within several lines 215. Make `zap-up-to-char-but-not-including' a la `zap-to-char' (maybe on S-M-z ?) 216. Use `align-regexp' with args to create `align-words' and `align-strings' ------------------------------------------------------- (custom-set-faces '(mode-line ((t (:box (:line-width 1)))))) (progn (set-frame-parameter (selected-frame) 'height 47) (set-frame-parameter (selected-frame) 'width (/ 178 2)) ;; (delete-other-windows) ;; (split-window-side-by-side) (goto-line 22) (recenter -22) (move-end-of-line 1) (emacs-lisp-mode) (highlight-parentheses-mode 1) (hl-sexp-mode 1) ) (forward-sexp) (defadvice server-goto-line-column (after server-visit-region.tex (line-col) activate) "When visiting a file from an external source, make sure that we are not narrowed, since the external source almost certainly uses absolute file line numbers." (when (string-match "_region_.tex\\'" (buffer-file-name)) (save-excursion ;; in case we don't find the other file we at least want the right line... (if (re-search-backward "\message{ !name(\\([^)]+\\))\\(?: !offset(\\([-0-9]+\\))\\)?\\s *}" nil nil) (let ((file-name (match-string 1)) (offset (match-string 2)) (line (car (ad-get-arg 0))) (col (cdr (ad-get-arg 0)))) (if offset (setq line (+ line (string-to-number offset)))) (find-file file-name nil) ;; Ironic, but I think cleaner then reimplementing... (server-goto-line-column (cons line col)) (message "Moved from _region_.tex to line %s of %s." line file-name)) ;; else (message "This is _region_.tex, but I couldn't find the original file!"))))) --Apple-Mail-9-464440245--