pyface.data_view.value_types.text_value module¶
- class pyface.data_view.value_types.text_value.TextValue[source]¶
Bases:
EditableValue
Editable value that presents a string value.
- format = Callable(str, update_value_type=True)¶
A function that converts the value to a string for display.
- unformat = Callable(str)¶
A function that converts to a value from a display string.
- get_text(model, row, column)[source]¶
Get the display text from the underlying value.
- Parameters
model (AbstractDataModel) – The data model holding the data.
row (sequence of int) – The row in the data model being queried.
column (sequence of int) – The column in the data model being queried.
- Returns
text – The text to display.
- Return type
- set_text(model, row, column, text)[source]¶
Set the text of the underlying value.
- Parameters
model (AbstractDataModel) – The data model holding the data.
row (sequence of int) – The row in the data model being queried.
column (sequence of int) – The column in the data model being queried.
text (str) – The text to set.
- Raises
DataViewSetError – If the value cannot be set.