Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open ponk issue settings with DARK/LIGHT theme #14

Open
TNemecek opened this issue Oct 18, 2024 · 1 comment
Open

Open ponk issue settings with DARK/LIGHT theme #14

TNemecek opened this issue Oct 18, 2024 · 1 comment

Comments

@TNemecek
Copy link

Not sure if this is valid behavior, but i can't switch light/dark mode. It appears to set null when change theme. Theme then looks like set to dark, but nothing happens. Same behavior is with switching back to Light.

nightly build - win
Pharo 12.0.0
Build information: Pharo-12.0.0+SNAPSHOT.build.1539.sha.**688a (64 Bit)
image

@JanBliznicenko
Copy link
Member

JanBliznicenko commented Oct 20, 2024

Hello, thank you for finding the issue.
While this error should be fixed (on GUI library's side - I have forwarded the problem to its issue tracker pharo-spec/Spec#1632), OpenPonk, unfortunately, does not fully support themes anyway. General GUI items would be switched to the dark theme, but not the main drawing area, there are no dark theme compatible icons and it is overall untested.

You may still try. In order to do that, you need to switch the layout before opening any OpenPonk project for the first time. As long as any OpenPonk window is already opened or still in memory (not yet garbage-collected), the theme would not change properly and cause this error.
If you would like a little experiment, you may also run the garbage collection yourself. Close all OpenPonk project windows (those inner windows inside the application), then in the top menu: Browse - Playground. Write or copy paste there the following code:

OPProjectStorage reset. 
SpNullApplication reset. 
Smalltalk garbageCollect.

Then click on the green arrow "Do it" and try to change the theme again.
Those OPProjectStorage and SpNullApplication parts should not be needed, but I just fixed a few memory leaks caused by these 2 classes holding references to closed OP windows and the fix is only available in current nightly build so far :)

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

No branches or pull requests

2 participants