Skip to content

Break up ui.py into seperate class-only python files.#27

Open
jdunns wants to merge 11 commits into
mainfrom
26-break-up-uipy
Open

Break up ui.py into seperate class-only python files.#27
jdunns wants to merge 11 commits into
mainfrom
26-break-up-uipy

Conversation

@jdunns

@jdunns jdunns commented Jun 5, 2026

Copy link
Copy Markdown
Contributor

This addresses #26 .

This is almost a 1:1 copy of all classes in the massive ui.py file. Each class was broken out into their own python file. The only modification other than fixing imports was removing the ThemeColors object which was completely unnecessary. I decided to remove it rather than try and pass the colors from the global variable in ui,py to each of the classes no longer in that file.

This merge request shouldn't be reviewed until #25 is merged in since I branched off of that feature branch (I did not want to face new ruff errors later and merge conflicts if I could help it).

@jdunns jdunns linked an issue Jun 5, 2026 that may be closed by this pull request
@nightlark nightlark changed the title 26 - Break up ui.py into seperate class-only python files. Break up ui.py into seperate class-only python files. Jun 9, 2026
Comment thread src/ui.py
_theme_colors = None


class ThemeColors:

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This object was what I deleted instead of working to copy and pass it to each UI class. I found it to be completely unnecessary since the dark theme is set at the initial window creation and the colors can be referenced from the ttkbootstrap Colors object much more elegantly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Break up ui,py.

1 participant