Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@vmcj
Copy link
Collaborator

@vmcj vmcj commented Aug 25, 2025

I think I need some help to check for the lightMode in a proper way. Best would be an autowire but I don't have enough experience with Java on how to do this properly. Is there a piece of code which I can look at to use as example?

On itself all are improvements IMO as the the presentations didn't work in lightmode. I checked with a client also in normal/dark mode and it seems everything stayed the same there.

vmcj added 4 commits August 25, 2025 20:13
The TextHelper would always set it's own color and not the one from the
Graphics.

Better would be if we can autowire the lightmode in there so we can make the
selection from here and optionally even get the current color from the graphics
if that's non standard so we pick the right one always.
The deskcolors were all dark which didn't look nice and the Title was
white on white.

This leaves the drawing of the paths etc. as this would require the lightMode
again but there is no clean way to feed this into it.
@vmcj vmcj marked this pull request as draft August 25, 2025 18:17
@deboer-tim
Copy link
Collaborator

I think I need some help to check for the lightMode in a proper way. Best would be an autowire but I don't have enough experience with Java on how to do this properly. Is there a piece of code which I can look at to use as example?

Not sure I understand? We made light mode a basic property on presentations and (intentionally) didn't initially try to support it in all the presentations. The kind of changes I see here are expected, and I'd suggest just PRing it every couple presentations to keep things moving.

On itself all are improvements IMO as the the presentations didn't work in lightmode. I checked with a client also in normal/dark mode and it seems everything stayed the same there.

Sounds good.

I did notice an unrelated change to using Taskbar in PresentationWindowImpl. I kind of assumed every typical Windows/Mac/Linux system had a taskbar and app icons - are you using one that doesn't have a taskbar? If so, maybe we need that same change everywhere I touched taskbar (but in a separate PR of course, I could do it).

@vmcj
Copy link
Collaborator Author

vmcj commented Aug 25, 2025

I did notice an unrelated change to using Taskbar in PresentationWindowImpl. I kind of assumed every typical Windows/Mac/Linux system had a taskbar and app icons - are you using one that doesn't have a taskbar? If so, maybe we need that same change everywhere I touched taskbar (but in a separate PR of course, I could do it).

I'll check around a bit more what is actually failing, this was the fastest fix. I do get the App icon in my dock when the app is started though which implies that something is being set.

I think I need some help to check for the lightMode in a proper way. Best would be an autowire but I don't have enough experience with Java on how to do this properly. Is there a piece of code which I can look at to use as example?

Not sure I understand? We made light mode a basic property on presentations and (intentionally) didn't initially try to support it in all the presentations. The kind of changes I see here are expected, and I'd suggest just PRing it every couple presentations to keep things moving.

I now need to add a property to TextHelper and set the lightmode explicit instead of it being autowired from when the property is set on startup with --light. This means that in all presentation we would need to change every TextHelper to get the explicit call to setLightMode which felt a bit overly verbose. I'm fine with doing it like this for now if we want to make sure no other presentations are unintentionally changed.

@vmcj
Copy link
Collaborator Author

vmcj commented Aug 27, 2025

I did notice an unrelated change to using Taskbar in PresentationWindowImpl. I kind of assumed every typical Windows/Mac/Linux system had a taskbar and app icons - are you using one that doesn't have a taskbar? If so, maybe we need that same change everywhere I touched taskbar (but in a separate PR of course, I could do it).

image So I also have the problem in KDE which I would expect has a Taskbar.

@deboer-tim
Copy link
Collaborator

I now need to add a property to TextHelper and set the lightmode explicit instead of it being autowired from when the property is set on startup with --light. This means that in all presentation we would need to change every TextHelper to get the explicit call to setLightMode which felt a bit overly verbose. I'm fine with doing it like this for now if we want to make sure no other presentations are unintentionally changed.

Yeah, that's not great, but anything more global would require us to switch all presentations at once. We might be close enough now, but before that would clearly have 'broken' some of the presentations.

TBH I'm not totally sure TextHelper should even understand light/dark, maybe it should just have a foreground and accent colour that each user sets. It's just meant to be a utility class for text / image / emojis and shouldn't really have any state or global options.

So I also have the problem in KDE which I would expect has a Taskbar.

Submitted separate PR #1184 to fix this.

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.

2 participants