emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ulf Stegemann <ulf-news@zeitform.de>
To: emacs-orgmode@gnu.org
Subject: Re: [LaTeX-Export] Longtable and Caption
Date: Thu, 17 Dec 2009 08:59:29 +0100	[thread overview]
Message-ID: <zf.upnr5qujaji.fsf@zeitform.de> (raw)
In-Reply-To: 55EA6F63-99FE-47A2-A5DD-9A9ECDA15485@gmail.com

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

Hi Carsten,

Carsten Dominik <carsten.dominik@gmail.com> wrote:

> On Dec 3, 2009, at 4:22 PM, Ulf Stegemann wrote:
>
>> Carsten Dominik <carsten.dominik@gmail.com> wrote:
>>
>>> it was my understanding that the caption command in longtable is different
>>> from the caption command in normal tables, in that it is a  line that is
>>> printed over the table on each page - so I thought it  always needs to be
>>> there.  Is that not correct?
>>
>> yes, treatment is different but nevertheless the caption is not
>> mandatory for longtable. I never had any problems with longtable tables
>> without \caption{}.
>
> sorry for being so slow to process this request.
>
> I believe this works now as you requested, please verify.

thanks for having a look at it (no need to apologise for the delay, it's
certainly not an urgent matter).

Captions are now suppressed for longtables without caption definition.
However, I've noticed that the extra linebreak (\\) is still inserted in
longtable environments regardless of the presence of a caption. That
linebreak leads to undesired effects when using longtable without a
caption but with vertical lines.

This should fix it:


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: org-latex_table-export.diff --]
[-- Type: text/x-patch, Size: 643 bytes --]

--- org-latex.el.orig	2009-12-17 08:10:19.000000000 +0100
+++ org-latex.el	2009-12-17 08:49:02.000000000 +0100
@@ -1538,7 +1538,7 @@
                              "\\caption{%s%s}"
                              (if label (concat "\\\label{" label "}") "")
                              (or caption "")))
-                        (if longtblp "\\\\\n" "\n")
+                        (if (and longtblp caption) "\\\\\n" "\n")
                         (if (and org-export-latex-tables-centered (not longtblp))
                             "\\begin{center}\n")
                         (if (not longtblp) (concat "\\begin{tabular}{" align "}\n"))

[-- Attachment #3: Type: text/plain, Size: 5 bytes --]


Ulf

[-- Attachment #4: Type: text/plain, Size: 201 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

  reply	other threads:[~2009-12-17  8:00 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-02  7:51 [LaTeX-Export] Longtable and Caption Ulf Stegemann
2009-12-03 14:37 ` Carsten Dominik
2009-12-03 15:22   ` Ulf Stegemann
2009-12-16 23:17     ` Carsten Dominik
2009-12-17  7:59       ` Ulf Stegemann [this message]
2009-12-17  9:58         ` Carsten Dominik

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=zf.upnr5qujaji.fsf@zeitform.de \
    --to=ulf-news@zeitform.de \
    --cc=emacs-orgmode@gnu.org \
    /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).