From: Ihor Radchenko <yantar92@gmail.com>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: emacs-orgmode@gnu.org, Robert Klein <roklein@roklein.de>
Subject: Re: BUG: org-table: table option “:missing” not working (in ob-gnuplot.el)
Date: Fri, 01 Oct 2021 11:56:49 +0800 [thread overview]
Message-ID: <877dexe6ta.fsf@localhost> (raw)
In-Reply-To: <87a6jteiao.fsf@nicolasgoaziou.fr>
[-- Attachment #1: Type: text/plain, Size: 589 bytes --]
Nicolas Goaziou <mail@nicolasgoaziou.fr> writes:
> I'm not sure. I wrote this some years ago. I guess the rationale at that
> time was that it didn't feel useful to apply a format to an empty cell.
> For example, if you use `:fmt "$%s$"', I assume you wouldn't want to get
> "$$" in otherwise empty cells.
Also makes sense.
At this point, third-party code is likely to rely on the existing logic,
so I do not see any reason to insist on changing org-table.
To avoid confusion, can we change the docstring explicitly saying that
empty cells are ignored? (see the attached)
Best,
Ihor
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-orgtbl-to-generic-Mention-that-fmt-is-ignored-for-em.patch --]
[-- Type: text/x-diff, Size: 1018 bytes --]
From 60365a164147dfc71f0047661c143b54064a459b Mon Sep 17 00:00:00 2001
Message-Id: <60365a164147dfc71f0047661c143b54064a459b.1633060596.git.yantar92@gmail.com>
From: Ihor Radchenko <yantar92@gmail.com>
Date: Fri, 1 Oct 2021 11:40:54 +0800
Subject: [PATCH] orgtbl-to-generic: Mention that :fmt is ignored for empty
cells
* lisp/org-table.el (orgtbl-to-generic): Amend docstring mentioning
that :fmt is ignored for empty table cells.
---
lisp/org-table.el | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lisp/org-table.el b/lisp/org-table.el
index 89c57fb06..3fed15054 100644
--- a/lisp/org-table.el
+++ b/lisp/org-table.el
@@ -5649,6 +5649,9 @@ (defun orgtbl-to-generic (table params)
(:fmt (2 \"$%s$\" 4 (lambda (c) (format \"$%s$\" c))))
+ The format is ignored for empty fields. Use :raw t with non-nil
+ :backend option to force formatting empty fields.
+
:hlstart :hllstart :hlend :hllend :hsep :hlfmt :hllfmt :hfmt
Same as above, specific for the header lines in the table.
--
2.32.0
next prev parent reply other threads:[~2021-10-01 3:56 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-17 19:13 BUG: org-table: table option “:missing” not working (in ob-gnuplot.el) Robert Klein
2021-09-30 13:03 ` Ihor Radchenko
2021-09-30 23:48 ` Nicolas Goaziou
2021-10-01 3:56 ` Ihor Radchenko [this message]
2021-10-01 7:47 ` Nicolas Goaziou
2021-10-01 9:15 ` Ihor Radchenko
2021-10-01 3:50 ` 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=877dexe6ta.fsf@localhost \
--to=yantar92@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=mail@nicolasgoaziou.fr \
--cc=roklein@roklein.de \
/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).