fastpyxl.formatting.rule module

fastpyxl.formatting.rule.CellIsRule(operator=None, formula=None, stopIfTrue=None, font=None, border=None, fill=None)[source]

Conditional formatting rule based on cell contents.

class fastpyxl.formatting.rule.ColorScale(cfvo=None, color=None)[source]

Bases: RuleType

color: list[Color]
tagname = 'colorScale'
xml_order = ('cfvo', 'color')
fastpyxl.formatting.rule.ColorScaleRule(start_type=None, start_value=None, start_color=None, mid_type=None, mid_value=None, mid_color=None, end_type=None, end_value=None, end_color=None)[source]

Backwards compatibility

class fastpyxl.formatting.rule.DataBar(minLength=None, maxLength=None, showValue=None, cfvo=None, color=None)[source]

Bases: RuleType

color: Color | None
maxLength: int | None
minLength: int | None
showValue: bool | None
tagname = 'dataBar'
xml_order = ('cfvo', 'color')
fastpyxl.formatting.rule.DataBarRule(start_type=None, start_value=None, end_type=None, end_value=None, color=None, showValue=None, minLength=None, maxLength=None)[source]
class fastpyxl.formatting.rule.FormatObject(type, val=None, gte=None, extLst=None)[source]

Bases: Serialisable

extLst: ExtensionList | None
gte: bool | None
tagname = 'cfvo'
type: str | None
val: object | None
fastpyxl.formatting.rule.FormulaRule(formula=None, stopIfTrue=None, font=None, border=None, fill=None)[source]

Conditional formatting with custom differential style

class fastpyxl.formatting.rule.IconSet(iconSet=None, showValue=None, percent=None, reverse=None, cfvo=None)[source]

Bases: RuleType

iconSet: str | None
percent: bool | None
reverse: bool | None
showValue: bool | None
tagname = 'iconSet'
xml_order = ('cfvo',)
fastpyxl.formatting.rule.IconSetRule(icon_style=None, type=None, values=None, showValue=None, percent=None, reverse=None)[source]

Convenience function for creating icon set rules

class fastpyxl.formatting.rule.Rule(type, dxfId=None, priority=0, stopIfTrue=None, aboveAverage=None, percent=None, bottom=None, operator=None, text=None, timePeriod=None, rank=None, stdDev=None, equalAverage=None, formula=(), colorScale=None, dataBar=None, iconSet=None, extLst=None, dxf=None)[source]

Bases: Serialisable

aboveAverage: bool | None
bottom: bool | None
colorScale: ColorScale | None
dataBar: DataBar | None
dxf: DifferentialStyle | None
dxfId: int | None
equalAverage: bool | None
extLst: ExtensionList | None
formula: list[str]
iconSet: IconSet | None
operator: str | None
percent: bool | None
priority: int | None
rank: int | None
stdDev: int | None
stopIfTrue: bool | None
tagname = 'cfRule'
text: str | None
timePeriod: str | None
type: str | None
xml_order = ('colorScale', 'dataBar', 'iconSet', 'formula')
class fastpyxl.formatting.rule.RuleType(**kwargs: Any)[source]

Bases: Serialisable

cfvo: list[FormatObject]