Skip to main content

Таблица DocumentAPI.PageOrientation

Таблица PageOrientation содержит варианты ориентации страницы документа. Может быть использована для получения / установки ориентации страниц для секции или документа в методах Section:setPageOrientation(), Section:getPageOrientation().

ЗначениеОписание
DocumentAPI.PageOrientation_LandscapeАльбомная ориентация страницы
DocumentAPI.PageOrientation_PortraitКнижная ориентация страницы

Примеры​


local section = document:getBlocks():getBlock(0):getSection()
section:setPageOrientation(DocumentAPI.PageOrientation_Landscape)
print(section:getPageOrientation())
local section = document:setPageOrientation(DocumentAPI.PageOrientation_Portrait)
local section = document:getBlocks():getBlock(0):getSection()
print(section:getPageOrientation())