styles

Style collection.

styles.StyleCollection

collections.styles.StyleCollection(app)

doc.styles — paragraph-style collection (minimal Phase 3 impl).

Enumeration requires a live HWP runtime because HWP COM doesn’t expose a direct style list. This stub is Protocol-compliant; full enumeration will land after Phase 4 when the HWPML-export path is ported over from hwpapi/classes/styles.py.

Attributes

Name Description
current Paragraph style currently applied at the cursor, or None.

Methods

Name Description
names Empty until HWPML-based enumeration is ported.

names

collections.styles.StyleCollection.names()

Empty until HWPML-based enumeration is ported.

styles.Style

collections.styles.Style(app, name, index=None)

Value object for a single paragraph style.

Methods

Name Description
apply Apply this style to the current cursor paragraph.

apply

collections.styles.Style.apply()

Apply this style to the current cursor paragraph.

Back to top