-
Notifications
You must be signed in to change notification settings - Fork 210
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
cols_width()
not working when using cols_merge()
for PDF output
#1837
Comments
Just want to add that
So it seems that the label is misattributed in latex. Maybe this can help with debugging. I've had a related issue with latex when creating tables using gtsummary and converting to gt using |
Good catch. I looked a bit more into it, and from what I can see the issue is with the Indeed if we call the example table for
so it calculates the widths correctly for the correct columns, but this is translated into LaTeX code by
|
Did a bit more investigating and it's this part of the code that's not working properly (line 179-214):
because
EDIT: The above doesn't work with stubs/row_groups introduced with the
yields
|
Thanks both for your investigation! Basically, if you use We'd happily accept a PR for this with tests, clear explanations, before and after screenshots of the result |
@olivroy: I'm taking a look at this and currently trying to understand stub layouts. Could you give me an example where the result of |
|
Description
Widths set with
cols_width()
isn't respected when usingcols_merge()
and when the output is PDF.Reproducible example
Consider this Quarto document:
Expected result
The table created doesn't respect the widths set:
When output as html, everything looks fine:
Session info
The text was updated successfully, but these errors were encountered: