emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Orgtbl, Radiotables: ":booktabs t"
@ 2013-11-26 10:15 AW
  2013-12-01  9:54 ` AW
  0 siblings, 1 reply; 11+ messages in thread
From: AW @ 2013-11-26 10:15 UTC (permalink / raw)
  To: org mode mailing list


\documentclass[parskip=half]{scrartcl}
\usepackage{booktabs, verbatim}

\begin{document}

Hello!

Once in a while I need a radiotable inside my LaTeX file and I'm asking to 
implement a parameter for the use of booktabs.

This is an example I picked from the manual of orgmode and added
\verb|\toprule|, \verb|\bottomrule|, :booktabs t and some other details.

This is the tabular in \LaTeX:

     \begin{tabular}{lrrr}\toprule
     Month & \multicolumn{1}{c}{Days} & Nr.\ sold & per day\\\midrule
     % BEGIN RECEIVE ORGTBL salesfigures
Jan & 23 & 55 & 2.4 \\
Feb & 21 & 16 & 0.8 \\
March & 22 & 278 & 12.6 \\
\hline
S: & 66 &  &  \\
     % END RECEIVE ORGTBL salesfigures
	\bottomrule
     \end{tabular}

And here comes the source:
     
\begin{verbatim}
     #+ORGTBL: SEND salesfigures orgtbl-to-latex :splice t :skip 2 :booktabs t
     | Month | Days | Nr sold | per day |
     |-------+------+---------+---------|
     | Jan   |   23 |      55 |     2.4 |
     | Feb   |   21 |      16 |     0.8 |
     | March |   22 |     278 |    12.6 |
     |-------+------+---------+---------|
     | S:    |   66 |         |         |
     #+TBLFM: $4=$3/$2;%.1f::@5$2=vsum(@I..II)
     
\end{verbatim}

The parameter ":booktabs t" would be new. 

To what end? You see, my table uses the booktabs package and I can, as
displayed above, use \verb|\toprule| and \verb|\bottomrule| in the "spliced"
tabular. But inside the tabular, all horizontal lines become
"hline"(s), which is, well, not ugly, but disturbing. Instead of each
hline a midrule is needed.

You can take this email and compile it with pdflatex. You'll see, that
some space is missing between the ``S:'' and the hline.

So would it be possible to implement the parameter ":booktabs t"
without much trouble?

Kind regards,

Alexander

\end{document}

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Orgtbl, Radiotables: ":booktabs t"
  2013-11-26 10:15 Orgtbl, Radiotables: ":booktabs t" AW
@ 2013-12-01  9:54 ` AW
  2013-12-01 10:18   ` Nicolas Goaziou
  0 siblings, 1 reply; 11+ messages in thread
From: AW @ 2013-12-01  9:54 UTC (permalink / raw)
  To: emacs-orgmode

Push?! 

Am Dienstag, 26. November 2013, 11:15:21 schrieb AW:
> \documentclass[parskip=half]{scrartcl}
> \usepackage{booktabs, verbatim}
> 
> \begin{document}
> 
> Hello!
> 
> Once in a while I need a radiotable inside my LaTeX file and I'm asking to
> implement a parameter for the use of booktabs.
> 
> This is an example I picked from the manual of orgmode and added
> \verb|\toprule|, \verb|\bottomrule|, :booktabs t and some other details.
> 
> This is the tabular in \LaTeX:
> 
>      \begin{tabular}{lrrr}\toprule
>      Month & \multicolumn{1}{c}{Days} & Nr.\ sold & per day\\\midrule
>      % BEGIN RECEIVE ORGTBL salesfigures
> Jan & 23 & 55 & 2.4 \\
> Feb & 21 & 16 & 0.8 \\
> March & 22 & 278 & 12.6 \\
> \hline
> S: & 66 &  &  \\
>      % END RECEIVE ORGTBL salesfigures
> 	\bottomrule
>      \end{tabular}
> 
> And here comes the source:
> 
> \begin{verbatim}
>      #+ORGTBL: SEND salesfigures orgtbl-to-latex :splice t :skip 2 :booktabs
> t
>      | Month | Days | Nr sold | per day |
>      |
>      |-------+------+---------+---------|
>      |
>      | Jan   |   23 |      55 |     2.4 |
>      | Feb   |   21 |      16 |     0.8 |
>      | March |   22 |     278 |    12.6 |
>      |
>      |-------+------+---------+---------|
>      |
>      | S:    |   66 |         |         |
> 
>      #+TBLFM: $4=$3/$2;%.1f::@5$2=vsum(@I..II)
> 
> \end{verbatim}
> 
> The parameter ":booktabs t" would be new.
> 
> To what end? You see, my table uses the booktabs package and I can, as
> displayed above, use \verb|\toprule| and \verb|\bottomrule| in the "spliced"
> tabular. But inside the tabular, all horizontal lines become
> "hline"(s), which is, well, not ugly, but disturbing. Instead of each
> hline a midrule is needed.
> 
> You can take this email and compile it with pdflatex. You'll see, that
> some space is missing between the ``S:'' and the hline.
> 
> So would it be possible to implement the parameter ":booktabs t"
> without much trouble?
> 
> Kind regards,
> 
> Alexander
> 
> \end{document}

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Orgtbl, Radiotables: ":booktabs t"
  2013-12-01  9:54 ` AW
