From: Tobias Zawada <i@tn-home.de>
To: emacs-orgmode@gnu.org
Subject: Enhancement: Changing default setting of source block header line switches [9.0.5 (9.0.5-elpa @ /home/naehring/.emacs.d/elpa/org-20170210/)]
Date: Thu, 06 Jul 2017 08:12:52 +0200 [thread overview]
Message-ID: <87mv8idrff.fsf@smtp.1und1.de> (raw)
At first I would like to ask whether it is already possible to change
the default settings of the source block header line switches.
The question
> Is it possible to define source block switches globally in org mode?
at https://emacs.stackexchange.com/questions/33971/is-it-possible-to-define-source-block-switches-globally-in-org-mode
demonstrates the usefulness of this feature.
Reading part of the orgmode-manual (http://orgmode.org/manual/Literal-examples.html#Literal-examples), scanning the customization options,
and inspecting the source code gave me the impression that this is not
implemented yet. So, I am filing that as an enhancement request.
1. It should be possible to customize the default settings of the
switches
2. It should be possible to change the default settings of the switches
tree-locally through setting a property. That includes file-local
settings if one sets the property before the first headline.
3. Explicit inner settings should override outer settings, e.g.,
tree-local settings override the customization options and explicit headline
switches override the tree-local settings.
4. For each switch there should also be a negative switch. E.g., if line
numbering is enabled through the customization option it should be
possible to disable it with a tree-local setting or with the source
block headline switches.
Thanks for considering this feature request.
With best regards,
Tobias
======================================================================
Emacs : GNU Emacs 25.1.50.2 (i686-pc-linux-gnu, GTK+ Version 3.10.8)
of 2016-04-25
Package: Org mode version 9.0.5 (9.0.5-elpa @ /home/username/.emacs.d/elpa/org-20170210/)
current state:
==============
(setq
org-entities-user '(("frowney" "\\frowney" nil "੏" ":-(" ":-(" "☹")
("smiley" "\\smiley" nil "ća;" ":-)" ":-)" "☺")
("blacksquare" "\\blacksquare" nil "A0;" "#" "#" "■")
("square" "\\square" nil "□" "| |" "| |" "□")
("ldots" "\\ldots" nil "…" "..." "..." "…")
("times" "\\times" t "×" "x" "x" "×")
("mapsto" "\\mapsto" t "↦" "|->" "|->" "↦")
("neg" "\\neg" t "&neg;" "/" "/" "¬")
("greatergreater" "\\gg" t "⪢" ">>" ">>"
"⪢")
("nbsp" "\\medspace" t " " " " " " " ")
("greatereq" "\\geq" t "&greatereq;" ">=" ">=" "≥")
("lesseq" "\\leq" t "&lesseq;" "<=" "<=" "≤")
("lessless" "\\ll" t "⪡" "<<" "<<" "⪡")
("sqrt" "\\sqrt" t "√" "sqrt" "sqrt" "√")
("plusminus" "\\pm" t "±" "+-" "+-" "±")
("bull" "\\bullet" nil "•" "*" "*" "•"))
org-ctrl-c-ctrl-c-hook '(org-update-formula calc-inline-maybe)
org-latex-format-headline-function 'org-latex-format-headline-default-function
org-html-format-inlinetask-function 'org-html-format-inlinetask-default-function
org-cycle-level-after-item/entry-creation nil
org-tab-first-hook '(org-cycle-item-indentation
org-babel-hide-result-toggle-maybe
org-babel-header-arg-expand)
org-link-parameters '(("rmail" :follow org-rmail-open :store
org-rmail-store-link)
("mhe" :follow org-mhe-open :store org-mhe-store-link)
("irc" :follow org-irc-visit :store org-irc-store-link)
("info" :follow org-info-open :export org-info-export
:store org-info-store-link)
("gnus" :follow org-gnus-open :store
org-gnus-store-link)
("docview" :follow org-docview-open :export
org-docview-export :store org-docview-store-link)
("bibtex" :follow org-bibtex-open :store
org-bibtex-store-link)
("bbdb" :follow org-bbdb-open :export org-bbdb-export
:complete org-bbdb-complete-link :store
org-bbdb-store-link)
("w3m" :store org-w3m-store-link)
("id" :follow org-id-open)
("T" :follow org-trac-follow :export org-trac-export)
("H" :follow org-HD-follow :export org-HD-export)
("file+sys") ("file+emacs")
("doi" :follow org--open-doi-link)
("elisp" :follow org--open-elisp-link)
("file" :complete org-file-complete-link)
("ftp" :follow
(lambda (path) (browse-url (concat "ftp:" path))))
("help" :follow org--open-help-link)
("http" :follow
(lambda (path) (browse-url (concat "http:" path))))
("https" :follow
(lambda (path) (browse-url (concat "https:" path))))
("mailto" :follow
(lambda (path) (browse-url (concat "mailto:" path))))
("message" :follow
(lambda (path) (browse-url (concat "message:" path))))
("news" :follow
(lambda (path) (browse-url (concat "news:" path))))
("shell" :follow org--open-shell-link))
org-archive-hook '(org-attach-archive-delete-maybe)
org-preview-latex-process-alist '((dvips :programs ("latex" "dvips" "gs")
:description "latex → dvips → gs → png"
:message
"Required programs: latex dvips gs"
:image-input-type "dvi" :image-output-type
"png" :latex-compiler
("latex -interaction nonstopmode -output-directory %o %f")
:image-converter
("dvips -E %f -o %f.body.ps; echo -e \"%%!PS-Adobe-3.0 EPSF-3.0\\n%%%%Creator: dvips\\n%%%%Pages: 1\" > %f.bbi; gs -q -r%D -dSAFER -sDEVICE=bbox -dNOPAUSE -dBATCH %f.body.ps 2>> %f.bbi; echo -e \"\\n%%%%EndComments\\n%%%%BeginProlog\" >> %f.bbi; cat %f.bbi %f.body.ps > %f.ps; gs -sDEVICE=png16m -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -dAlignToPixels=0 -dDOINTERPOLATE -r%D -dNOPAUSE -dBATCH -sOutputFile=%O -dEPSCrop %f.ps")
)
(dvipng :programs ("latex" "dvipng")
:description "dvi > png" :message
"you need to install the programs: latex and dvipng."
:image-input-type "dvi" :image-output-type
"png" :image-size-adjust (1.0 . 1.0)
:latex-compiler
("latex -interaction nonstopmode -output-directory %o %f")
:image-converter
("dvipng -fg %F -bg %B -D %D -T tight -o %O %f")
)
(dvisvgm :programs ("latex" "dvisvgm")
:description "dvi > svg" :message
"you need to install the programs: latex and dvisvgm."
:use-xcolor t :image-input-type "dvi"
:image-output-type "svg"
:image-size-adjust (1.7 . 1.5)
:latex-compiler
("latex -interaction nonstopmode -output-directory %o %f")
:image-converter
("dvisvgm %f -n -b min -c %S -o %O"))
(imagemagick :programs ("latex" "convert")
:description "pdf > png" :message
"you need to install the programs: latex and imagemagick."
:use-xcolor t :image-input-type "pdf"
:image-output-type "png"
:image-size-adjust (1.0 . 1.0)
:latex-compiler
("pdflatex -interaction nonstopmode -output-directory %o %f")
:image-converter
("convert -density %D -trim -antialias %f -quality 100 %O")
)
)
org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
org-cycle-show-empty-lines
org-optimize-window-after-visibility-change)
org-agenda-before-write-hook '(org-agenda-add-entry-text)
org-confirm-babel-evaluate nil
org-speed-command-hook '(org-speed-command-default-hook
org-babel-speed-command-hook)
org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
org-babel-pre-tangle-hook '(save-buffer)
org-occur-hook '(org-first-headline-recenter)
org-html-format-headline-function 'org-html-format-headline-default-function
org-structure-template-alist '(("m" org-structure-template-latex
org-structure-template-latex)
("s" "#+BEGIN_SRC ?\n\n#+END_SRC")
("e" "#+BEGIN_EXAMPLE\n?\n#+END_EXAMPLE")
("q" "#+BEGIN_QUOTE\n?\n#+END_QUOTE")
("v" "#+BEGIN_VERSE\n?\n#+END_VERSE")
("V" "#+BEGIN_VERBATIM\n?\n#+END_VERBATIM")
("c" "#+BEGIN_CENTER\n?\n#+END_CENTER")
("l" "#+BEGIN_EXPORT latex\n?\n#+END_EXPORT")
("L" "#+LaTeX: ")
("h" "#+BEGIN_EXPORT html\n?\n#+END_EXPORT")
("H" "#+HTML: ")
("a" "#+BEGIN_EXPORT ascii\n?\n#+END_EXPORT")
("A" "#+ASCII: ") ("i" "#+INDEX: ?")
("I" "#+INCLUDE: %file ?"))
org-metaup-hook '(org-babel-load-in-session-maybe)
org-confirm-elisp-link-function 'y-or-n-p
org-descriptive-links nil
org-latex-format-drawer-function #[514 "\207" [] 3 "\n\n(fn _ CONTENTS)"]
org-src-tab-acts-natively t
org-export-backends '(ascii html icalendar latex odt tracTZA)
org-preview-latex-default-process 'dvips
org-highlight-latex-and-related '(latex)
org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
org-ascii-text-width 1000
org-image-actual-width '(400)
org-mode-hook '(#[0
"\305\306 >\203\0\307\n\310\311#\210\307\v\312\313#\210\307\v\314\315#\210\306 >\203,\307\n\316\317#\210\307\n\320\321#\210\322 >\203>\307\v\323\324#\210\307\v\325\324#\210\326 >\203P\307\n\327\317#\210\307\n\330\321#\210\331 >\203_\332\311\f\333BC\334#\210\335 >\203k\332\311\336\334#\210\337 >\203w\332\311\340\334#\210\341\342\343\344\311$\210\345\342\311\"\210\342\207"
[org-mouse-context-menu-function
org-mouse-features
org-mouse-map
org-mode-map
org-outline-regexp
org-mouse-context-menu
context-menu
org-defkey
[mouse-3]
nil
[mouse-3]
org-mouse-show-context-menu
[down-mouse-1]
org-mouse-down-mouse
[C-drag-mouse-1]
org-mouse-move-tree
[C-down-mouse-1]
org-mouse-move-tree-start
yank-link
[S-mouse-2]
org-mouse-yank-link
[drag-mouse-3]
move-tree
[drag-mouse-3]
[down-mouse-3]
activate-stars
font-lock-add-keywords
(0
(\`
(face
org-link
mouse-face
highlight
keymap
(\, org-mouse-map)
)
)
(quote prepend)
)
t
activate-bullets
(("^[ ]*\\([-+*]\\|[0-9]+[.)]\\) +"
(1
(\`
(face
org-link
keymap
(\, org-mouse-map)
mouse-face highlight)
)
(quote prepend)
)
)
)
activate-checkboxes
(("^[ ]*\\([-+*]\\|[0-9]+[.)]\\) +\\(\\[[ X]\\]\\)"
(2
(\`
(face
bold
keymap
(\, org-mouse-map)
mouse-face highlight)
)
t)
)
)
ad-add-advice
org-open-at-point
(org-mouse-open-at-point
nil
t
(advice
lambda
nil
(let
((context
(org-context)
)
)
(cond
((assq :headline-stars context)
(org-cycle)
)
((assq :checkbox context)
(org-toggle-checkbox)
)
((assq :item-bullet context)
(let
((org-cycle-include-plain-lists t)
)
(org-cycle)
)
)
((org-footnote-at-reference-p)
nil)
(t ad-do-it)
)
)
)
)
around ad-activate]
5]
org-hook-todo-regexp
(lambda nil
(local-set-key (kbd "C-c b") (quote org-insert-block)))
(lambda nil
(add-hook (quote text-scale-mode-hook)
(quote org-text-scale-eye))
)
org+-org-mode-hook-function
(lambda nil (local-set-key (kbd "C-c p") (quote org-patch)))
#[0 "\300\301\302\303\304$\207"
[add-hook change-major-mode-hook org-show-block-all append
local]
5]
#[0 "\300\301\302\303\304$\207"
[add-hook change-major-mode-hook org-babel-show-result-all
append local]
5]
org-babel-result-hide-spec org-babel-hide-all-hashes)
org-agenda-mode-hook '(#[0
"\302\303 \304\305#\210\303 \306\307#\210\303 \310\311#\210\303 \312\313#\210\303 \314\315#\207"
[org-mouse-context-menu-function
org-agenda-mode-map
org-mouse-agenda-context-menu
org-defkey
[mouse-3]
org-mouse-show-context-menu
[down-mouse-3]
org-mouse-move-tree-start
[C-mouse-4]
org-agenda-earlier
[C-mouse-5]
org-agenda-later
[drag-mouse-3]
#[257
"\300!\301\302\"\203\0\303\304!\202\0\301\305\"\205\0\306\304!\207"
[org-mouse-get-gesture eql :left org-agenda-earlier 1 :right org-agenda-later]
5 "\n\n(fn EVENT)" "e"]
]
4]
)
org-ascii-format-drawer-function #[771 "\207" [] 4 "\n\n(fn NAME CONTENTS WIDTH)"]
org-odt-format-drawer-function #[514 "\207" [] 3 "\n\n(fn NAME CONTENTS)"]
org-from-is-user-regexp "\\<Tobias Zawada\\>"
org-font-lock-set-keywords-hook '(org-hook-font-lock-todo
org-hidden-links-hook-function
(lambda nil
(let
((el
(assoc-string "{{{.+}}}"
org-font-lock-extra-keywords)
)
)
(when el (setcar el "{{{.+?}}}")))
(add-to-list
(quote org-font-lock-extra-keywords)
(quote
("^[[:blank:]]*\\([?!]\\):[^?!]*\\1$"
(0
(quote org-question-exclamation-face)
t)
)
)
)
(add-to-list
(quote org-font-lock-extra-keywords)
(quote
("^[[:blank:]]*[A-Z][A-Z]+:.*$"
(0
(quote org-user-defined-keywords-face)
t)
)
)
)
)
org-dont-underline-indents)
org-html-format-drawer-function #[514 "\207" [] 3 "\n\n(fn NAME CONTENTS)"]
org-src-preserve-indentation t
org-hide-emphasis-markers t
org-odt-format-headline-function 'org-odt-format-headline-default-function
org-metadown-hook '(org-babel-pop-to-session-maybe)
org-clock-display-default-range 'untilnow
org-src-mode-hook '(hack-local-variables org-src-babel-configure-edit-buffer
org-src-mode-configure-edit-buffer
org+-src-mode-configure-edit-file-buffer-name)
org-after-todo-state-change-hook '(org-clock-out-if-current)
org-odt-format-inlinetask-function 'org-odt-format-inlinetask-default-function
org-babel-tangle-lang-exts '(("ruby" . "rb") ("python" . "py")
("perl" . "pl") ("maxima" . "max") ("D" . "d")
("C++" . "cpp") ("emacs-lisp" . "el")
("elisp" . "el"))
org-babel-load-languages '((C . t) (ditaa . t) (dot . t) (emacs-lisp . t)
(gnuplot . t) (maxima . t) (octave . t) (perl . t)
(python . t) (R . t) (ruby . t) (shell . t)
(sqlite . t) (calc . t))
org-bbcode-after-export-hook '(org-bbcode-apply-delete-char)
org-metareturn-hook '(org-metareturn-insert-item)
org-latex-format-inlinetask-function 'org-latex-format-inlinetask-default-function
org-confirm-shell-link-function 'y-or-n-p
)
next reply other threads:[~2017-07-06 6:15 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2017-07-06 6:12 Tobias Zawada [this message] 2017-07-06 7:03 ` Enhancement: Changing default setting of source block header line switches [9.0.5 (9.0.5-elpa @ /home/naehring/.emacs.d/elpa/org-20170210/)] Rasmus 2017-07-06 7:33 ` Tobias Zawada 2017-08-28 8:12 ` Nicolas Goaziou
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style List information: https://www.orgmode.org/ * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=87mv8idrff.fsf@smtp.1und1.de \ --to=i@tn-home.de \ --cc=emacs-orgmode@gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).