Re: bug in emacs-ui ?
authorSebastien Binet <seb.binet@gmail.com>
Tue, 21 Jun 2011 19:26:25 +0000 (21:26 +0200)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:38:39 +0000 (09:38 -0800)
08/65215220959491c9945fb72e3480fa05f6b1f7 [new file with mode: 0644]

diff --git a/08/65215220959491c9945fb72e3480fa05f6b1f7 b/08/65215220959491c9945fb72e3480fa05f6b1f7
new file mode 100644 (file)
index 0000000..8355a7d
--- /dev/null
@@ -0,0 +1,187 @@
+Return-Path: <seb.binet@gmail.com>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 3C311429E25\r
+       for <notmuch@notmuchmail.org>; Tue, 21 Jun 2011 12:28:09 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "Cc"\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.789\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.789 tagged_above=-999 required=5\r
+       tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+       FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, T_MIME_NO_TEXT=0.01]\r
+       autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id Bex19KD44ToR for <notmuch@notmuchmail.org>;\r
+       Tue, 21 Jun 2011 12:28:07 -0700 (PDT)\r
+Received: from mail-wy0-f181.google.com (mail-wy0-f181.google.com\r
+       [74.125.82.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id C0CA7431FB6\r
+       for <notmuch@notmuchmail.org>; Tue, 21 Jun 2011 12:28:06 -0700 (PDT)\r
+Received: by wyb28 with SMTP id 28so74518wyb.26\r
+       for <notmuch@notmuchmail.org>; Tue, 21 Jun 2011 12:28:05 -0700 (PDT)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma;\r
+       h=domainkey-signature:from:to:cc:cc:subject:in-reply-to:references\r
+       :user-agent:date:message-id:mime-version:content-type;\r
+       bh=Ih3TLD7xDNIts2ZcQzjuBaafgzmSBPvdiWMDnD7i3s0=;\r
+       b=unXZcuNJaYKd4uQN3N96DuZBdLJF78IAQICkBxUbKDNa7ya35jIIL9RhrqQ1c23fnr\r
+       03BARH9xSlKbkAg/b89g1wNVtHbW4NZh0MwDXuniPmSktwVYHE1ArhwTvV+wKHwHgXyJ\r
+       EFtNMWjnsV4WSdru57ABSpvREnPbEt8713Qdo=\r
+DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma;\r
+       h=from:to:cc:subject:in-reply-to:references:user-agent:date\r
+       :message-id:mime-version:content-type;\r
+       b=P4xTDCkbLyV2wK07PpxMS9W9XyLIkFBHyCOuTKqZOrpf79WoBHd2UlEd5NT+IiOnyV\r
+       CN/MRMM4wVdn0GgQGPPo8Qy+geD5aPQPbGhgd6n2ORkQ2RxVEqYE5QvwgCrg9mGxQ1T7\r
+       I/pBTmJd4+eWII53+sSfDHdgG1eiUEHA34DR4=\r
+Received: by 10.227.143.14 with SMTP id s14mr6199451wbu.11.1308684484965;\r
+       Tue, 21 Jun 2011 12:28:04 -0700 (PDT)\r
+Received: from localhost (pc-88068.lal.in2p3.fr [134.158.88.68])\r
+       by mx.google.com with ESMTPS id c17sm4244340wbh.63.2011.06.21.12.28.03\r
+       (version=TLSv1/SSLv3 cipher=OTHER);\r
+       Tue, 21 Jun 2011 12:28:03 -0700 (PDT)\r
+From: Sebastien Binet <seb.binet@gmail.com>\r
+To: Jameson Graef Rollins <jrollins@finestructure.net>\r
+Subject: Re: bug in emacs-ui ?\r
+In-Reply-To: <87hb7jg2rl.fsf@servo.factory.finestructure.net>\r
+References: <8739j5rn2d.fsf@cern.ch>\r
+       <87pqm8cz4f.fsf@servo.factory.finestructure.net>\r
+       <87oc1spkkc.fsf@cern.ch>\r
+       <87mxhccw9v.fsf@servo.factory.finestructure.net>\r
+       <87hb7kpi7e.fsf@cern.ch>\r
+       <87fwn4cm9q.fsf@servo.factory.finestructure.net>\r
+       <BANLkTin=viaP4US-=qj2x7BQOKhGaLeaHw@mail.gmail.com>\r
+       <87hb7jg2rl.fsf@servo.factory.finestructure.net>\r
+User-Agent: Notmuch/ (http://notmuchmail.org) Emacs/23.3.1\r
+       (x86_64-unknown-linux-gnu)\r
+Date: Tue, 21 Jun 2011 21:26:25 +0200\r
+Message-ID: <878vsv9eam.fsf@cern.ch>\r
+MIME-Version: 1.0\r
+Content-Type: multipart/signed; boundary="=-=-=";\r
+       micalg=pgp-sha1; protocol="application/pgp-signature"\r
+Cc: , notmuch@notmuchmail.org\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Tue, 21 Jun 2011 19:28:09 -0000\r
+\r
+--=-=-=\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+hi,\r
+\r
+On Mon, 20 Jun 2011 22:41:18 -0700, Jameson Graef Rollins <jrollins@finestr=\r
+ucture.net> wrote:\r
+Non-text part: multipart/signed\r
+> On Tue, 21 Jun 2011 02:01:17 +0200, Sebastien Binet <seb.binet@gmail.com>=\r
+ wrote:\r
+> > and I checked there were no lingering .el files...\r
+> >=20\r
+> > so...\r
+> >  any way to tell which notmuch-emacs-ui I am actually using ? (I am a n=\r
+ewbie\r
+> > when comes to hacking lisp)\r
+>=20\r
+> Hey, Sebastien.  You can determine the loaded version of a library from\r
+> within emacs with the follow command:\r
+>=20\r
+> M-x locate-library notmuch\r
+>=20\r
+> It's also good to know how many notmuch instances are installed on your\r
+> system.  For instance, I have a system-wide installation, a "personal"\r
+> installation, the build currently in the source tree, etc.  Depending on\r
+> the options I supply to emacs at startup, I could run a variety of\r
+> versions.\r
+\r
+so, it seems the problem comes from:\r
+\r
+(defun notmuch-show-advance-and-archive ()\r
+  "Advance through thread and archive."\r
+  (interactive)\r
+  (let ((end-of-this-message (notmuch-show-message-bottom)))\r
+    (cond\r
+     ;; Ideally we would test `end-of-this-message' against the result\r
+     ;; of `window-end', but that doesn't account for the fact that\r
+     ;; the end of the message might be hidden, so we have to actually\r
+     ;; go to the end, walk back over invisible text and then see if\r
+     ;; point is visible.\r
+     ((save-excursion\r
+        (message "pt00: %s" (point))\r
+        (goto-char (- end-of-this-message 1))\r
+        (message "pt01: %s" (point))\r
+        (notmuch-show-move-past-invisible-backward)\r
+        (message "msg-end: %s" end-of-this-message)\r
+        (message "pt11: %s" (point))\r
+        ;;(goto-char (- (point) 400))\r
+        (message "pt12: %s" (point))\r
+        (> (point) (window-end)))\r
+      (message "point: %s" (point))\r
+      (message "window-end: %s" (window-end))\r
+      ;; The bottom of this message is not visible - scroll.\r
+      (scroll-up nil))\r
+     ((not (=3D end-of-this-message (point-max)))\r
+      ;; This is not the last message - move to the next visible one.\r
+      (notmuch-show-next-open-message))\r
+\r
+where I've added some good ol' print "foo" debugging.\r
+\r
+using the message from the openmpi mailing list I sent earlier and\r
+pressing tab, I get in the *Messages* buffer:\r
+\r
+For information about GNU Emacs and the GNU system, type C-h C-a.\r
+pt00: 1\r
+pt01: 1392\r
+msg-end: #<marker at 1393 in *[Open MPI Announce] Open MPI...>\r
+pt11: 1392\r
+pt12: 1392\r
+point: 1\r
+window-end: 1113\r
+notmuch-show-advance-and-archive: End of buffer=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=\r
+=20=20=20=20\r
+ie: it would seem the notmuch-show-move-past-invisible-backward does\r
+*not* move the point up to just before the hidden signature (and does\r
+not move it at all.)\r
+\r
+if I uncomment the goto-char to -400 line, everything's fine. (400 is\r
+roughly the length of the hidden signature)\r
+\r
+well, this is just an educated guess from an emacs-lisp programmer\r
+complete newbie.\r
+\r
+fyi: I am using emacs-23.3\r
+no patch were applied on top of the vanilla sources:\r
+http://projects.archlinux.org/svntogit/packages.git/tree/emacs/repos/extra-=\r
+x86_64/PKGBUILD\r
+\r
+=2Ds\r
+\r
+--=-=-=\r
+Content-Type: application/pgp-signature\r
+\r
+-----BEGIN PGP SIGNATURE-----\r
+Version: GnuPG v1.4.11 (GNU/Linux)\r
+\r
+iEYEARECAAYFAk4A8GEACgkQPj4AVbsZCCZJCgCg2K3VMtSmtrHRpc3jrCmllbWX\r
+Sa0AoIepe6Ls+oOKYz7RZlPrfm6XYdxQ\r
+=mi22\r
+-----END PGP SIGNATURE-----\r
+--=-=-=--\r