@ 2013-12-01 10:18   ` Nicolas Goaziou
  2013-12-01 10:30     ` Handshake: Org-mode + Emacs releases Jambunathan K
  2014-08-19 16:03     ` Orgtbl, Radiotables: ":booktabs t" Jorge A. Alfaro-Murillo
  0 siblings, 2 replies; 11+ messages in thread
From: Nicolas Goaziou @ 2013-12-01 10:18 UTC (permalink / raw)
  To: AW; +Cc: emacs-orgmode

Hello,

AW <alexander.willand@t-online.de> writes:

>>      #+ORGTBL: SEND salesfigures orgtbl-to-latex :splice t :skip 2 :booktabs t
>>      | Month | Days | Nr sold | per day |
>>      |
>>      |-------+------+---------+---------|
>>      |
>>      | Jan   |   23 |      55 |     2.4 |
>>      | Feb   |   21 |      16 |     0.8 |
>>      | March |   22 |     278 |    12.6 |
>>      |
>>      |-------+------+---------+---------|
>>      |
>>      | S:    |   66 |         |         |
>> 
>>      #+TBLFM: $4=$3/$2;%.1f::@5$2=vsum(@I..II)
>> 

>> The parameter ":booktabs t" would be new.

[...]

>> So would it be possible to implement the parameter ":booktabs t"
>> without much trouble?

I don't think :booktabs belong to #+ORGTBL keyword because it is not
specific to radio tables.

I have a half baked patch which allows to use export framework to handle
radio tables. I'll try to complete it by the end of the year and propose
it on the ML.

Since ox-latex supports booktabs extension, radio tables will logically
inherit that feature.


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Handshake: Org-mode + Emacs releases
  2013-12-01 10:18   ` Nicolas Goaziou
@ 2013-12-01 10:30     ` Jambunathan K
  2013-12-01 11:13       ` Nicolas Goaziou
  2014-08-19 16:03     ` Orgtbl, Radiotables: ":booktabs t" Jorge A. Alfaro-Murillo
  1 sibling, 1 reply; 11+ messages in thread
From: Jambunathan K @ 2013-12-01 10:30 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode, emacs-devel


Nicolas

Nicolas Goaziou <n.goaziou@gmail.com> writes:

> I have a half baked patch which allows to use export framework to handle
> radio tables. I'll try to complete it by the end of the year and propose
> it on the ML.

I see that you are adding features and doing a very quick iteration.
Nothing wrong with it and each sprint has been well-timed and planned.

I am a bit apprehensive that (what you think as) essentials MAY get
missed in Vanilla Emacs proper.  So it would be good if you could
communicate with Emacs developers the Org-mode features that you want
packed in the upcoming Emacs release.  (If this is already communicated,
well and good)

Stefan was indicating mid-December for the current release.  Needless to
say, having features bundled as part of pre-test builds would get more
beta-testing and coverage.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Handshake: Org-mode + Emacs releases
  2013-12-01 10:30     ` Handshake: Org-mode + Emacs releases Jambunathan K
@ 2013-12-01 11:13       ` Nicolas Goaziou
  2013-12-01 12:03         ` Jambunathan K
  2013-12-06 14:27         ` Bastien
  0 siblings, 2 replies; 11+ messages in thread
From: Nicolas Goaziou @ 2013-12-01 11:13 UTC (permalink / raw)
  To: Jambunathan K; +Cc: emacs-orgmode, emacs-devel

Hello,

Jambunathan K <kjambunathan@gmail.com> writes:

> I am a bit apprehensive that (what you think as) essentials MAY get
> missed in Vanilla Emacs proper.  So it would be good if you could
> communicate with Emacs developers the Org-mode features that you want
> packed in the upcoming Emacs release.  (If this is already communicated,
> well and good)

I am no maintainer so I cannot tell which Org revision should be merged
with Emacs.

FWIW, considering the 15 days time frame we have, I think 8.2.3 family
is stable enough (modulo some features that might be cherry picked from
master) and would be the obvious safe choice for a quiet end of year.

8.3 release (i.e. built from master) has some interesting features, but
may require more work from Org developers during pretest phase.

> Stefan was indicating mid-December for the current release.  Needless to
> say, having features bundled as part of pre-test builds would get more
> beta-testing and coverage.

That's true. Nevertheless, with the package system, I would say we
already have a good coverage at each release.

OTOH, I think that Org versions bundled with Emacs should focus on being
rock solid.


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Handshake: Org-mode + Emacs releases
  2013-12-01 11:13       ` Nicolas Goaziou
