arelle.UITkTable

@author: Acsone S. A. See COPYRIGHT.md for copyright information.

Module Contents

Classes

Coordinate

MyToolTip

TableCombobox

XbrlTable

This class implements all the GUI elements needed for representing the sliced 2D-view of an Xbrl Table

ScrolledTkTableFrame

Data

API

arelle.UITkTable.USE_resizeTableCells

False

class arelle.UITkTable.Coordinate(row: int, column: int)

Initialization

class arelle.UITkTable.MyToolTip(master: tkinter.Misc, text: str | None = '', delay: int = 500, **opts: Any)

Bases: arelle.CntlrWinTooltip.ToolTip

Initialization

motion(event: tkinter.Event | None = None) None
configure(**opts: Any) None
enter(event: tkinter.Event[Any] | None = None) None
leave(event: tkinter.Event[Any] | None = None) None
coords() tuple[int, int]
create_contents() None
class arelle.UITkTable.TableCombobox(master=None, **kw)

Bases: tkinter.ttk.Combobox

property valueIndex: int
current(newindex=None)
set(value)
bbox(index)
identify(x, y)
validate()
instate(statespec, callback=None, *args, **kw)
state(statespec=None)
destroy()
deletecommand(name)
tk_strictMotif(boolean=None)
tk_bisque()
tk_setPalette(*args, **kw)
wait_variable(name='PY_VAR')
waitvar

None

wait_window(window=None)
wait_visibility(window=None)
setvar(name='PY_VAR', value='1')
getvar(name='PY_VAR')
getint(s)
getdouble(s)
getboolean(s)
focus_set()
focus

None

focus_force()
focus_get()
focus_displayof()
focus_lastfor()
tk_focusFollowsMouse()
tk_focusNext()
tk_focusPrev()
after(ms, func=None, *args, **kw)
after_idle(func, *args, **kw)
after_cancel(id)
after_info(id=None)
bell(displayof=0)
tk_busy_cget(option)
busy_cget

None

tk_busy_configure(cnf=None, **kw)
tk_busy_current(pattern=None)
busy_current

None

tk_busy_forget()
busy_forget

None

tk_busy_hold(**kw)
tk_busy_status()
busy_status

None

clipboard_get(**kw)
clipboard_clear(**kw)
clipboard_append(string, **kw)
grab_current()
grab_release()
grab_set()
grab_set_global()
grab_status()
option_add(pattern, value, priority=None)
option_clear()
option_get(name, className)
option_readfile(fileName, priority=None)
selection_clear(**kw)
selection_get(**kw)
selection_handle(command, **kw)
selection_own(**kw)
selection_own_get(**kw)
send(interp, cmd, *args)
lower(belowThis=None)
tkraise(aboveThis=None)
lift

None

info_patchlevel()
winfo_atom(name, displayof=0)
winfo_atomname(id, displayof=0)
winfo_cells()
winfo_children()
winfo_class()
winfo_colormapfull()
winfo_containing(rootX, rootY, displayof=0)
winfo_depth()
winfo_exists()
winfo_fpixels(number)
winfo_geometry()
winfo_height()
winfo_id()
winfo_interps(displayof=0)
winfo_ismapped()
winfo_manager()
winfo_name()
winfo_parent()
winfo_pathname(id, displayof=0)
winfo_pixels(number)
winfo_pointerx()
winfo_pointerxy()
winfo_pointery()
winfo_reqheight()
winfo_reqwidth()
winfo_rgb(color)
winfo_rootx()
winfo_rooty()
winfo_screen()
winfo_screencells()
winfo_screendepth()
winfo_screenheight()
winfo_screenmmheight()
winfo_screenmmwidth()
winfo_screenvisual()
winfo_screenwidth()
winfo_server()
winfo_toplevel()
winfo_viewable()
winfo_visual()
winfo_visualid()
winfo_visualsavailable(includeids=False)
winfo_vrootheight()
winfo_vrootwidth()
winfo_vrootx()
winfo_vrooty()
winfo_width()
winfo_x()
winfo_y()
update()
update_idletasks()
bindtags(tagList=None)
bind(sequence=None, func=None, add=None)
unbind(sequence, funcid=None)
bind_all(sequence=None, func=None, add=None)
unbind_all(sequence)
bind_class(className, sequence=None, func=None, add=None)
unbind_class(className, sequence)
mainloop(n=0)
quit()
nametowidget(name)
register

