-
-
Notifications
You must be signed in to change notification settings - Fork 545
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
Add theme and plot thickness options #847
base: master
Are you sure you want to change the base?
Conversation
Maybe some of the colors of the graph can be tweaked a bit? The dark blue is very hard to see on dark theme (graph is somewhat OK, but the labels are almost unreadable). |
Thanks! One small thing, if you switch theme, the graph titlebar doesn't get updated to new color until you focus it. But I think the title bar needs to keep OS color, this is how other apps do it too. |
I made a video of the behavior on my end: https://imgur.com/R8r6ycM
I wasn't sure whether you meant switch OS theme, or switch LHM theme. In the video, I showed that changing both immediately updates the LHM main window and plot window themes without any additional interaction needed.
I don't think there is a proper or improper way to do this, in video I show Microsoft Edge top bar changing color with theme. Plenty of apps use their own color for the title bar, and I think this is the preferred behavior here. |
If you switch OS theme (app preferences), the titlebar color of the plot window isn't updated until you refocus it. I tried it on two systems and both have the same problem 🤔
Edge doesn't change here (Windows 10), it stays on Windows' color. |
@PhyxionNL I unfortunately don't have a Windows 10 system to test this behavior. All I do is look in the registry for |
You can detect the WININICHANGE (0x001A) message and then retrieve registry theme information. |
It's not that the detection to change theme is broken, it does that correctly. But it doesn't update the titlebar color of dialogs unless you focus them. |
Awesome, thank you! |
Thanks for this! |
@MRog40 Can you address the remaining issues mentioned here so it can be merged? Thanks! |
I've been using this PR version for a long time now because I can't live without dark mode 😄 Much appreciated @MRog40 |
I've fixed a couple of the bugs with opening/closing and losing theme settings, still working out the title bar color |
How can this be enabled? Theming options don't appear in my menu... |
Give the issue a thumbs up then wait and let developers develop it until one day in the releases section you see a new version and "Dark mode added" is one of the items in the change log, then shower them in praise and donations. Actually you could start praise and donations now, I guess, nobody would mind ;) |
You have to compile it yourself from MRog40:darkmode with Visual Studio 😉 |
Sorry for the delay everyone - day job taking priority for the moment. I actually was previously requested to compile a release with dark mode, you can find that release here: https://github.com/MRog40/LibreHardwareMonitorDark/releases I'm going to work on getting this PR in hopefully next sprint |
@MRog40 It's fine, I am excited for it to be merged! Hopefully your job isn't too stressful or anything. Thanks for your work so far! 😄 |
I hope you will be able to find out ! |
adding something like ApplyTheme();
_plot.ShowTracker(new TrackerHitResult());
_plot.HideTracker();
foreach (Control plotControl in _plot.Controls)
{
plotControl.BackColor = Theme.Current.PlotBackgroundColor;
} to PlotPanel constructor makes it working |
Thank you @kamkie for the fix. Two remaining issues I'll try and wrap up:
|
I believe all the issues are now fixed. Latest was uploaded to https://github.com/MRog40/LibreHardwareMonitorDark/releases to test |
@PhyxionNL I believe all the issues have been addressed |
Just tried it out, but plot window is still white for me (manually set theme to Dark). Also Parameters dialog is white. |
Works for me here. With every plot location, but I used my former config file. Maybe there is a difference. |
Try this artifact: https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/suites/18575006450/artifacts/1080435156 |
This is great, thanks a lot!! Will let you know if I find any issues |
I've tested the provided artifact and still the theme always works for me, I've tried all combinations of separate plot window, integrated plot, and all theme options including auto and it always works. Having different Windows / App themes doesn't matter, as I only look at the "AppsUseLightTheme" registry key and never the windows settings. |
Here is a little video demo using your artifact showing it only responds to App theme changes, and it responds even faster than windows explorer does: Phyxion_Artifact_Theme.mp4 |
Merged master and uploaded another updated release here for those that are using this version: https://github.com/MRog40/LibreHardwareMonitorDark/releases |
I was using OpenHardwareMonitor at night on my otherwise all black OLED system, so a quick google search pointed me towards "Hey, try Libre Hardware Monitor it is still maintained". I came across an all but abandoned PR for themes and decided to revive the code and add some other additions for customization
Themes
Plot Stroke Thickness
Auto dark theme (set by windows theme setting), 2pt Stroke Thickness
Black theme, 2pt Stroke Thickness
Light theme, 4pt Stroke Thickness