From: Ihor Radchenko <yantar92@gmail.com> To: Pride Allman <allmanpride@gmail.com> Cc: emacs-orgmode@gnu.org Subject: Re: [PATCH] lisp/org-table.el: Use booktabs on org-table-export Date: Wed, 11 May 2022 20:19:44 +0800 [thread overview] Message-ID: <87a6bojm73.fsf@localhost> (raw) In-Reply-To: <CA+VaMHtG5xZiWChm1XEv2+WafQD0SJQXnsYsW71mxQogr_-Azg@mail.gmail.com> Pride Allman <allmanpride@gmail.com> writes: > This is my first patch so hopefully I followed the instructions correctly, Thanks for the patch! Patches are always welcome, though I do not fully agree with the approach you used in this particular one. > While using ~org-table-export~ on a table directly even with > ~org-latex-tables-booktabs~ set to ~t~, it exports a normal table instead > of booktabs table. But on the same situation, if you export the whole > buffer the table will be exported according to booktabs. I also find this discrepancy awkward. Normally, Org export options are chosen according to org-export-options-alist (see the docstring) and the equivalent variables in specific export backend (see org-export-define-backend 'latex in ox-latex.el). However, when you look into orgtbl-to-latex, orgtbl-to-html, orgtbl-to-texinfo, and orgtbl-to-unicode, they all overwrite certain export settings by force. Sometimes, even not leaving the user an option to choose. All those (list :option value ...) are force-overwriting the _global_ export defaults (see orgtbl-to-latex calling orgtbl-to-generic that calls org-export-get-environment with third argument) , including :latex-tables-booktabs. This is by design. While I do not like the current design, your patch will only create even more inconsistencies; The same problem will remain for other force-overwritten options. Best, Ihor
next prev parent reply other threads:[~2022-05-11 12:19 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-05-09 22:29 Pride Allman 2022-05-11 12:19 ` Ihor Radchenko [this message] 2022-05-11 17:01 ` Pride Allman 2022-05-12 9:29 ` Ihor Radchenko
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=87a6bojm73.fsf@localhost \ --to=yantar92@gmail.com \ --cc=allmanpride@gmail.com \ --cc=emacs-orgmode@gnu.org \ --subject='Re: [PATCH] lisp/org-table.el: Use booktabs on org-table-export' \ /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: link
Code repositories for project(s) associated with this 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).