Перечисление PageOrientation
Перечисление PageOrientation содержит варианты ориентации страницы документа. Может быть использована для получения / установки ориентации страниц для секции или документа в методах Section.setPageOrientation(), Section.getPageOrientation().
| Значение | Описание |
|---|---|
PageOrientation.Landscape | Альбомная ориентация |
PageOrientation.Portrait | Книжная ориентация |
Примеры
Block block = document.getBlocks().getBlock(0);
if (block != null)
{
Section section = block.getSection();
section.setPageOrientation(PageOrientation.Portrait);
Console.WriteLine(section.getPageOrientation());
}
Sections sections = document.getSections();
SectionsEnumerator sectionsEnumerator = sections.GetEnumerator();
foreach (var section in sectionsEnumerator)
{
section.setPageOrientation(PageOrientation.Portrait);
Console.WriteLine(section.getPageOrientation());
}