class settings.Settings(parent, reset_settings=False)[source]

Bases: object

Contains all global application states.

  • parent (QWidget) – Parent widget, normally main window

  • reset_settings (bool) – Do not restore saved settings


Adds new file to history


value – File name to be added to history

border_choice = 'All borders'

The state of the border choice button

changed_since_save = False

If True then File actions trigger a dialog

default_column_width = 100
default_row_height = 30
digest_types = None

List of default digest types for preprocessing values from CSV import

encodings = ('ascii', 'big5', 'big5hkscs', 'cp037', 'cp424', 'cp437', 'cp500', 'cp720', 'cp737', 'cp775', 'cp850', 'cp852', 'cp855', 'cp856', 'cp857', 'cp858', 'cp860', 'cp861', 'cp862', 'cp863', 'cp864', 'cp865', 'cp866', 'cp869', 'cp874', 'cp875', 'cp932', 'cp949', 'cp950', 'cp1006', 'cp1026', 'cp1140', 'cp1250', 'cp1251', 'cp1252', 'cp1253', 'cp1254', 'cp1255', 'cp1256', 'cp1257', 'cp1258', 'euc-jp', 'euc-jis-2004', 'euc-jisx0213', 'euc-kr', 'gb2312', 'gbk', 'gb18030', 'hz', 'iso2022-jp', 'iso2022-jp-1', 'iso2022-jp-2', 'iso2022-jp-2004', 'iso2022-jp-3', 'iso2022-jp-ext', 'iso2022-kr', 'latin-1', 'iso8859-2', 'iso8859-3', 'iso8859-4', 'iso8859-5', 'iso8859-6', 'iso8859-7', 'iso8859-8', 'iso8859-9', 'iso8859-10', 'iso8859-13', 'iso8859-14', 'iso8859-15', 'iso8859-16', 'johab', 'koi8-r', 'koi8-u', 'mac-cyrillic', 'mac-greek', 'mac-iceland', 'mac-latin2', 'mac-roman', 'mac-turkish', 'ptcp154', 'shift-jis', 'shift-jis-2004', 'shift-jisx0213', 'utf-32', 'utf-32-be', 'utf-32-le', 'utf-16', 'utf-16-be', 'utf-16-le', 'utf-7', 'utf-8', 'utf-8-sig')

Encodings for importing files (e.g. CSV or SVG)

entry_line_font_family = 'Monospace'

Font family for entry line widget

file_history = []

Files in file history

find_dialog_state = None

Find dialog state - needs to be stored when dialog is closed

font_sizes = (6, 8, 10, 12, 14, 16, 18, 20, 24, 28, 32)


highlighter_limit = 1000000

Maximum length of code, for which the netry line enables highlighting

last_file_export_path = PosixPath('/root')

Initial Path for exporting files

last_file_import_path = PosixPath('/root')

Initial Path for importing files

last_file_input_path = PosixPath('/root')

Initial Path for opening files

last_file_output_path = PosixPath('/root')

Initial Path for saving files

macro_editor_font_family = 'Monospace'

Font family for macro editor widget

max_file_history = 5

Maximum number of files in file history

maxshape = (1000000, 100000, 100)

Maximum shape of the grid

print_zoom = None
refresh_timeout = 1000

Timeout for frozen cell updates in milliseconds


Reset to defaults


Restores application state from QSettings


Saves application state to QSettings

shape = (1000, 100, 3)

Default shape of initial grid (rows, columns, tables)

show_frozen = False

If True then frozen cell background is striped

show_statusbar_sum = True
signature_key = None

Key for signing save files

sniff_size = 65536

Number of bytes for csv sniffer sniff_size should be larger than 1st+2nd line

timeout = 1000

Timeout for cell calculations in milliseconds

widget_names = ['main_window', 'main_toolbar', 'find_toolbar', 'format_toolbar', 'macro_toolbar', 'entry_line', 'entry_line_dock']

Names of widgets with persistant states

zoom_levels = (0.4, 0.5, 0.6, 0.7, 0.8, 1.0, 1.2, 1.4, 1.6, 1.8, 2.0, 2.5, 3.0, 3.5, 4.0, 5.0, 6.0, 8.0)