Ihor Radchenko writes: > Bastien writes: >> Could it slow down agenda generation for some configurations? > The total slowdown is ~30%, though the second part will only be slow > before the headings are fontified first time by > org-buffer-substring-fontified. Subsequent agenda rebuilds will be > faster. I have updated the code to avoid creating temporary org buffers. Now, I got 8% slowdown during first agenda run. The slowdown diminishes as the headlines contributing to agenda get fontified (i.e. for all next org-agenda-redo). > Please move the comments after the change log themselves. Done. > Here and for the rest of the patch: please try to keep lines below 80 > characters. I'm aware this is not always feasible, especially given > long functions with many nested s-exps, but let's try to come as close > as possible to 80. Done. William Xu writes: > The only issue I still see, is that when you org-agenda-redo-all, or > org-agenda-log-mode (which triggers org-agenda-redo-all), the > prettify gets lost again. Maybe org-buffer-substring-fontified call is > also required somewhere during org-agenda-redo-all? I managed to reproduce it. This time, I went through all the agenda.el and updated places where the strings are fetched from Org buffers into agenda. The updated patch is attached. Best, Ihor