bokuweb / docx-rs

:memo: A .docx file writer with Rust/WebAssembly.
https://bokuweb.github.io/docx-rs/
MIT License
341 stars 59 forks source link

page_orient() not working #603

Open toufik-belgacemi opened 1 year ago

toufik-belgacemi commented 1 year ago

Describe the bug

A clear and concise description of what the bug is.

Reproduced step

Steps to reproduce the behavior:

Impossible to change the orientation of a page to Landscape with the function page_orient(PageOrientationType::Landscape)

Expected behavior

Change the orientation of the page

Actual behavior

Nothing happen

Desktop (please complete the following information)

Jumes-1 commented 1 year ago

The function page_orient only changes the orient property, which is not good enough for the word processor, the size of the document has to be changed as well. Which is as simple as flipping the width with the height. I think that the function itself should do this

k-bx commented 1 year ago

At least documenting this would help a lot.