tik_manager4.ui.widgets.common
Common usage basic widgets.
Attributes
Classes
Clickable frame widget. |
|
Label with bold font and indent. |
|
Simple vertical separator. |
|
Label for resolved paths, names etc. |
|
Convenience class to edit the style of a widget. |
|
Frame with custom styler. |
|
Unified button class for the whole app. |
|
Unified button box class for the whole app. |
|
Button specific for fixed sized icons. |
|
Unified label class for the whole app. |
|
Customize the button to be used next to the header. |
|
Simple horizontal separator. |
Functions
|
Lightens the given color. |
Module Contents
- class ClickableFrame(*args, **kwargs)
Bases:
tik_manager4.ui.Qt.QtWidgets.QFrameClickable frame widget.
- mousePressEvent(event)
- clicked
- class HeaderLabel(*args, **kwargs)
Bases:
TikLabelLabel with bold font and indent.
- set_font_size(font_size, bold=True)
- style_sheet = Multiline-String
Show Value
""" QLabel { background-color: #404040; border-width: 1px; border-color: #1e1e1e; border-style: solid; padding: 5px; font-size: 12x; border-radius: 14px; } """
- class HorizontalSeparator(color=(100, 100, 100), height=1, width=None)
Bases:
tik_manager4.ui.Qt.QtWidgets.QLabelSimple vertical separator.
- set_color(color)
- class ResolvedText(*args, **kwargs)
Bases:
TikLabelLabel for resolved paths, names etc.
- set_font_size(font_size, bold=True)
- class StyleEditor
Convenience class to edit the style of a widget.
- static dictionary_to_stylesheet(styles)
- static stylesheet_to_dictionary(stylesheet)
- background_color = '#404040'
- border_color = '#1e1e1e'
- text_color = '#b1b1b1'
- class StyleFrame(*args, **kwargs)
Bases:
ClickableFrame,StyleEditorFrame with custom styler.
- class TikButton(text='', font_size=10, text_color='#b1b1b1', border_color='#1e1e1e', background_color='#404040', *args, **kwargs)
Bases:
tik_manager4.ui.Qt.QtWidgets.QPushButton,StyleEditorUnified button class for the whole app.
- set_color(text_color=None, background_color=None, border_color=None)
- set_font_size(font_size)
- class TikButtonBox(*args, font_size=10, **kwargs)
Bases:
tik_manager4.ui.Qt.QtWidgets.QDialogButtonBoxUnified button box class for the whole app.
- event(event)
- modifyButton(button)
- set_font_size(font_size)
- class TikIconButton(icon_name=None, circle=True, size=22, icon_size=None, **kwargs)
Bases:
TikButtonButton specific for fixed sized icons.
- set_icon(icon_name)
- set_size(size)
- static square_to_circle_multiplier(side_length)
- class TikLabel(*args, text='', font_size=10, bold=False, color=(255, 255, 255), **kwargs)
Bases:
tik_manager4.ui.Qt.QtWidgets.QLabel,StyleEditorUnified label class for the whole app.
- set_color(text_color=None, background_color=None, border_color=None)
- set_font_size(font_size, bold=False)
- set_text(text)
- class TikLabelButton(*args, color=(255, 255, 255), **kwargs)
Bases:
TikButtonCustomize the button to be used next to the header.
- set_state_text(checked)
- style_sheet = Multiline-String
Show Value
""" QPushButton {{ color: {0}; background-color: #404040; border-width: 1px; border-color: {0}; border-style: solid; padding: 5px; font-size: 12x; border-radius: 0px; }}"""
- class TikMessageBox(*args, font_size=10, **kwargs)
Bases:
tik_manager4.ui.Qt.QtWidgets.QMessageBox- set_font_size(font_size)
- class VerticalSeparator(color=(100, 100, 100), height=25, width=20)
Bases:
tik_manager4.ui.Qt.QtWidgets.QLabelSimple horizontal separator.
- set_color(color)
- lighten_color(color_str, factor=110)
Lightens the given color.
- Args:
color_str (str): The color to lighten as a hex string. factor (int): The percentage to lighten (100 = no change, >100 = lighter, <100 = darker).
- Returns:
str: A lighter color as a hex string.
- BUTTON_STYLE = Multiline-String
Show Value
""" QPushButton { color: #b1b1b1; background-color: #404040; border-width: 1px; border-color: #1e1e1e; border-style: solid; padding: 5px; font-size: 12x; border-radius: 4px; } QPushButton:hover { background-color: #505050; border: 1px solid #ff8d1c; } QPushButton:hover[circle=true] { background-color: #505050; border: 2px solid #ff8d1c; } QPushButton:disabled { color: #505050; background-color: #303030; border: 1px solid #404040; border-width: 1px; border-color: #1e1e1e; border-style: solid; padding: 5px; font-size: 12x; } QPushButton:pressed { background-color: #ff8d1c; border: 1px solid #ff8d1c; } """
- FONT = 'Arial'