None

configure(cnf=None, **kw)
config

None

cget(key)
keys()
pack_propagate(flag=_noarg_)
propagate

None

pack_slaves()
slaves

None

place_slaves()
grid_anchor(anchor=None)
anchor

None

grid_bbox(column=None, row=None, col2=None, row2=None)
grid_columnconfigure(index, cnf={}, **kw)
columnconfigure

None

grid_location(x, y)
grid_propagate(flag=_noarg_)
grid_rowconfigure(index, cnf={}, **kw)
rowconfigure

None

grid_size()
size

None

grid_slaves(row=None, column=None)
event_add(virtual, *sequences)
event_delete(virtual, *sequences)
event_generate(sequence, **kw)
event_info(virtual=None)
image_names()
image_types()
pack_configure(cnf={}, **kw)
pack_forget()
forget

None

pack_info()
info

None

place_configure(cnf={}, **kw)
place_forget()
place_info()
grid_configure(cnf={}, **kw)
grid_forget()
grid_remove()
grid_info()
delete(first, last=None)
get()
icursor(index)
index(index)
insert(index, string)
scan_mark(x)
scan_dragto(x)
selection_adjust(index)
select_adjust

None

select_clear

None

selection_from(index)
select_from

None

selection_present()
select_present

None

selection_range(start, end)
select_range

None

selection_to(index)
select_to

None

xview(*args)
xview_moveto(fraction)
xview_scroll(number, what)
class arelle.UITkTable.XbrlTable(parentWidget: tkinter.Misc, rows: int, columns: int, titleRows: int, titleColumns: int, tableName: str | None = None, browsecmd: Callable[..., Any] | None = None)

Bases: arelle.TkTableWrapper.Table

This class implements all the GUI elements needed for representing the sliced 2D-view of an Xbrl Table

Initialization

The initial size of the table (including the header sizes) must be supplied at table creation time. The contextual menu will have to be created later with a “widget.contextMenu()” command. The Tab and Return key are bound to cell navigation.

TG_PREFIX

‘cFmt’

TG_TOP_LEFT

‘top-left-cell’

TG_LEFT_JUSTIFIED

‘left’

TG_RIGHT_JUSTIFIED

‘right’

TG_CENTERED

‘center’

TG_TOP_LEFT_JUSTIFIED

‘top-left’

ANCHOR_POSITIONS

None

JUSTIFICATIONS

None

TG_BG_WHITE

‘bg-white’

TG_BG_DEFAULT

None

TG_BG_YELLOW

‘bg-yellow’

TG_BG_ORANGE

‘bg-orange’

TG_BG_VIOLET

‘bg-violet’

TG_BG_GREEN

‘bg-green’

COLOURS

None

TG_DISABLED

‘disabled-cells’

TG_NO_BORDER

‘no-border’

TG_BORDER_ALL

‘border-all’

TG_BORDER_LEFT

‘border-left’

TG_BORDER_TOP

‘border-top’

TG_BORDER_RIGHT

‘border-right’

TG_BORDER_BOTTOM

‘border-bottom’

TG_BORDER_LEFT_TOP

‘border-left-top’

TG_BORDER_LEFT_RIGHT

‘border-left-right’

TG_BORDER_LEFT_BOTTOM

‘border-left-bottom’

TG_BORDER_TOP_RIGHT

‘border-top-right’

TG_BORDER_TOP_BOTTOM

‘border-top-bottom’

TG_BORDER_RIGHT_BOTTOM

‘border-right-bottom’

TG_BORDER_TOP_RIGHT_BOTTOM

‘border-top-right-bottom’

TG_BORDER_RIGHT_BOTTOM_LEFT

‘border-right-bottom-left’

TG_BORDER_BOTTOM_LEFT_TOP

‘border-bottom-left-top’

TG_BORDER_LEFT_TOP_RIGHT

‘border-left-top-right’

BORDERWIDTHS

None

BORDER_NAMES

None

MAX_COLUMN_WIDTH

20

MAX_ROW_HEIGHT

50

MAX_COLUMN_WIDTH_PLUS_1

None

DEFAULT_COLUMN_WIDTH

6

DEFAULT_ROW_HEIGHT

