Module section

Module section 

Source
Expand description

Document sections.

A Section is a contiguous block of paragraphs sharing the same PageSettings. Typical HWP documents have one section, but complex reports may mix portrait and landscape sections.

§Examples

use hwpforge_core::section::Section;
use hwpforge_core::PageSettings;
use hwpforge_core::paragraph::Paragraph;
use hwpforge_core::run::Run;
use hwpforge_foundation::{CharShapeIndex, ParaShapeIndex};

let mut section = Section::new(PageSettings::a4());
section.add_paragraph(Paragraph::with_runs(
    vec![Run::text("Hello", CharShapeIndex::new(0))],
    ParaShapeIndex::new(0),
));
assert_eq!(section.paragraph_count(), 1);

Structs§

BeginNum
Starting numbers for various auto-numbering sequences.
HeaderFooter
A header or footer region containing paragraphs.
LineNumberShape
Line numbering settings for a section.
MasterPage
A master page (background/watermark page) for a section.
PageBorderFillEntry
A single page border/fill entry for the section.
PageNumber
Page number display settings for a section.
Section
A document section: paragraphs + page geometry.
Visibility
Controls visibility of headers, footers, master pages, borders, and fills.