Re: [O] Bug: LaTeX export of table with caption broken
Eric S Fraga writes: > On Thursday, 24 Jan 2019 at 10:02, Nick Dokos wrote: >> is* one with a caption). I do wonder why Eric and I could see it and >> you could not, but some mysteries will remain despite one's best >> efforts :-) > > Out of curiosity, I wonder if it's related to the version of Emacs? I'm > using emacs-snapshot on Debian. Don't know: I use (haven't updated emacs for a while) GNU Emacs 27.0.50 (build 3, x86_64-pc-linux-gnu, GTK+ Version 3.22.26) of 2018-11-12 Org mode version 9.2 (release_9.2-209-gdeb5c4 @ /home/nick/elisp/org-mode/lisp/) on Fedora 27 (I know: no longer supported - need to move to Fedora 29 pronto!). -- Nick "There are only two hard problems in computer science: cache invalidation, naming things, and off-by-one errors." -Martin Fowler
Re: [O] Bug: LaTeX export of table with caption broken
On Thursday, 24 Jan 2019 at 10:02, Nick Dokos wrote: > is* one with a caption). I do wonder why Eric and I could see it and > you could not, but some mysteries will remain despite one's best > efforts :-) Out of curiosity, I wonder if it's related to the version of Emacs? I'm using emacs-snapshot on Debian. -- Eric S Fraga via Emacs 27.0.50, Org release_9.2-207-g102142
Re: [O] Bug: LaTeX export of table with caption broken
On Thursday, 24 Jan 2019 at 14:48, Nicolas Goaziou wrote: > OK. I fixed that, even though I cannot reproduce the issue. Thanks! Works fine now. Strange that you could not reproduce it. -- Eric S Fraga via Emacs 27.0.50, Org release_9.2-207-g102142
Re: [O] Bug: LaTeX export of table with caption broken
Nicolas Goaziou writes: > Hello, > > Nick Dokos writes: > >> Guessing the culprit is c28eb3c2cb904666594e40c1dcae4437d954bde4. >> It seems that the caption is an empty string but the code tests whether >> it's nil and since it isn't, it assumes there is a caption and makes it >> into a floating table. > > OK. I fixed that, even though I cannot reproduce the issue. > Thank you! Just updated and tested: there is no more floating table without a caption (and there *is* one with a caption). I do wonder why Eric and I could see it and you could not, but some mysteries will remain despite one's best efforts :-) BTW, I also tested the RET/ fix and Bernt's example (checkboxes in a list with M-S-RET - or is it M-S-?) works for me now. Thanks! (again) -- Nick "There are only two hard problems in computer science: cache invalidation, naming things, and off-by-one errors." -Martin Fowler
Re: [O] Bug: LaTeX export of table with caption broken
Hello, Nick Dokos writes: > Guessing the culprit is c28eb3c2cb904666594e40c1dcae4437d954bde4. > It seems that the caption is an empty string but the code tests whether > it's nil and since it isn't, it assumes there is a caption and makes it > into a floating table. OK. I fixed that, even though I cannot reproduce the issue. Thank you. Regards, -- Nicolas Goaziou
Re: [O] Bug: LaTeX export of table with caption broken
Eric S Fraga writes: > On Tuesday, 22 Jan 2019 at 23:52, Nicolas Goaziou wrote: >> I cannot reproduce it. E.g., >> Would you have an ECM? > > Strangely, with attached ECM and emacs -Q, I have this problem. See > attached resulting LaTeX. > > Thanks, Guessing the culprit is c28eb3c2cb904666594e40c1dcae4437d954bde4. It seems that the caption is an empty string but the code tests whether it's nil and since it isn't, it assumes there is a caption and makes it into a floating table. -- Nick "There are only two hard problems in computer science: cache invalidation, naming things, and off-by-one errors." -Martin Fowler
Re: [O] Bug: LaTeX export of table with caption broken
On Wednesday, 23 Jan 2019 at 15:21, Nicolas Goaziou wrote: > Odd. Even with a minimal init file (i.e, I only loading Org), I cannot > reproduce it. Thanks Nicolas. It is indeed strange. I will play some more when I get a chance (bogged down with work at the moment). As I have a way around the problem, there's no worry. I'll report back when I figure this out! -- Eric S Fraga via Emacs 27.0.50, Org release_9.2-204-g3fc7b0
Re: [O] Bug: LaTeX export of table with caption broken
Hello, Eric S Fraga writes: > On Tuesday, 22 Jan 2019 at 23:52, Nicolas Goaziou wrote: >> I cannot reproduce it. E.g., >> Would you have an ECM? > > Strangely, with attached ECM and emacs -Q, I have this problem. See > attached resulting LaTeX. Odd. Even with a minimal init file (i.e, I only loading Org), I cannot reproduce it. Regards, -- Nicolas Goaziou
Re: [O] Bug: LaTeX export of table with caption broken
On Tuesday, 22 Jan 2019 at 23:52, Nicolas Goaziou wrote: > I cannot reproduce it. E.g., > Would you have an ECM? Strangely, with attached ECM and emacs -Q, I have this problem. See attached resulting LaTeX. Thanks, -- Eric S Fraga via Emacs 27.0.50, Org release_9.2-204-g3fc7b0 % Created 2019-01-23 Wed 08:34 % Intended LaTeX compiler: pdflatex \documentclass[11pt]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{graphicx} \usepackage{grffile} \usepackage{longtable} \usepackage{wrapfig} \usepackage{rotating} \usepackage[normalem]{ulem} \usepackage{amsmath} \usepackage{textcomp} \usepackage{amssymb} \usepackage{capt-of} \usepackage{hyperref} \author{Eric S Fraga} \date{\today} \title{} \hypersetup{ pdfauthor={Eric S Fraga}, pdftitle={}, pdfkeywords={}, pdfsubject={}, pdfcreator={Emacs 27.0.50 (Org mode 9.2)}, pdflang={English}} \begin{document} \tableofcontents This is a table: \begin{table}[htbp] \centering \begin{tabular}{ll} item & description\\ \hline one & first\\ two & second\\ \hline \end{tabular} \end{table} \end{document} This is a table: | item | description | |--+-| | one | first | | two | second | |--+-|
Re: [O] Bug: LaTeX export of table with caption broken
On Tuesday, 22 Jan 2019 at 23:52, Nicolas Goaziou wrote: > I cannot reproduce it. E.g., > Would you have an ECM? I did try essentially the same minimal example as you and it did not work (i.e. table was wrapped in a table environment). I did not try with emacs -Q however. I will do so when back on the system that has latest org later today but, in the meantime, any idea what setting could affect this behaviour? thanks, -- Eric S Fraga via Emacs 27.0.50, Org release_9.2-193-ge7901c
Re: [O] Bug: LaTeX export of table with caption broken
Hello, Eric S Fraga writes: > tables without captions now seem to export to tabulars within table > environments, which they did not do before. I cannot reproduce it. E.g., | a | becomes \begin{center} \begin{tabular}{l} \toprule a\\ \bottomrule \end{tabular} \end{center} Would you have an ECM? Regards, -- Nicolas Goaziou
Re: [O] Bug: LaTeX export of table with caption broken
Nicolas, tables without captions now seem to export to tabulars within table environments, which they did not do before. That is, before, a simple table with no document exported to just a tabular environment. This change is breaking many of my documents. Did I miss something or is this unintended behaviour due to the recent changes to table handling? If I add :float nil attribute, everything is fine but it means updating many documents. (although tabular environment now centred but maybe it was before as well -- cannot be sure) Thanks, eric -- Eric S Fraga via Emacs 27.0.50, Org release_9.2-204-g3fc7b0
Re: [O] Bug: LaTeX export of table with caption broken
On 2019-01-19, at 16:06, Nicolas Goaziou wrote: > Jens Lechtenboerger writes: > >> when exporting a table with caption to LaTeX on the master branch, >> invalid code is generated. > > Fixed. Thank you. Wow, that was lightning fast. Many thanks! Jens
Re: [O] Bug: LaTeX export of table with caption broken
Hello, Jens Lechtenboerger writes: > when exporting a table with caption to LaTeX on the master branch, > invalid code is generated. > > Example Org file: > > #+CAPTION: Some text > | Col1 | Col2 | > > |--+--| > | foo | bar | > > The resulting tex file contains this, without table environment, > which is necessary for the use of captions: > > begin{center} > \caption{Some text} > \begin{tabular}{ll} > Col1 & Col2\\ > \hline > foo & bar\\ > \end{tabular} > \end{center} Fixed. Thank you. Regards, -- Nicolas Goaziou
[O] Bug: LaTeX export of table with caption broken
Hi there, when exporting a table with caption to LaTeX on the master branch, invalid code is generated. Example Org file: #+CAPTION: Some text | Col1 | Col2 | |--+--| | foo | bar | The resulting tex file contains this, without table environment, which is necessary for the use of captions: begin{center} \caption{Some text} \begin{tabular}{ll} Col1 & Col2\\ \hline foo & bar\\ \end{tabular} \end{center} The above happens on the current master branch, but did already happen last month on the next branch: Org mode version 9.2 (release_9.2-193-ge7901c @ /usr/share/emacs/24.5/site-lisp/org/) Org mode version 9.1.14 (release_9.1.14-1178-gdd26f0 @ /usr/share/emacs/24.5/site-lisp/org/) In contrast, Org mode version 9.1.9 (release_9.1.9-65-g5e4542) shipping with Emacs is fine, creating the following: \begin{table}[htbp] \caption{Some text} \centering \begin{tabular}{ll} Col1 & Col2\\ \hline foo & bar\\ \end{tabular} \end{table} Best wishes Jens