org-present
org-present copied to clipboard
Support hiding complete source blocks
Hi,
I am currently using source blocks to generate plantuml diagrams. Ideally I do not want to see the source blocks in my presentation.
I'm thinking hiding all of them would not work that well since you may have a mix of different types of blocks, some of which you want to see the source.
Maybe we need some kind of marker to indicate which source blocks should be hidden?
I do not know much about the functions org provide or elisp for that matter, please correct me if there's another way of doing this.
Of course there is an easy workaround for my case which is to generate the images externally.
It may be worthy consider using a workaround, i.e. to collaspe all src blocks when org-present is enabled.
I've made this, which does not hide it, but just folds it.
(defun eyjhb/org-present-hide-plantuml ()
(interactive)
(beginning-of-buffer)
(while (re-search-forward "begin_src plantuml" nil t) (org-fold-hide-block-toggle t)))
Could be run as a hook or something. Still trying to figure out how I want everything to work, but thought this might be useful for someone else.
This is ran after the buffer is narrowed.