Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion helper/styles.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
MAIN_WINDOW_STYLE = """
QMainWindow {
background-color: #f0f0f0;
color: #333333;
}
"""

Expand Down Expand Up @@ -148,6 +149,7 @@
COMBOBOX_STYLE = """
QComboBox {
background-color: white;
color: #333333;
border: 1px solid #ccc;
border-radius: 4px;
padding: 4px 8px;
Expand Down Expand Up @@ -335,7 +337,7 @@ def get_tactic_header_style(bg_color):
HTML_SUCCESS_COLOR = "#28a745"

# System type / inputs
INPUT_LINE_STYLE = "padding: 8px; font-size: 11pt; border: 1px solid #ccc; border-radius: 4px;"
INPUT_LINE_STYLE = "padding: 8px; font-size: 11pt; border: 1px solid #ccc; border-radius: 4px; color: #333333; background-color: #ffffff;"

# Knowledge Base (KB) resources - shared text/tree/detail styles
TEXT_EDIT_KB_DETAIL_DIALOG = """
Expand Down
21 changes: 20 additions & 1 deletion kanvas.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,25 @@ def helpEvent(self, event, view, option, index):
class MainApp:
def __init__(self):
self.app = QApplication(sys.argv)
self.app.setStyle("Fusion")

from PySide6.QtGui import QPalette
palette = QPalette()
palette.setColor(QPalette.Window, QColor(240, 240, 240))
palette.setColor(QPalette.WindowText, Qt.black)
palette.setColor(QPalette.Base, QColor(255, 255, 255))
palette.setColor(QPalette.AlternateBase, QColor(240, 240, 240))
palette.setColor(QPalette.ToolTipBase, Qt.white)
palette.setColor(QPalette.ToolTipText, Qt.black)
palette.setColor(QPalette.Text, Qt.black)
palette.setColor(QPalette.Button, QColor(240, 240, 240))
palette.setColor(QPalette.ButtonText, Qt.black)
palette.setColor(QPalette.BrightText, Qt.red)
palette.setColor(QPalette.Link, QColor(42, 130, 218))
palette.setColor(QPalette.Highlight, QColor(42, 130, 218))
palette.setColor(QPalette.HighlightedText, Qt.white)
self.app.setPalette(palette)

logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(name)s - %(levelname)s - %(message)s', filename='kanvas.log')
self.logger = logging.getLogger(__name__)
image_dir = os.path.join(os.path.dirname(os.path.abspath(__file__)), "images")
Expand Down Expand Up @@ -2223,4 +2242,4 @@ def application_cleanup(self):

if __name__ == "__main__":
main_app = MainApp()
sys.exit(main_app.run())
sys.exit(main_app.run())