@ 2013-12-01 12:03         ` Jambunathan K
  2013-12-06 14:27         ` Bastien
  1 sibling, 0 replies; 11+ messages in thread
From: Jambunathan K @ 2013-12-01 12:03 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode, emacs-devel

Nicolas Goaziou <n.goaziou@gmail.com> writes:

> Hello,
>
> Jambunathan K <kjambunathan@gmail.com> writes:
>
>> I am a bit apprehensive that (what you think as) essentials MAY get
>> missed in Vanilla Emacs proper.  So it would be good if you could
>> communicate with Emacs developers the Org-mode features that you want
>> packed in the upcoming Emacs release.  (If this is already communicated,
>> well and good)
>
> I am no maintainer so I cannot tell which Org revision should be merged
> with Emacs.

Just to clarify, I was interested in your comments as a developer who is
in-charge of org-element and ox & Co.  Essentially, I was asking a
convoluted question about the roadmap for features that you have taken
responsibility for vis-a-vis current Emacs release.

> (modulo some features that might be cherry picked from master) and
> would be the obvious safe choice for a quiet end of year.

Ok.  I am sure you will work this out with whoever is merging...

> FWIW, considering the 15 days time frame we have, I think 8.2.3 family
> is stable enough

> 8.3 release (i.e. built from master) has some interesting features, but
> may require more work from Org developers during pretest phase.

I take your answer to mean that you don't foresee anything substantial
to be added to the current feature set.

It's possible for you to buy time if you would like to see more
feature-lets added or stabilized.  

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Handshake: Org-mode + Emacs releases
  2013-12-01 11:13       ` Nicolas Goaziou
  2013-12-01 12:03         ` Jambunathan K
@ 2013-12-06 14:27         ` Bastien
  1 sibling, 0 replies; 11+ messages in thread
From: Bastien @ 2013-12-06 14:27 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode, Jambunathan K, emacs-devel

Nicolas Goaziou <n.goaziou@gmail.com> writes:

> FWIW, considering the 15 days time frame we have, I think 8.2.3 family
> is stable enough (modulo some features that might be cherry picked from
> master) and would be the obvious safe choice for a quiet end of
> year.

I just released 8.2.4 and merged it with Emacs.

We may have time for another merge for 8.2.5.

> 8.3 release (i.e. built from master) has some interesting features, but
> may require more work from Org developers during pretest phase.

Indeed -- let's not rush and let's polish 8.3 outside Emacs for now.

-- 
 Bastien

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Orgtbl, Radiotables: ":booktabs t"
  2013-12-01 10:18   ` Nicolas Goaziou
  2013-12-01 10:30     ` Handshake: Org-mode + Emacs releases Jambunathan K
@ 2014-08-19 16:03     ` Jorge A. Alfaro-Murillo
  2014-08-19 16:28       ` Jorge A. Alfaro-Murillo
  2014-08-19 22:16       ` Nicolas Goaziou
  1 sibling, 2 replies; 11+ messages in thread
From: Jorge A. Alfaro-Murillo @ 2014-08-19 16:03 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode

Hi Nicolas, 

Are there any news on this? I was just trying to accomplish the 
same thing (get \midrule instead of \hline in a LaTeX orgtbl), but 
adding :booktabs t seems to not be enough.

Best,

Jorge.
 
On [2013-12-01 Sun 10:18], Nicolas Goaziou wrote:

