interfaces.pys.*¶
This file contains interfaces to the native pys file format.
- PysReader and PysWriter classed are structured into the following sections:
shape
code
attributes
row_heights
col_widths
macros
Provides
-
class
interfaces.pys.PysReader(pys_file, code_array)[source]¶ Bases:
objectReads pys v2.0 file into a code_array
- Parameters
-
_pys2attributes_10(line)[source]¶ Updates attributes in code_array - for save file version 1.0
- Parameters
line (
str) – Pys file line to be parsed
-
_pys2code_10(line)[source]¶ Updates code in pys code_array - for save file version 1.0
- Parameters
line (
str) – Pys file line to be parsed
-
_pys2col_widths(line)[source]¶ Updates col_widths in code_array
- Parameters
line (
str) – Pys file line to be parsed
-
_pys2macros(line)[source]¶ Updates macros in code_array
- Parameters
line (
str) – Pys file line to be parsed
-
_pys2row_heights(line)[source]¶ Updates row_heights in code_array
- Parameters
line (
str) – Pys file line to be parsed
-
_pys2shape(line)[source]¶ Updates shape in code_array
- Parameters
line (
str) – Pys file line to be parsed
-
_pys_version(line)[source]¶ pys file version including assertion
- Parameters
line (
str) – Pys file line to be parsed
-
class
interfaces.pys.PysWriter(code_array)[source]¶ Bases:
objectInterface between code_array and pys file data
Iterating over it yields pys file lines
- Parameters
code_array (
CodeArray) – The code_array object data structure
-
_attributes2pys()[source]¶ Returns cell attributes information in pys format
Format: <selection[0]> […] <tab> <key> <value> […]
-
_col_widths2pys()[source]¶ Returns column width information in pys format
Format: <col> <tab> <value>
-
_row_heights2pys()[source]¶ Returns row height information in pys format
Format: <row> <tab> <value>
pyspread