Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/

API Reference

Class

OdfStyle

Namespace OfficeIMO.OpenDocument
Assembly OfficeIMO.OpenDocument
Source revision 804a7612eee4 with working tree changes
Modifiers sealed

An XML-backed common or automatic ODF style.

Inheritance

  • Object
  • OdfStyle

Usage

Explore 9 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters 2

Methods

public OdfStyleMap AddConditionalMap(String condition, String applyStyleName, String? baseCellAddress = null) #
Returns: OdfStyleMap

Adds a native ODF conditional style mapping.

Parameters

condition System.String requiredposition: 0
applyStyleName System.String requiredposition: 1
baseCellAddress System.String? = null optionalposition: 2

Properties

public String Name { get; } #

Style name.

public OdfStyleFamily Family { get; } #

Style family.

public String? ParentStyleName { get; set; } #

Optional parent style name.

public Boolean IsAutomatic { get; } #

True for an automatic style.

public IReadOnlyList<OdfStyleMap> ConditionalMaps { get; } #

Conditional style mappings in their authored evaluation order.

public String? DataStyleName { get; set; } #

Referenced number, currency, percentage, date, or time data style.

public Boolean? Bold { get; set; } #

True when bold text is explicitly enabled by this style.

public Boolean? Italic { get; set; } #

True when italic text is explicitly enabled by this style.

public Boolean? Underline { get; set; } #

True when text underline is explicitly enabled by this style.

public OdfTextDecorationStyle? UnderlineStyle { get; set; } #

Explicit native ODF underline line style.

public OdfTextDecorationType? UnderlineType { get; set; } #

Explicit native ODF underline line count.

public Boolean? UsesNonSolidUnderlineStyle { get; } #

Whether this style explicitly uses an underline variant other than solid or none.

public Boolean? StrikeThrough { get; set; } #

True when text strike-through is explicitly enabled by this style.

public OdfTextDecorationStyle? LineThroughStyle { get; set; } #

Explicit native ODF line-through style.

public OdfTextDecorationType? LineThroughType { get; set; } #

Explicit native ODF line-through count.

public Boolean? UsesNonSolidLineThroughStyle { get; } #

Whether this style explicitly uses a line-through variant other than solid or none.

public OdfLength? FontSize { get; set; } #

Explicit font size.

public String? TextPositionValue { get; set; } #

Exact ODF style:text-position value, including authored percentages.

public OdfTextPosition? TextPosition { get; set; } #

Common native ODF baseline placement.

public OdfTextTransform? TextTransform { get; set; } #

Native ODF display-time case transformation.

public Boolean? SmallCaps { get; set; } #

Native ODF small-cap display formatting.

public String? FontFamily { get; set; } #

Explicit font family.

public OdfColor? Color { get; set; } #

Explicit text color.

public Double? TextOpacity { get; set; } #

Explicit text opacity from zero to one. Null means no declaration in this style.

Exceptions

  • InvalidDataException – An imported declaration is invalid or its aliases conflict.
  • ArgumentOutOfRangeException – The assigned value is not finite or is outside zero to one.
public OdfColor? TextBackgroundColor { get; set; } #

Explicit text background color, commonly used for highlighting.

public OdfColor? BackgroundColor { get; set; } #

Explicit cell or paragraph background color.

public String? BreakBefore { get; set; } #

Explicit paragraph break-before value.

public String? TextAlign { get; set; } #

Explicit horizontal paragraph alignment.

public String? CellTextAlignSource { get; set; } #

Whether table-cell horizontal alignment is fixed or follows the value type.

public String? CellVerticalAlign { get; set; } #

Explicit table-cell vertical alignment token.

public String? CellWrapOption { get; set; } #

Explicit table-cell text wrapping token.

public String? WritingMode { get; set; } #

Explicit ODF paragraph writing-mode token.

public OdfLength? LineHeight { get; set; } #

Explicit paragraph line height, including absolute and percentage values.

public OdfLength? MarginLeft { get; set; } #

Explicit paragraph start margin.

public OdfLength? MarginRight { get; set; } #

Explicit paragraph end margin.

public OdfLength? MarginTop { get; set; } #

Explicit paragraph top margin.

public OdfLength? MarginBottom { get; set; } #

Explicit paragraph bottom margin.

public OdfLength? TextIndent { get; set; } #

Explicit first-line paragraph indentation.