2

currentCellCoordinates: arelle.UITkTable.Coordinate | None

None

lastMouseCoordinates: arelle.UITkTable.Coordinate | None

None

toolTipShown: bool

None

headerToolTipText: tkinter.StringVar

None

headerToolTip: arelle.UITkTable.MyToolTip

None

modifiedCells: dict[arelle.UITkTable.Coordinate, bool]

None

titleRows: int

None

titleColumns: int

None

mouseMotion(event: tkinter.Event) bool
getCoordinatesFromEventXY(event: tkinter.Event) tuple[str | None, arelle.UITkTable.Coordinate | None]
cellRight(event: tkinter.Event, *args: Any) str
cellDown(event: tkinter.Event, *args: Any) str
format_cell(option: str, index: str) None
set(rc: Any = None, index: str | None = None, objectId: str | None = None, *args: Any, **kwargs: Any) None
clearModificationStatus() None
getObjectId(coordinate: arelle.UITkTable.Coordinate) str
setObjectId(coordinate: arelle.UITkTable.Coordinate, objectId: str) None
getTableValue(coordinate: arelle.UITkTable.Coordinate) str
isHeaderCell(coordinate: arelle.UITkTable.Coordinate) bool
getCoordinatesOfModifiedCells() Any
getCurrentCellCoordinates() arelle.UITkTable.Coordinate | None
initCellValue(value: str, x: int, y: int, backgroundColourTag: str | None = 'bg-white', justification: str = 'left', objectId: str | None = None) None

Initialise the content of a cell. The resulting cell will be writable.

initCellCombobox(value: str, values: tuple[str, ...], x: int, y: int, isOpen: bool = False, objectId: str | None = None, selectindex: int | None = None, comboboxselected: Callable[..., Any] | None = None, codes: dict[Any, Any] = dict()) arelle.UITkTable.TableCombobox

Initialise the content of a cell as a combobox. If isOpen=False, the combobox will be read-only, no new value can be added to the combobox.

initReadonlyCell(x: int, y: int) None

Make the specified cell read-only

initHeaderCellValue(value: str, x: int, y: int, colspan: int, rowspan: int, justification: str, objectId: str | None = None, hasLeftBorder: bool = True, hasTopBorder: bool = True, hasRightBorder: bool = True, hasBottomBorder: bool = True, width: int | None = None) None

Initialise the read-only content of a header cell.

initCellSpan(x: int, y: int, colspan: int, rowspan: int) None

Set the row and column span for the given cell

initHeaderCombobox(x: int, y: int, value: str = '', values: tuple[str, ...] = (), colspan: int = 0, rowspan: int = 0, isOpen: bool = True, objectId: str | None = None, selectindex: int | None = None, comboboxselected: Callable[..., Any] | None = None, codes: dict[Any, Any] = dict(), isRollUp: bool = False) arelle.UITkTable.TableCombobox

Initialise the read-only content of a header cell as a combobox. New values can be added to the combobox if isOpen==True.

drawBordersAroundCell(x: int, y: int, borders: int) None

The borders are coded in an integer: 2^0 = bottom 2^1 = top 2^2 = right 2^3 = left

initHeaderBorder(x: int, y: int, cellsToTheRight: int = 0, cellsBelow: int = 0, hasLeftBorder: bool = False, hasTopBorder: bool = False, hasRightBorder: bool = False, hasBottomBorder: bool = False) None

Set the border around a group of header cells. The rectangular group of cells will start at position (x,y) and possibly extend cellsToTheRight cells to the right and/or cellsBelow cells below the given position. The border will always have the same size.

resizeTable(rows: int, columns: int, titleRows: int = -1, titleColumns: int = -1, clearData: bool = True) None

Resize a table. Only positive increases are allowed. Negative increases will be ignored. All numbers are absolute numbers and the actual increase will be computed by this method. If titleRows or titleColumns is less than 0, the corresponding axis will not be updated either.

clearSpans() None
clearTags() None
disableUnusedCells() None
resizeTableCells() None
class arelle.UITkTable.ScrolledTkTableFrame(parent: tkinter.Misc, browseCmd: Callable[..., Any] | None, *args: Any, **kw: Any)

Bases: tkinter.ttk.Frame

clearGrid() None
identify(x, y)
instate(statespec, callback=None, *args, **kw)
state(statespec=None)
destroy()
deletecommand(name)
tk_strictMotif(boolean=None)
tk_bisque()
tk_setPalette(*args, **kw)
wait_variable(name='PY_VAR')
waitvar

None

wait_window(window=None)
wait_visibility(window=None)
setvar(name='PY_VAR', value='1')
getvar(name='PY_VAR')
getint(s)
getdouble(s)
getboolean(s)
focus_set()
focus

None

focus_force()
focus_get()
focus_displayof()
focus_lastfor()
tk_focusFollowsMouse()
tk_focusNext()
tk_focusPrev()
after(ms, func=None, *args, **kw)
after_idle(func, *args, **kw)
after_cancel(id)
after_info(id=None)
bell(displayof=0)
tk_busy_cget(option)
busy_cget

None

tk_busy_configure(cnf=None, **kw)
tk_busy_current(pattern=None)
busy_current

None

tk_busy_forget()
busy_forget

None

tk_busy_hold(**kw)
tk_busy_status()
busy_status

None

clipboard_get(**kw)
clipboard_clear(**kw)
clipboard_append(string, **kw)
grab_current()
grab_release()
grab_set()
grab_set_global()
grab_status()
option_add(pattern, value, priority=None)
option_clear()
option_get(name, className)
option_readfile(fileName, priority=None)
selection_clear(**kw)
selection_get(**kw)
selection_handle(command, **kw)
selection_own(**kw)
selection_own_get(**kw)
send(interp, cmd, *args)
lower(belowThis=None)
tkraise(aboveThis=None)
lift

None

info_patchlevel()
winfo_atom(name, displayof=0)
winfo_atomname(id, displayof=0)
winfo_cells()
winfo_children()
winfo_class()
winfo_colormapfull()
winfo_containing(rootX, rootY, displayof=0)
winfo_depth()
winfo_exists()
winfo_fpixels(number)
winfo_geometry()
winfo_height()
winfo_id()
winfo_interps(displayof=0)
winfo_ismapped()
winfo_manager()
winfo_name()
winfo_parent()
winfo_pathname(id, displayof=0)
winfo_pixels(number)
winfo_pointerx()
winfo_pointerxy()
winfo_pointery()
winfo_reqheight()
winfo_reqwidth()
winfo_rgb(color)
winfo_rootx()
winfo_rooty()
winfo_screen()
winfo_screencells()
winfo_screendepth()
winfo_screenheight()
winfo_screenmmheight()
winfo_screenmmwidth()
winfo_screenvisual()
winfo_screenwidth()
winfo_server()
winfo_toplevel()
winfo_viewable()
winfo_visual()
winfo_visualid()
winfo_visualsavailable(includeids=False)
winfo_vrootheight()
winfo_vrootwidth()
winfo_vrootx()
winfo_vrooty()
winfo_width()
winfo_x()
winfo_y()
update()
update_idletasks()
bindtags(tagList=None)
bind(sequence=None, func=None, add=None)
unbind(sequence, funcid=None)
bind_all(sequence=None, func=None, add=None)
unbind_all(sequence)
bind_class(className, sequence=None, func=None, add=None)
unbind_class(className, sequence)
mainloop(n=0)
quit()
nametowidget(name)
register

None

configure(cnf=None, **kw)
config

None

cget(key)
keys()
pack_propagate(flag=_noarg_)
propagate

None

pack_slaves()
slaves

None

place_slaves()
grid_anchor(anchor=None)
anchor

None

grid_bbox(column=None, row=None, col2=None, row2=None)
bbox

None

grid_columnconfigure(index, cnf={}, **kw)
columnconfigure

None

grid_location(x, y)
grid_propagate(flag=_noarg_)
grid_rowconfigure(index, cnf={}, **kw)
rowconfigure

None

grid_size()
size

None

grid_slaves(row=None, column=None)
event_add(virtual, *sequences)
event_delete(virtual, *sequences)
event_generate(sequence, **kw)
event_info(virtual=None)
image_names()
image_types()
pack_configure(cnf={}, **kw)
pack_forget()
forget

None

pack_info()
info

None

place_configure(cnf={}, **kw)
place_forget()
place_info()
grid_configure(cnf={}, **kw)
grid_forget()
grid_remove()
grid_info()