emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] adding more color to agenda events


From: Carsten Dominik
Subject: Re: [Orgmode] adding more color to agenda events
Date: Sat, 3 Mar 2007 16:33:09 +0100

Hi Scott,


On Mar 1, 2007, at 18:43, Scott Jaderholm wrote:
Thanks Carsten!

Do you know how to select the whole line instead of just the word?
Also, do you know where I can find more information about the syntax to use in setting colors in the '(face ) area?

Is there an easy way to not interfere with the other highlighting that's going to happen? I'd like to highlight stuff in work.org with a different color, say orange, but I think I'd like TODO to stay red and Scheduled to stay green but change rest of headline color and the work: column. If there's a way to do this easily I'd also like to use it when defining special highlights for tags.

Thanks again,
Scott

Well, first you need to lear about regular expressions.
For example to match a line containing the word birthday
you would do

    "^.*\\<birthday\\>.*

To change only part of a line, leave the rest, you can use
groups.  For example, to change everyting in a line except
the word TODO you would match it like

   "\\(^.*\\)\\<TODO\\>\\(.*\\)"

and then use `add-text-properties' twice, first to add the face
property from (match-beginning 1) to (match-end 1), and then
from (match-beginning 2) to (match-end 2).

If you want to change the faces used by Org-mode in normal .org
files, try

   M-x customize-group RET org-faces RET

there you can change all the standard faces used.

If you want to add new stuff to fontification in org-mode,
take a look at the function `font-lock-add-keywords'.

There are quite a few faces already defined in Emacs that you can
use, or you can define your own.

Well, you are entering the world of Emacs hacking here, and the only
way you will get further is by learning about text properties,
regular expressons etc in the Emacs manual and in the Emacs lisp manual.

- Carsten





reply via email to

[Prev in Thread] Current Thread [Next in Thread]