Nicolas Goaziou wrote: > Hello, >> This is defeated by the indentation code, which does not recognise >> sublists correctly and gets the indentation wrong.
> Would you mind elaborating? I fail to see where the indentation code > has some problem recognizing lists. Hopefully the example below clears things up a bit. >> By setting `fill-indent-according-to-mode' to nil, we tell Emacs' >> filling code to pay attention to `adaptive-fill-prefix' rather than >> using `indent-line-function'. > Not using `org-indent-line-function' sounds like a very bad idea to > me. Before ignoring this function, perhaps we could try to see what is > wrong with it. >> This is not a perfect solution, since refilling a list entry still >> does not work correctly unless the entire item is on a single line. > Huh? Again, could you provide an example, please? emacs -Q C-x C-f $TMP/foo.org M-: (erase-buffer) RET M-x auto-fill-mode RET M-: (insert "* Header\n- List entry\n - Sublist entry") RET Now type some more text so that the sublist entry line goes past the fill column. Note where the line-wrapping puts the continuation of the sublist entry: 1 | * Header 2 | - List entry 3 | - Sublist entry here we have some more text to make the line very 4 | very long and trigger line-wrapping. So the text on line 4 is considered to be part of the sublist entry, while I would expect it to be so (it would have been if auto-fill-mode were off). If fill-indent-according-to-mode is set to nil then doing the same thing leads to: 1 | * Header 2 | - List entry 3 | - Sublist entry here we have some more text to make the line very 4 | very long and trigger line-wrapping. Notice how in this case the continuation of the sublist entry is correct. Furthermore, if you've formatted the document as in the second example by hand, but fill-indent-according-to-mode is t, and you hit M-q on the sublist entry, the indentation of line 4 is changed from 4 spaces to 2 spaces. This changes line 4 from being part of the sublist entry to being part of the list entry from line 2. Hope this clarifies things. Cheers, Lawrence -- Lawrence Mitchell <we...@gmx.li> _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode