Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Nicolas Goaziou
Kaushal Modi writes: > On Sun, Feb 11, 2018 at 3:22 PM Nicolas Goaziou > wrote: > >> >> > :SOME_PROP:This is a very long property value that goes beyond the >>^^^ >> Wild guess: missing spaces? >> > > Yes, that was it. > > Committed in > https://code.orgmode.org/bzg/org-mode/commit/f

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Kaushal Modi
On Sun, Feb 11, 2018 at 3:22 PM Nicolas Goaziou wrote: > > > :SOME_PROP:This is a very long property value that goes beyond the >^^^ > Wild guess: missing spaces? > Yes, that was it. Committed in https://code.orgmode.org/bzg/org-mode/commit/fe7619cd184847227e9c1085b4f3c13a553f007b -

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Kaushal Modi
On Sun, Feb 11, 2018, 3:13 PM Kaushal Modi wrote: Sorry, ignore that, figured out the mistake in my test. > -- Kaushal Modi

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Nicolas Goaziou
Kaushal Modi writes: > I was actually adding a test for org-return as the commit doesn't modify > the org-auto-fill-function. OK. > Interactively, the org-return change works as expected, but the test fails > with this: > > Test test-org/return condition: > (ert-test-failed > ((should

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Kaushal Modi
On Sun, Feb 11, 2018 at 10:54 AM Nicolas Goaziou wrote: > > Would you mind adding a test to `test-org/auto-fill-function' for good > measure? I was actually adding a test for org-return as the commit doesn't modify the org-auto-fill-function. The test I added was this.. but doesn't work. Can y

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Nicolas Goaziou
Kaushal Modi writes: > I'll convert that to a proper commit with comments and commit message, and > commit. Great! > Btw this is safe enough to commit to maint? I think so. Would you mind adding a test to `test-org/auto-fill-function' for good measure? Thank you.

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Kaushal Modi
Hi Nicolas, On Sun, Feb 11, 2018, 8:12 AM Nicolas Goaziou wrote: > > (and (not (org-at-property-p)) > auto-fill-function) > Thanks for the feedback. What I emailed earlier was just a buffer diff. I'll convert that to a proper commit with comments and commit message, and commit.

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-11 Thread Nicolas Goaziou
Hello, Kaushal Modi writes: > + (t (let ((auto-fill-function (if (org-at-property-p) > + nil > +auto-fill-function))) (and (not (org-at-property-p)) auto-fill-function) Could you add a comment explaining

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-05 Thread Kaushal Modi
On Sun, Feb 4, 2018 at 5:16 PM Nicolas Goaziou wrote: > `org-return' doesn't call any auto fill function. > It sort of does, indirectly, via (newline). Please see the proposed patch at the end of this email. Yet, it doesn't break properties drawers. > I agree. Though this patch fixes what sho

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-04 Thread Nicolas Goaziou
Kaushal Modi writes: > Of course. But "the right thing" would be to prevent call to auto filling > within `org-return` (somehow? I haven't yet dug deeper into that) if point > is in a property drawer. `org-return' doesn't call any auto fill function. > If you want to add a new property, use C-c

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-04 Thread Kaushal Modi
On Sat, Feb 3, 2018 at 5:16 PM Nicolas Goaziou wrote: > > Wait... What? > Yes :) I had thought I couldn't get my point across correctly the first time. > Properties drawers do not contain blank lines. If you hit , this is > no longer a properties drawer, but a regular one, where auto-filling i

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Nicolas Goaziou
Kaushal Modi writes: > 1. Download the attached Org file (property-auto-fill.org). > 2. emacs -Q property-auto-fill.org > 3. Navigate to the Heading, hit TAB, then to the PROPERTY drawer, hit TAB. > 4. Go to the end of the DESCRIPTION property, hit RET. Wait... What? Properties drawers do not c

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Nick Dokos
Kaushal Modi writes: > On Sat, Feb 3, 2018 at 11:22 AM Nick Dokos wrote: > > FWIW, I tried it too both with emacs -Q and in my normal working emacs: I > cannot reproduce it. > > Hello Nick, Nicolas, > > Thank you for trying out the MWE. I don't know what we could be doing > differently. >

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Kaushal Modi
On Sat, Feb 3, 2018 at 11:22 AM Nick Dokos wrote: > > FWIW, I tried it too both with emacs -Q and in my normal working emacs: I > cannot reproduce it. > Hello Nick, Nicolas, Thank you for trying out the MWE. I don't know what we could be doing differently. So here's a recorded screencast ( htt

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Nick Dokos
Kaushal Modi writes: > On Sat, Feb 3, 2018, 9:40 AM Nicolas Goaziou wrote: > > Kaushal Modi writes: > > I think I spotted your mistake. Considering (a part of) your ECM: > >    * Heading > >    :PROPERTIES: >      > > There's a line between the heading an

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Nicolas Goaziou
Kaushal Modi writes: > On Sat, Feb 3, 2018, 9:40 AM Nicolas Goaziou wrote: > >> Kaushal Modi writes: >> >> I think I spotted your mistake. Considering (a part of) your ECM: >> >>* Heading >> >>:PROPERTIES: >> >> >> There's a line between the heading and the properties drawer, so it is >

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Kaushal Modi
On Sat, Feb 3, 2018, 9:40 AM Nicolas Goaziou wrote: > Kaushal Modi writes: > > I think I spotted your mistake. Considering (a part of) your ECM: > >* Heading > >:PROPERTIES: > > > There's a line between the heading and the properties drawer, so it is > a regular drawer, > I don't follow

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Nicolas Goaziou
Kaushal Modi writes: > Did you copy and paste the whole ECM including the Local Variables? .. > because I can reproduce that in emacs -Q (emacs-26 branch). > > It's something about auto-fill-mode being on, that's different from > M-q. I think I spotted your mistake. Considering (a part of) your

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Kaushal Modi
On Sat, Feb 3, 2018, 9:29 AM Nicolas Goaziou wrote: > It is already the case. See `org-adaptive-fill-function': it returns nil > when at a node property. > I thought so too, because the filling doesn't happen on M-q. So it took me a while to come with that complete ECM. I cannot reproduce your

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Nicolas Goaziou
Hello, Kaushal Modi writes: > Hello, > > I am bumping this thread, as it very likely could have been missed. > > If fixing that was already on the radar, sorry for the bump. > > On Tue, Jan 30, 2018, 11:50 AM Kaushal Modi wrote: > >> Hello, >> >> I have noticed that auto-filling working on long

Re: [O] Prevent auto-fill-mode from filling Property values in drawers

2018-02-03 Thread Kaushal Modi
Hello, I am bumping this thread, as it very likely could have been missed. If fixing that was already on the radar, sorry for the bump. On Tue, Jan 30, 2018, 11:50 AM Kaushal Modi wrote: > Hello, > > I have noticed that auto-filling working on long (going past fill-column) > values in property

[O] Prevent auto-fill-mode from filling Property values in drawers

2018-01-30 Thread Kaushal Modi
Hello, I have noticed that auto-filling working on long (going past fill-column) values in property drawers. Here's a MWE: = #+TITLE: Test case showing auto-filling happening in Property drawers too * Heading :PROPERTIES: :DESCRIPTION: This is a very long description that will auto fill at t