> Hello,
>
> AW <alexander.willand@t-online.de> writes:
>
>>>      #+ORGTBL: SEND salesfigures orgtbl-to-latex :splice t :skip 2 :booktabs t
>>>      | Month | Days | Nr sold | per day |
>>>      |
>>>      |-------+------+---------+---------|
>>>      |
>>>      | Jan   |   23 |      55 |     2.4 |
>>>      | Feb   |   21 |      16 |     0.8 |
>>>      | March |   22 |     278 |    12.6 |
>>>      |
>>>      |-------+------+---------+---------|
>>>      |
>>>      | S:    |   66 |         |         |
>>> 
>>>      #+TBLFM: $4=$3/$2;%.1f::@5$2=vsum(@I..II)
>>> 
>
>>> The parameter ":booktabs t" would be new.
>
> [...]
>
>>> So would it be possible to implement the parameter ":booktabs t"
>>> without much trouble?
>
> I don't think :booktabs belong to #+ORGTBL keyword because it is not
> specific to radio tables.
>
> I have a half baked patch which allows to use export framework to handle
> radio tables. I'll try to complete it by the end of the year and propose
> it on the ML.
>
> Since ox-latex supports booktabs extension, radio tables will logically
> inherit that feature.
>
>
> Regards,

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Orgtbl, Radiotables: ":booktabs t"
  2014-08-19 16:03     ` Orgtbl, Radiotables: ":booktabs t" Jorge A. Alfaro-Murillo
@ 2014-08-19 16:28       ` Jorge A. Alfaro-Murillo
  2014-08-19 17:37         ` Jorge A. Alfaro-Murillo
  2014-08-19 22:16       ` Nicolas Goaziou
  1 sibling, 1 reply; 11+ messages in thread
From: Jorge A. Alfaro-Murillo @ 2014-08-19 16:28 UTC (permalink / raw)
  To: emacs-orgmode

Well for now and until :booktabs t is incorporated this is what I 
am using:

#+BEGIN_SRC emacs-lisp 
  (defun orgtbl-to-latex-booktabs (table params) 
    "Convert the Orgtbl mode TABLE to LaTeX using booktabs 
    package."  (let* ((alignment (mapconcat (lambda (x) (if x "r" 
    "l")) 
                                 org-table-last-alignment "")) 
           (params2 
            (list 
             :tstart (concat "\\begin{tabular}{" alignment 
             "}\n\\toprule") :tend "\\bottomrule\n\\end{tabular}" 
             :lstart "" :lend " \\\\" :sep " & " :efmt "%s\\,(%s)" 
             :hline "\\midline"))) 
      (orgtbl-to-generic table (org-combine-plists params2 
      params)))) 
 
  (setq orgtbl-radio-table-templates 
        (delete-if (lambda (x) (equal (car x) 'latex-mode))  
                   orgtbl-radio-table-templates)) 
 
  (add-to-list 'orgtbl-radio-table-templates 
               '(latex-mode "% BEGIN RECEIVE ORGTBL %n\n% END 
               RECEIVE ORGTBL %n\n\\begin{comment}\n#+ORGTBL: SEND 
               %n orgtbl-to-latex-booktabs :splice nil :skip 0\n| 
               | |\n\\end{comment}\n")) 
#+END_SRC

-- 
Jorge.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Orgtbl, Radiotables: ":booktabs t"
  2014-08-19 16:28       ` Jorge A. Alfaro-Murillo
@ 2014-08-19 17:37         ` Jorge A. Alfaro-Murillo
  0 siblings, 0 replies; 11+ messages in thread
From: Jorge A. Alfaro-Murillo @ 2014-08-19 17:37 UTC (permalink / raw)
  To: emacs-orgmode

Ups... it should be midrule not midline.
-- 
Jorge.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Orgtbl, Radiotables: ":booktabs t"
  2014-08-19 16:03     ` Orgtbl, Radiotables: ":booktabs t" Jorge A. Alfaro-Murillo
  2014-08-19 16:28       ` Jorge A. Alfaro-Murillo
@ 2014-08-19 22:16       ` Nicolas Goaziou
  1 sibling, 0 replies; 11+ messages in thread
From: Nicolas Goaziou @ 2014-08-19 22:16 UTC (permalink / raw)
  To: Jorge A. Alfaro-Murillo; +Cc: emacs-orgmode

Hello,

jorge.alfaro-murillo@yale.edu (Jorge A. Alfaro-Murillo) writes:

> Are there any news on this? I was just trying to accomplish the same
> thing (get \midrule instead of \hline in a LaTeX orgtbl), but
> adding :booktabs t seems to not be enough.

Unfortunately, progress is slow. This is still in my TODO list anyway.
I'll post a patch when it's ready.


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2014-08-19 22:16 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-11-26 10:15 Orgtbl, Radiotables: ":booktabs t" AW
2013-12-01  9:54 ` AW
2013-12-01 10:18   ` Nicolas Goaziou
2013-12-01 10:30     ` Handshake: Org-mode + Emacs releases Jambunathan K
2013-12-01 11:13       ` Nicolas Goaziou
2013-12-01 12:03         ` Jambunathan K
2013-12-06 14:27         ` Bastien
2014-08-19 16:03     ` Orgtbl, Radiotables: ":booktabs t" Jorge A. Alfaro-Murillo
2014-08-19 16:28       ` Jorge A. Alfaro-Murillo
2014-08-19 17:37         ` Jorge A. Alfaro-Murillo
2014-08-19 22:16       ` Nicolas Goaziou

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