-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
5p layout not correctly rendered when table is added #24
Comments
This format should be trying to do the right thing with long tables in 2-column layouts, but I've seen when that code isn't working properly (e.g. before I added it). I think a place to start is to add We're basically hoping that this: \usepackage{float}
\makeatletter
\let\oldlt\longtable
\let\endoldlt\endlongtable
\def\longtable{\@ifnextchar[\longtable@i \longtable@ii}
\def\longtable@i[#1]{\begin{figure}[H]
\onecolumn
\begin{minipage}{0.5\textwidth}
\oldlt[#1]
}
\def\longtable@ii{\begin{figure}[H]
\onecolumn
\begin{minipage}{0.5\textwidth}
\oldlt
}
\def\endlongtable{\endoldlt
\end{minipage}
\twocolumn
\end{figure}}
\makeatother makes it into the latex. One other thought- it's possible that since this is redefining |
Thanks for the suggestion! I will see if I see it in the latex file and report back |
Hi, I checked the latex file, and the code that you mentioned is present in the generated latex. The top part is still cut off though |
Can you share the latex (or see whether the table in the document is a ‘longtable’)? |
I am attaching the latex file. I think I saw "longtable" at the end, Thanks a lot for taking the time to help! |
Yeah it definitely seems like everything should be working, but it sure looks like the table is evading our special handling. I'll need to try to drill into the LaTeX more carefully to diagnose what is happening... |
Can you provide a |
I actually am using quarto from jupyterlab and rendering the .ipynb file. But I made a qmd file too just now. The problem persists. I am attaching the qmd code in txt file |
Hi, Any luck with the debugging process ? Also I wanted to ask an unrelated question. Is there any way to span a figure across the 2 columns in 5p or 3p ? |
Quarto provides the way to do this with figures with Some examples from a document I'm working on: {#fig-bespoke-spi width="100%" fig-env="figure*"} It's not documented, but I got it to work with embedded figures by wrapping it in the fenced div. ::: {#fig-targets fig-env="figure*"}
{{< embed notebooks/SingleIndex-Code.ipynb#fig-targets >}}
::: I haven't figured out how to get a table to span both columns though - that's what brought me to this issue! @dragonstyle is this possible with longtable? I believe it can be done be done with |
Hi, I am using the elsevier quarto extension for a paper I am writing. When I add a markdown table, the 5p format is not rendering correctly. It is fine without the table, but with the table, some of the text in the beginning is cut off.
This is the render from the template file :

Now when I just replace the content under the heading "Tables coming from R" with my own markdown table, I get this render:

Everything above "Using CSL" is cut off! Could you help see why this is happening?
The text was updated successfully, but these errors were encountered: