Table of Contents

Class OdfConditionalFormatInfo

Namespace
OdfKit.Spreadsheet
Assembly
OdfKit.dll

Represents summary information for a LibreOffice calcext conditional formatting rule in a worksheet. 表示工作表中一筆 LibreOffice calcext 條件格式規則的摘要資訊。

public sealed class OdfConditionalFormatInfo
Inheritance
OdfConditionalFormatInfo
Inherited Members

Constructors

OdfConditionalFormatInfo(OdfConditionalFormatKind, string, string?, string?, OdfColor?, OdfColor?, OdfColor?, OdfColor?, OdfColor?, string?, OdfIconSetType?)

Represents summary information for a LibreOffice calcext conditional formatting rule in a worksheet. 表示工作表中一筆 LibreOffice calcext 條件格式規則的摘要資訊。

public OdfConditionalFormatInfo(OdfConditionalFormatKind kind, string targetRangeAddress, string? conditionValue = null, string? styleName = null, OdfColor? minColor = null, OdfColor? maxColor = null, OdfColor? midColor = null, OdfColor? positiveColor = null, OdfColor? negativeColor = null, string? iconSetTypeName = null, OdfIconSetType? iconSetType = null)

Parameters

kind OdfConditionalFormatKind

The conditional formatting kind. / 條件格式種類。

targetRangeAddress string

The ODF target range address string from calcext:target-range-address. / ODF 目標範圍位址字串(calcext:target-range-address)。

conditionValue string

The condition expression, available only for Condition. / 條件運算式,僅 Condition 時有值。

styleName string

The style name to apply, available only for Condition. / 要套用的樣式名稱,僅 Condition 時有值。

minColor OdfColor?

The color scale minimum color, available only for ColorScale. / 色階最小值色彩,僅 ColorScale 時有值。

maxColor OdfColor?

The color scale maximum color, available only for ColorScale. / 色階最大值色彩,僅 ColorScale 時有值。

midColor OdfColor?

The color scale midpoint color, available for three-color scales. / 色階中間值色彩,三色色階時有值。

positiveColor OdfColor?

The data bar positive value color, available only for DataBar. / 資料橫條正值色彩,僅 DataBar 時有值。

negativeColor OdfColor?

The optional data bar negative value color. / 資料橫條負值色彩,可選。

iconSetTypeName string

The original icon set type name from calcext:icon-set-type. / 圖示集類型名稱(calcext:icon-set-type 原文)。

iconSetType OdfIconSetType?

The recognized icon set type, or null when it cannot be mapped. / 已辨識的圖示集類型,無法對應時為 null

Properties

ConditionValue

Gets the condition expression. 取得條件運算式。

public string? ConditionValue { get; }

Property Value

string

IconSetType

Gets the recognized icon set type. 取得已辨識的圖示集類型。

public OdfIconSetType? IconSetType { get; }

Property Value

OdfIconSetType?

IconSetTypeName

Gets the original icon set type name. 取得圖示集類型名稱原文。

public string? IconSetTypeName { get; }

Property Value

string

Kind

Gets the conditional formatting kind. 取得條件格式種類。

public OdfConditionalFormatKind Kind { get; }

Property Value

OdfConditionalFormatKind

MaxColor

Gets the color scale maximum color. 取得色階最大值色彩。

public OdfColor? MaxColor { get; }

Property Value

OdfColor?

MidColor

Gets the color scale midpoint color. 取得色階中間值色彩。

public OdfColor? MidColor { get; }

Property Value

OdfColor?

MinColor

Gets the color scale minimum color. 取得色階最小值色彩。

public OdfColor? MinColor { get; }

Property Value

OdfColor?

NegativeColor

Gets the data bar negative value color. 取得資料橫條負值色彩。

public OdfColor? NegativeColor { get; }

Property Value

OdfColor?

PositiveColor

Gets the data bar positive value color. 取得資料橫條正值色彩。

public OdfColor? PositiveColor { get; }

Property Value

OdfColor?

StyleName

Gets the style name to apply. 取得要套用的樣式名稱。

public string? StyleName { get; }

Property Value

string

TargetRangeAddress

Gets the ODF target range address string. 取得 ODF 目標範圍位址字串。

public string TargetRangeAddress { get; }

Property Value

string

Methods

TryGetTargetRange(out OdfCellRange)

Attempts to parse TargetRangeAddress as an OdfCellRange. 嘗試將 TargetRangeAddress 解析為 OdfCellRange

public bool TryGetTargetRange(out OdfCellRange range)

Parameters

range OdfCellRange

The cell range returned when parsing succeeds. / 解析成功時傳回的儲存格範圍。

Returns

bool

true if parsing succeeds; otherwise, false. / 若解析成功則為 true,否則為 false