cottax.consumers.visualization.interface_types module¶
What a drawing is answered with: a condition node’s Drawn, its Kind and Slot`s; and the `Notation`s a `Formatter writes a minted name in.
- class Kind(name: str, legend: str, title: str, slotted: bool, colour: tuple[str, str])[source]¶
Bases:
FrozenA category of problem: a language’s own, which the drawing names nowhere. name is its short name, what a struct calls it; two categories with one name are refused in one picture. legend is what a key says, title what hovering says. slotted: its reads are of mixed kind, so its slots are drawn by default. colour is its (fill, stroke) on a light ground, which a style draws as it is or derives its own from (Style.ground), written on each shape drawn in it.
- name: str¶
- legend: str¶
- title: str¶
- slotted: bool¶
- colour: tuple[str, str]¶
- class Text(plain: str, latex: str)[source]¶
Bases:
FrozenA text naming no place, written in each source a Formatter sets from: plain, and latex – Text(’≤ 0’, r’leq 0’).
- plain: str¶
- latex: str¶
- class Slot(label: tuple[Text | Place, ...], reads: tuple[Place, ...])[source]¶
Bases:
FrozenSome of a problem’s reads under one label. label is texts and places in order – (Text(‘min’, r’min’),), (Text(’= ‘, ‘= ‘), u), (lhs, Text(’ = ‘, ‘ = ‘), rhs) – set by the drawing: a text as Formatter.text, a place as its shown name.
- class Drawn(kind: Kind | None, slots: tuple[Slot, ...])[source]¶
Bases:
FrozenHow one condition node is drawn: its category (None: none, a grey problem) and its slots, in the order its driver is handed them.
- class Notation[source]¶
Bases:
FrozenHow a name minted in a namespace is written over the place it stands for.