wordless/wl_widgets/wl_tables.py
Wl_Table
has 35 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class Wl_Table(QTableView):
def __init__(
self, parent,
headers, header_orientation = 'hor',
editable = False,
Function __init__
has 13 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 13 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 13 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 13 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function ins_headers_hor
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def ins_headers_hor(
Function ins_header_hor
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def ins_header_hor(
Function add_headers_hor
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_headers_hor(
Function add_header_hor
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_header_hor(
Function ins_headers_vert
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def ins_headers_vert(
Function ins_header_vert
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def ins_header_vert(
Function add_header_vert
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_header_vert(
Avoid deeply nested control flow statements. Open
Open
for col in cols:
row_to_exp.append(self.table.model().item(row, col).text())
Avoid deeply nested control flow statements. Open
Open
if not self.isRowHidden(row):
item = self.model().item(row, col)
item.setText(f'{item.val:.{precision_decimals}}')
# Percentages
Avoid deeply nested control flow statements. Open
Open
for col in cols:
if self.table.model().item(row, col):
cell_text = self.table.model().item(row, col).text()
else:
cell_text = self.table.indexWidget(self.table.model().index(row, col)).text()
Avoid deeply nested control flow statements. Open
Open
if not self.isRowHidden(row):
item = self.model().item(row, col)
val_cum += item.val
item.setText(f'{val_cum:.{precision_decimals}}')
Avoid deeply nested control flow statements. Open
Open
if not self.isRowHidden(row):
item = self.model().item(row, col)
item.setText(str(item.val))
# Floats
Avoid deeply nested control flow statements. Open
Open
if not self.isRowHidden(row):
item = self.model().item(row, col)
val_cum += item.val
item.setText(str(val_cum))
Avoid deeply nested control flow statements. Open
Open
if not self.isRowHidden(row):
item = self.model().item(row, col)
val_cum += item.val
item.setText(f'{val_cum:.{precision_pcts}%}')
Avoid deeply nested control flow statements. Open
Open
if not self.isRowHidden(row):
item = self.model().item(row, col)
item.setText(f'{item.val:.{precision_pcts}%}')
elif self.header_orientation == 'vert':
Function add_headers_vert
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_headers_vert(
Function set_item_err
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def set_item_err(self, row, col, text, alignment_hor = 'center'):
Function __init__
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function set_item_num
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def set_item_num(self, row, col, val, total = -1):