1
votes

I am new to org-mode (using it under evil) and been using it as a very nice ASCII-based TODO with scheduled times and completion dates. I have a simple question - and in my case, I think an image is worth 1000 words...

Look at the image below, in the line that starts with "Merge button: ...." - i.e the one that I've split to two lines - with the continuation line starting with "click after..."

After hitting TAB to open the action tree node, the continuation line is colored in grey - as if it's not a part of the task in question:

Split lines

This is further verified if I mark the task as DONE (shift-rightCursor): The DONE marker is placed below my task line, not below my continuation line - as if the continuation line is on its own:

Wrong place to say DONE

I am probably missing something obvious - any help will be most appreciated.

2
The notes underneath a heading are just regular text without any special highlighting, and that is by design. If you place your cursor on the gray text and hit C-u C-x = does it show any special font at that location? If not, then the default is nothing. If it shows something, I'd be surprised -- so please let us know. If it's just the default font for regular text, then you'd need to change your default font for that particular major mode, which is a slightly different question than I think you're asking. - lawlist
The notes underneath a heading are very useful, and can be used also for a list / item format: orgmode.org/manual/Plain-lists.html I use the notes to synchronize my tasks with Toodledo and have access to my todo on all mobile and desktop devices. - lawlist
@lawlist: The C-u C-x warns me about a 'disabled upcase-region command' (maybe because I am using evil?). Anyway, from your other comment I take it that it's not possible to split a heading line as I did - because if you do, it's no longer part of the heading (hence the different color). Is it possible to have the TODO/DONE 'attributes' on multi-line sections? - ttsiodras
The easiest way I can think of to explain it is to show you. If you type from your org-mode buffer (like in your example): M-x describe-variable RET org-complex-heading-regexp RET you'll get a printout for the regexp used for headings based on the keywords you've defined for org-mode. org-mode uses that regexp for many functions, and that regexp essentially defines where a heading begins and where it ends. The only regexp I've ever seen for notes, is something that I wrote myself. Try M-x re-builder RET and paste the code of the complex variable to see it in action. - lawlist
The default setting for C-u C-x = is (what-cursor-position t). The same result can be achieved by typing M-x eval-expression RET (what-cursor-position t) RET - lawlist

2 Answers

1
votes

The text at issue in the question of the original poster is what I generally refer to as the notes section of a task. By design, org-mode does not assign a particular highlighting of the notes section -- i.e., the default font for text will be used.

However, all is not lost. It is possible to change the default font for a particular buffer using the face-remapping-alist and setting it as a local variable. The following example uses a cyan foreground color, but it can be just about anything: http://www.gnu.org/software/emacs/manual/html_node/elisp/Face-Attributes.html I'm not certain when setq-local was introduced, but it is available in a current version of Emacs Trunk and may be available in earlier versions of Emacs.


(defun my-org-notes-face-function ()
(interactive)
  (setq-local face-remapping-alist '(
    (default (:foreground "cyan")))))

(add-hook 'org-mode-hook 'my-org-notes-face-function)
2
votes

In a word, it's the Design.

You could think like this: The headline (first line) is the title of a task, the rest are contents/description or sub tasks.