Skip to content

section.orientation = WD_ORIENT.LANDSCAPE don't work #298

@waterdr0p

Description

@waterdr0p

https://python-docx.readthedocs.io/en/latest/user/sections.html
Describe: There is no change for my docx document by input following code. (No Error raised)
env: win10, office2016, python3.5.1

Page dimensions and orientation

section.orientation, section.page_width, section.page_height
(PORTRAIT (0), 7772400, 10058400) # (Inches(8.5), Inches(11))
new_width, new_height = section.page_height, section.page_width
section.orientation = WD_ORIENT.LANDSCAPE
section.page_width = new_width
section.page_height = new_height
section.orientation, section.page_width, section.page_height
(LANDSCAPE (1), 10058400, 7772400)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions