From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: list items not treated as such. Date: Sun, 6 Oct 2013 21:47:18 +0200 Message-ID: <50CD1355-9F0B-4973-AB18-4BC2C70B97CC@gmail.com> References: <87txh3v5d6.fsf@rudin.co.uk> <524877EE.3030002@toel.it> <87pprrv47y.fsf@rudin.co.uk> <5249A133.1070703@toel.it> <874n92xo43.fsf@rudin.co.uk> <877gdx4hy8.fsf@rudin.co.uk> <87fvsh5nqd.fsf@rudin.co.uk> <87li298013.fsf@gmail.com> <874n8w50w8.fsf@rudin.co.uk> Mime-Version: 1.0 (Mac OS X Mail 6.6 \(1510\)) Content-Type: multipart/signed; boundary="Apple-Mail=_21198D02-3C5A-428E-A2A9-4E4A881B6CEC"; protocol="application/pgp-signature"; micalg=pgp-sha1 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37371) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VSuIb-0003zp-HG for emacs-orgmode@gnu.org; Sun, 06 Oct 2013 15:47:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VSuIU-0008NY-Nj for emacs-orgmode@gnu.org; Sun, 06 Oct 2013 15:47:29 -0400 Received: from mail-ea0-x231.google.com ([2a00:1450:4013:c01::231]:46912) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VSuIU-0008NR-GB for emacs-orgmode@gnu.org; Sun, 06 Oct 2013 15:47:22 -0400 Received: by mail-ea0-f177.google.com with SMTP id f15so2776646eak.22 for ; Sun, 06 Oct 2013 12:47:20 -0700 (PDT) In-Reply-To: <874n8w50w8.fsf@rudin.co.uk> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Paul Rudin Cc: emacs-orgmode@gnu.org --Apple-Mail=_21198D02-3C5A-428E-A2A9-4E4A881B6CEC Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii On 4.10.2013, at 20:47, Paul Rudin wrote: > Nicolas Goaziou writes: >=20 >> Hello, >>=20 >> Paul Rudin writes: >>=20 >>> Paul Rudin writes: >>>=20 >>> (about lists) >>>=20 >>> Here is a test for this problem. Notice that if you change the "a)" = to "1." >>> - for example - the test passes. So this is something specific to >>> alphabetically labelled list items. >>>=20 >>>=20 >>> (ert-deftest org-list-item-test () >>> (with-temp-buffer >>> (org-mode) >>> (let ((org-allow-alphabetical t) >>> (fill-column 70)) >>> (insert "1. some stuff\n" >>> " a) an alphabetic list item with text longer that the = current fill column so that it gets wrapped by fill-paragraph") >>> (fill-paragraph)t >>> (should (not (equal (org-in-item-p) 1)))))) >>=20 >> Quoting `org-list-allow-alphabetical' docstring: >>=20 >> This variable needs to be set before org.el is loaded. If you >> need to make a change while Emacs is running, use the customize >> interface or run the following code, where VALUE stands for the >> new value of the variable, after updating it: >>=20 >> (when (featurep 'org-element) (load "org-element" t t)) >>=20 >> So let-binding it cannot work. >=20 >=20 > Aha. So how do you test things like that? This seems to be OK. Is it? >=20 > (ert-deftest org-list-item-test () > (with-temp-buffer > (org-mode) > (let ((fill-column 70)) > (custom-set-variables '(org-list-allow-alphabetical t)) > (insert "1. some stuff\n" > " a) an alphabetic list item with text longer that the = current fill column so that it gets wrapped by fill-paragraph") > (fill-paragraph) > (should (not (equal (org-in-item-p) 1)))))) >=20 >=20 > This also explains what I was seeing, as I was setting it in my init > file after org was loaded. I was lulled into a false sense of security > because some aspects of alphabetical list label work in this > circumstance. >=20 > All I need now is roman numeral list labels too :) No chance! :) - Carsten --Apple-Mail=_21198D02-3C5A-428E-A2A9-4E4A881B6CEC Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- iQEcBAEBAgAGBQJSUb5OAAoJEO+gg/nAZuwMpm8IALxtZK38yMRbwTF87xHASSfL 8d8Fx6S1uvAKykBIHtPUYBbBHwVjpuGJQDO/jAoYn4F2gUDb+suM5BoScCGksGeY xRtQgLtgdsfS1dl6utMROWG0pJ8KduCLbGJOKPdjxDKCHxioC70x9kwI7h6HNutF J8yA9NdMFOHC9zIi/yhgi/cM493RBNICbxXu0XIEy2bIlwO6elElOpdkcTsdrodS sH//PByIaAq+NwPXiz29ApYVzBFB+csjykzeVvqbrAishLUGnskppTS0JVnu/p0m SEI8bqOrr7chZdEc/0tt8Tf8CL7UkfQEPfuFcnBOK167XWLyEkitdvcv74rgjeo= =SabP -----END PGP SIGNATURE----- --Apple-Mail=_21198D02-3C5A-428E-A2A9-4E4A881B6CEC--