|
|
Home » Developing U++ » U++ Developers corner » DarkTheme support
|
|
|
Re: Please check the list of 2019.1 changes [message #51373 is a reply to message #51347] |
Sun, 17 March 2019 02:05 |
|
Klugier
Messages: 1082 Registered: September 2012 Location: Poland, Kraków
|
Senior Contributor |
|
|
Hello Tom and Mirek,
I tested dark them on my Linux machine with dark GTK theme and came into conclusion. The icons for TheIDE doesn't look grate, but the main reason for that is that we convert icons that do not really needs to be converted. It looks grate on both dark and white theme. I believe we should gain good results when we allow the programmer to decide how icons should behave in white/dark environment. In my opinion IconDes should offer following options:
- auto (use conversion algorithm for icon)
- separate icon for white/light themes
- separate icon for dark themes
- none (do not make conversion and use the same icon in both environments dark and light)
Let's look at the this picture. Some of Ide icons look great in IconDes, but the same icons with color inversion doesn't look great in toolbar:
Sincerely,
Klugier
U++ - one framework to rule them all.
[Updated on: Sun, 17 March 2019 12:07] Report message to a moderator
|
|
|
|
Re: Please check the list of 2019.1 changes [message #51382 is a reply to message #51379] |
Sun, 17 March 2019 11:54 |
|
Klugier
Messages: 1082 Registered: September 2012 Location: Poland, Kraków
|
Senior Contributor |
|
|
Hello,
It is converted somehow even it is not do intentionally. Look at debug/run icons inside TheIDE. Inside IconDes it's fulfillment are white, but inside TheIDE is is inverted to the dark colors. Here is example:
Sincerely,
Klugier
U++ - one framework to rule them all.
[Updated on: Sun, 17 March 2019 11:55] Report message to a moderator
|
|
|
|
Re: Please check the list of 2019.1 changes [message #51420 is a reply to message #51416] |
Sun, 24 March 2019 09:53 |
|
mirek
Messages: 14038 Registered: November 2005
|
Ultimate Member |
|
|
There are constants that can used to finetune the conversion, in Core/Color.cpp:233
// this represent physiological perception of brightness of R,G,B. Sum = 1
// static double c[3] = { 0.21, 0.72, 0.07 }; // physiologically correct values
static double c[3] = { 0.3, 0.5, 0.2 }; // with this set, blues and reds are more pronounced
As you can see, I have tried to alter the set and IMO it now looks even better (previously, blues tended to end as too close to white).
I am posting this here so that it can be eventually experimented on...
Mirek
|
|
|
|
Re: Please check the list of 2019.1 changes [message #51431 is a reply to message #51424] |
Mon, 25 March 2019 11:45 |
Tom1
Messages: 1242 Registered: March 2007
|
Senior Contributor |
|
|
Hi Mirek,
Good news! I'm testing dark theme now...
Surprisingly, a linking issue arised with dual tif libraries when compiling my app. (I have one in gdal and another in plugin/tif. Both needed. Actually I would only need one, but can't figure out how to make gdal use Upp plugin/tif instead of the bundled tiff library.) The picture shows this issue as well as a little bit strange color combination for the message, which is more relevant for the Dark -theme at hand:
After working awhile with TheIDE and recompliling, the colors of the linking error lines turned to white on pure red. Then when I closed TheIDE and started over with Light theme, I discovered that the linking error was printed with black on relatively dark red. That's hard to read, at least for me.
I need to figure out this linking issue before I can seriously test with my own code. Anyway, I can see that the frame in TheIDE already looks much better on Windows 10 than it did before.
Best regards,
Tom
-
Attachment: Dark.png
(Size: 76.26KB, Downloaded 503 times)
|
|
|
Re: Please check the list of 2019.1 changes [message #51432 is a reply to message #51431] |
Mon, 25 March 2019 11:51 |
Tom1
Messages: 1242 Registered: March 2007
|
Senior Contributor |
|
|
OK, now I know: The linking error background color is sluggishly following the Setup>Settings>Syntax highlighting color > White/Dark setting. Therefore it is not in sync with the Windows Dark -theme that is read on startup.
But: Shouldn't the Syntax highlighting (White/Dart) automatically follow the Dark/light theme read from the system on startup as everything else is now?
Best regards,
Tom
[Updated on: Mon, 25 March 2019 11:51] Report message to a moderator
|
|
|
|
|
Re: Please check the list of 2019.1 changes [message #51475 is a reply to message #51437] |
Fri, 29 March 2019 09:30 |
Tom1
Messages: 1242 Registered: March 2007
|
Senior Contributor |
|
|
Hi Mirek,
It turned out that there are many readability issues when using dark theme colors on Windows 7.
- Toolbar
- Menubar
- ArrayCtrl headers
- e.g. Settings dialog in TheIDE
On Windows 10 you solved the same already.
Best regards,
Tom
|
|
|
Re: Please check the list of 2019.1 changes [message #51476 is a reply to message #51475] |
Fri, 29 March 2019 10:54 |
|
mirek
Messages: 14038 Registered: November 2005
|
Ultimate Member |
|
|
Well, dark theme with Win 7 is completely different path (as there the colors are comming from the system).
Anyway, I have just finished another iteration of dark theme issues, so please recheck everything and report.
First of all, immediately after delivering one release on my app with dark theme support, I had reported it as error
So now you have to activate simulated Win10 dark theme by Ctrl::SetDarkThemeEnabled at the start of GUI_APP_MAIN.
Another new features:
bool IsDarkTheme();
Color AdjustIfDark(Color); // adjusts color for dark them if it is active
Also, previously deprecated functions SWhite, SRed().... are now reactivated and represent "dark theme adjusted colors". So if you want to put Red color somewhere, if you use SRed, it will be accordingly converted in dark mode (somewhat pink-ish).
I will try to write some docs about dark theme support soon... (probably as well as about UHD).
|
|
|
Re: Please check the list of 2019.1 changes [message #51478 is a reply to message #51476] |
Fri, 29 March 2019 16:31 |
Tom1
Messages: 1242 Registered: March 2007
|
Senior Contributor |
|
|
Hi Mirek,
On Windows 10 it all still works (after adding Ctrl::SetDarkThemeEnabled(); ).
On Windows 7 the symptoms I mentioned in my last message remain.
Another thing I noticed is that Windows 10 1809 does not alter any icon color at all (or maybe just pure black/white) when switching between light and dark themes. (Please take a look at Windows "File Explorer" toolbar icons while toggling between Light and Dark app modes on Windows > Settings > Personalization > Colors.) For this to work properly, all icons must be colored in a way that prevents them from sinking into the background. Sorry to bring this up this late down the road, but after using TheIDE with dark theme for a while, I have now noticed that I have some difficulty to identify certain TheIDE icons (e.g. Build and Rebuild All on the toolbar) in their dark variant. This may be related to the fact that I have red-green colorblindness (as about 8 % of males do). Using light theme icons on dark background would in most cases work better for me after all. Of course there are some icons that would need to be changed in order to be visible on both dark and light backgrounds. This involves changing from black to mid-grey to support both white and black backgrounds with a single icon.
I tried this by commenting out the following code in function Iml::Get(int i) in Iml.cpp:
// if(gui_image && IsDark(SColorPaper()))
// m.image = DarkTheme(m.image);
The result is easier for me to work with. Some icons (the dark ones including, but not limited to compile (C++) and preprocess (#) ) would need a new lighter color tone that is closer to mid range intensity.
Best regards,
Tom
|
|
|
|
Re: Please check the list of 2019.1 changes [message #51483 is a reply to message #51482] |
Sat, 30 March 2019 12:50 |
Tom1
Messages: 1242 Registered: March 2007
|
Senior Contributor |
|
|
mirek wrote on Sat, 30 March 2019 11:22Tom1 wrote on Fri, 29 March 2019 16:31Hi Mirek,
On Windows 10 it all still works (after adding Ctrl::SetDarkThemeEnabled(); ).
On Windows 7 the symptoms I mentioned in my last message remain.
Well, M$ dropped the support for Win7 and we have not made it worse by recent changes, so... it will perhaps have to wait before I have some Win7 machine again.
Quote:
Another thing I noticed is that Windows 10 1809 does not alter any icon color at all (or maybe just pure black/white) when switching between light and dark themes. (Please take a look at Windows "File Explorer" toolbar icons while toggling between Light and Dark app modes on Windows > Settings > Personalization > Colors.) For this to work properly, all icons must be colored in a way that prevents them from sinking into the background. Sorry to bring this up this late down the road, but after using TheIDE with dark theme for a while, I have now noticed that I have some difficulty to identify certain TheIDE icons (e.g. Build and Rebuild All on the toolbar) in their dark variant. This may be related to the fact that I have red-green colorblindness (as about 8 % of males do). Using light theme icons on dark background would in most cases work better for me after all. Of course there are some icons that would need to be changed in order to be visible on both dark and light backgrounds. This involves changing from black to mid-grey to support both white and black backgrounds with a single icon.
Oh great...
Mirek
Dark theme support on Windows 7 is not critical for me, but as I found it out during testing, I wanted to let you know. Leaving it as it is, is OK with me.
As for the question with icon coloring/theming, I understand your frustration about it and I'm truly sorry I have not been able to realize this before. I'm trying to be helpful, but I understand this is not always the case.
Then again, I do not know where Microsoft is going with this subject either. Anyway, the dark theme support has evolved gradually during recent Windows 10 upgrades and there is no evidence that it would stop here. Next update is just around the corner and news on the preview versions point out some slight changes again.
But in the end, you decide how U++ deals with this.
Best regards,
Tom
|
|
|
Goto Forum:
Current Time: Fri Sep 20 04:27:09 CEST 2024
Total time taken to generate the page: 0.03066 seconds
|
|
|