Класс PageProperties
Класс PageProperties предоставляет такие свойства страницы как высота, ширина, размеры полей. Используется в Document.setPageProperties(), Section.getPageProperties(), Section.setPageProperties().
| Поле | Тип | Описание |
|---|---|---|
PageProperties.height | float | Высота страницы |
PageProperties.width | float | Ширина страницы |
PageProperties.margins | Insets | Поля страницы |
Примеры
PageProperties pageProperties = section.getPageProperties();
pageProperties.height = 100;
pageProperties.width = 200;
section.setPageProperties(pageProperties);
PageProperties pageProperties = new PageProperties();
pageProperties.height = 100;
pageProperties.width = 200;
document.setPageProperties(pageProperties);
PageProperties pageProperties = new PageProperties(100, 200);
document.setPageProperties(pageProperties);