Skip to content
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

docx table width #1907

Open
Liripo opened this issue Oct 15, 2024 · 0 comments
Open

docx table width #1907

Liripo opened this issue Oct 15, 2024 · 0 comments

Comments

@Liripo
Copy link

Liripo commented Oct 15, 2024

---
title: "docx_gt"
format: 
  docx:
    toc: true
    number-sections: true
    toc-title: 目录
    toc-depth: 3
editor: visual
---

## Quarto

```{r}
library(gt)
gt(head(mtcars)) |>
    tab_options(table.width = pct(100), column_labels.font.weight = "bold") |>
    cols_align(align = "left")


gt(head(mtcars)) |>
    tab_options(table.width = px(600), column_labels.font.weight = "bold") |>
    cols_align(align = "left")
```

The above code does not take effect on the table width. How to adjust the table width?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant