Commit graph

4 commits

Author SHA1 Message Date
zmworm
510b807bb6 fix: resolve CS8602 null dereference and IL2026 trim warnings 2026-04-03 16:51:09 +08:00
zmworm
c732a744a9 fix: 4 schema order and bool prop bugs across Word/Excel handlers
- Word: use AddChild for TitlePage in sectPr to respect schema order
- Word: use AppendToParent in CopyFrom to insert before SectionProperties
- Word: use AddChild for UpdateFieldsOnOpen/DisplayBackgroundShape in Settings
- Word: fix EnsurePageMargin to insert after PageSize instead of AppendChild
- Excel: only report true bool props in Format (false is OOXML default)
- Excel: clear bool attributes and cleanup empty elements when setting to false
2026-04-03 02:39:32 +08:00
zmworm
17e62c339d fix: Excel workbook boolean properties now output false instead of omitting
PopulateWorkbookSettings used == true filter which dropped explicit false
values. Changed 8 conditions to != null so false is distinguishable from
unset, consistent with the PPT show.narration fix.
2026-04-02 15:52:59 +08:00
zmworm
4a29fa1b42 feat: add document-level L2 Set/Get for all Office formats
Add comprehensive document-level property support via Set("/") and Get("/"):

Word: DocGrid, CJK layout (AutoSpace/Kinsoku/OverflowPunct),
CharSpacingControl, print/display flags, font embedding,
layout flags (MirrorMargins/GutterAtTop/BookFold/EvenOddHeaders),
DefaultTabStop, Columns, SectionType, Compatibility (63 flags +
presets), DocDefaults (font/size/color/bold/italic/alignment/spacing)

Excel: WorkbookProperties, CalculationProperties, WorkbookProtection

PowerPoint: firstSlideNum, rtl, compatMode, PrintingProperties,
ShowProperties

Common: Theme ColorScheme/FontScheme Get+Set, ExtendedProperties
(Template/Company/Manager)

All settings maintain OOXML schema element ordering via AddChild.
2026-04-02 14:40:42 +08:00