Gnm.StyleConditions

g GObject.Object GObject.Object Gnm.StyleConditions Gnm.StyleConditions GObject.Object->Gnm.StyleConditions

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

new (sheet)

delete (pos)

details ()

dup ()

dup_to (sheet)

equal (scb, relax_sheet)

eval (pos)

get_pos ()

get_sheet ()

hash ()

insert (cond, pos)

overlay (base)

set_pos (pos)

Virtual Methods

Inherited:

GObject.Object (7)

Properties

None

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Class Details

class Gnm.StyleConditions(**kwargs)
Bases:

GObject.Object

Abstract:

No

classmethod new(sheet)
Parameters:

sheet (Gnm.Sheet) – Gnm.Sheet

Returns:

a Gnm.StyleConditions

Return type:

Gnm.StyleConditions

Convenience tool to create a Gnm.StyleCondition. Straight g_object_new will work too.

delete(pos)
Parameters:

pos (int) –

details()
Returns:

style details.

Return type:

[Gnm.StyleCond]

dup()
Returns:

the duplicated Gnm.StyleConditions.

Return type:

Gnm.StyleConditions or None

dup_to(sheet)
Parameters:

sheet (Gnm.Sheet) – Gnm.Sheet that the duplicate should live on

Returns:

the duplicated Gnm.StyleConditions.

Return type:

Gnm.StyleConditions or None

equal(scb, relax_sheet)
Parameters:
Returns:

True if the conditions are equal.

Return type:

bool

eval(pos)
Parameters:

pos (Gnm.EvalPos) – Gnm.EvalPos

Returns:

the condition to use or -1 if none match.

Return type:

int

get_pos()
Returns:

The position at which relative addresses in the conditions will be evaluated. This may be None if no conditions require a position.

Return type:

Gnm.CellPos or None

get_sheet()
Returns:

the Gnm.Sheet.

Return type:

Gnm.Sheet

hash()
Return type:

int

insert(cond, pos)
Parameters:

Insert cond before pos (append if pos < 0).

overlay(base)
Parameters:

base (Gnm.Style) – Gnm.Style

Returns:

an array of Gnm.Style.

Return type:

[Gnm.Style]

set_pos(pos)
Parameters:

pos (Gnm.CellPos) – new position

Sets the position of self, i.e., the position at which relative addresses in the conditions will be evaluated.