emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Kyle Meyer <kyle@kyleam.com>
To: Daniel Fleischer <danflscr@gmail.com>
Cc: Ihor Radchenko <yantar92@gmail.com>,
	emacs-orgmode@gnu.org, emacs@vergauwen.me
Subject: Re: [PATCH] Re: ox-latex table tabbing support.
Date: Sun, 26 Jun 2022 14:18:02 -0400	[thread overview]
Message-ID: <87fsjr1e79.fsf@kyleam.com> (raw)
In-Reply-To: <m2y1xjcwjs.fsf_-_@gmail.com>

Thanks for the follow-up patch.

Daniel Fleischer writes:

> Subject: [PATCH] lisp/ox-latex.el: tabbing code refactor
>
> * lisp/ox-latex.el: documentation, indentation, cleaning
> (org-latex-table)
> (org-latex--align-string-tabbing)
> (org-table--org-tabbing)

This format doesn't quite align to the conventions.  Here are two
examples:

,----[ https://orgmode.org/worg/org-contribute.html#commit-messages ]
|  * lisp/org-capture.el (org-capture-set-plist): Make sure txt is a
|  string before calling `string-match'.
|  (org-capture-templates): Fix customization type.
`----

,----[ https://www.gnu.org/prep/standards/html_node/Style-of-Change-Logs.html#Style-of-Change-Logs ]
| * lisp/term.el (term-emulate-terminal): Avoid errors if the whole
| decoded string is eight-bit characters.  Don't attempt to save the
| string for next iteration in that case.
| * test/lisp/term-tests.el (term-decode-partial)
| (term-undecodable-input): New tests.
`----

[...]
> +  (or (org-export-read-attribute :attr_latex table :align)
> +      (let* ((count
> +              ;; Count the number of cells in the first row.
> +              (length
> +               (org-element-map
> +                   (org-element-map table 'table-row
> +                     (lambda (row)
> +                       (and (eq (org-element-property :type row)
> +                                'standard)
> +                            row))
> +                     info 'first-match)
> +                   'table-cell
> +                 (lambda (cell) cell))))

Fine as is, but (lambda (cell) cell) could be reduced to #'identity

> +             ;; Calculate the column width, using a proportion of
> +             ;;the documets textwidth.

nit: missing space before "the"

typo: documets -> document's

> +(defun org-table--org-tabbing (table contents info)
> +  "Return tabbing environment latex code for Org table.

Perhaps s/latex/LaTeX/ for consistency?

Otherwise, looks good to me.  Thanks again.


  reply	other threads:[~2022-06-26 18:31 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-28 14:38 ox-latex table tabbing support emacs--- via General discussions about Org-mode.
2022-04-04 10:33 ` Ihor Radchenko
     [not found] ` <87wng5nno3.fsf@localhost-Mzo7eKN----2>
2022-04-04 14:03   ` emacs--- via General discussions about Org-mode.
2022-06-21  4:43     ` Daniel Fleischer
2022-06-24 13:37       ` Robert Pluim
2022-06-24 14:20         ` Daniel Fleischer
2022-06-24 15:01           ` Robert Pluim
2022-06-24 15:50             ` Daniel Fleischer
2022-06-24 19:32             ` emacs--- via General discussions about Org-mode.
2022-06-25  3:32               ` Ihor Radchenko
2022-06-26 10:08                 ` Robert Pluim
2022-06-26 13:47                   ` [PATCH] describe how to override Author Robert Pluim
2022-06-26 14:04                     ` Daniel Fleischer
2022-06-27  9:53                     ` Ihor Radchenko
2022-06-28 12:07                       ` Robert Pluim
2022-06-29 10:10                         ` Ihor Radchenko
2022-06-30  8:18                           ` Robert Pluim
2022-06-30 13:19                             ` Ihor Radchenko
2022-06-30 15:17                               ` Robert Pluim
2022-07-02  4:21                                 ` Ihor Radchenko
2022-06-26  1:54       ` ox-latex table tabbing support Ihor Radchenko
2022-06-26  3:49         ` Kyle Meyer
2022-06-26 14:46           ` [PATCH] " Daniel Fleischer
2022-06-26 18:18             ` Kyle Meyer [this message]
2022-06-26 18:48               ` Daniel Fleischer

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=87fsjr1e79.fsf@kyleam.com \
    --to=kyle@kyleam.com \
    --cc=danflscr@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=emacs@vergauwen.me \
    --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).