emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Pride Allman <allmanpride@gmail.com>
To: Ihor Radchenko <yantar92@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 13:01:21 -0400	[thread overview]
Message-ID: <CA+VaMHubAUiqtZbnfGLb8MmBjQtefFe1ncCbbnsnFymnXB9KXA@mail.gmail.com> (raw)
In-Reply-To: <87a6bojm73.fsf@localhost>

[-- Attachment #1: Type: text/plain, Size: 2266 bytes --]

So basically, the export function is doing the overwrite for user options
but to reduce the number of inconsistency we can't use this patch for only
one such option.

Now you explained it I can't think of a way to solve it without rewriting
the whole thing. Or maybe I need to read the source code more deeply.

Would it be too much to hope for it to be integrated on the basis that
things like this can be added for other options in other export backend
too? Or somehow introduce the global settings there.

And considering the answer is no for the previous question; is there a
workaround for this? Something people use? Because having to manually edit
the table everytime I export is a bit too much for me.

Thank you.

On Wed, 11 May 2022, 08:19 Ihor Radchenko, <yantar92@gmail.com> wrote:

> 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
>

[-- Attachment #2: Type: text/html, Size: 2969 bytes --]

  reply	other threads:[~2022-05-11 17:02 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-09 22:29 [PATCH] lisp/org-table.el: Use booktabs on org-table-export Pride Allman
2022-05-11 12:19 ` Ihor Radchenko
2022-05-11 17:01   ` Pride Allman [this message]
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=CA+VaMHubAUiqtZbnfGLb8MmBjQtefFe1ncCbbnsnFymnXB9KXA@mail.gmail.com \
    --to=allmanpride@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=yantar92@gmail.com \
    /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
Be 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).