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

Built-in "Dark" UI theme #396

Closed
ghost opened this issue Oct 2, 2019 · 12 comments
Closed

Built-in "Dark" UI theme #396

ghost opened this issue Oct 2, 2019 · 12 comments

Comments

@ghost
Copy link

ghost commented Oct 2, 2019

Add built-in theme support as option in "Preferences" window:

  • «Light» UI theme (current default)
  • «Dark» UI theme:
    • dark toolbars with monochrome light icons;
    • dark panels background with light fonts;
    • dark workspace background;
  • «Use environment UI theme» - use system theme (optional)

Switching theme should work without restart.

NOTE: Additionally need review workspace background behavior:

  • Actual behavior: 'workspace background' always depend on "Scene Background" settings;
  • Expected behavior: 'workspace background' should be realized additional option that provide ability to ignore "Scene Background" and use 'workspace background' (solid color) provided by UI theme.

(will add more info soon)

REFERENCES

@nathaneltitane
Copy link

no use, just use built in system gtk if on linux or work something out on windows - all modern OSes already support those defacto - no need to put the burden on leocad

@ghost
Copy link
Author

ghost commented Jan 2, 2020

Problem here is that there are no simple way to enable use of system theme in LeoCAD settings

For example, in Manuskript app there is option in settings that allow use system gtk theme.

pic.1

@nathaneltitane
Copy link

You mean to say that your leocad session does not use the system gtk theme? Dark or not?

I'm curious to know why it'd do that if that were the case.

@ghost
Copy link
Author

ghost commented Jan 3, 2020

You mean to say that your leocad session does not use the system gtk theme? Dark or not?

Yes.

@nathaneltitane
Copy link

@Symbian9 are you runing Gnome DE?
I've just switched to kde and integration is flwless (because of Qt of course)

I suggest you enable the environment export workarounds for qt4 and qt5 to help with themeing:

for qt5:

install qt5-style-plugins
sudo echo "QT_QPA_PLATFORMTHEME=gtk2" > /etc/environment

you can optionally configure and tweak things with qt5ct

for qt4:

run this:

#!/bin/bash

home="/home/${SUDO_USER:-$USER}"
configuration_directory="$home/.config"
gtk_configuration_directory="$configuration_directory/gtk-3.0"

if [ ! -e "$configuration_directory" ]
then
mkdir "$configuration_directory"
fi

configuration

echo "${cyan}Adding styles configuration parameters (Qt)...${reset}"

cat > "$configuration_directory"/Trolltech.conf << 'FILE'
[Qt]

style=GTK+
FILE

Link configuration file for GTK 3+ setup

ln -s -f "$configuration_directory"/Trolltech.conf "$gtk_configuration_directory"/Trolltech.conf

@ghost
Copy link
Author

ghost commented Jan 11, 2020

are you runing Gnome DE?
I've just switched to kde and integration is flwless (because of Qt of course)

That is why I requested built-in dark theme for avoid any DE/WM issues.

@nathaneltitane
Copy link

are you runing Gnome DE?
I've just switched to kde and integration is flwless (because of Qt of course)

That is why I requested built-in dark theme for avoid any DE/WM issues.

This should be handled upstream normally.

@ghost
Copy link
Author

ghost commented Jul 11, 2020

This should be handled upstream normally.

@nathaneltitane, Are you use AppImage-build of LeoCAD or compile & install it itself as regular package?

@nathaneltitane
Copy link

This should be handled upstream normally.

@nathaneltitane, Are you use AppImage-build of LeoCAD or compile & install it itself as regular package?

I used to use the prebuilt version.

I've been compiling l'encadrement for over two years now...

What does it have to do with style settings?

@ghost
Copy link
Author

ghost commented Jul 12, 2020

What does it have to do with style settings?

There is issue where AppImage package would not detect system themes if not directly configure it:

As for me, I use LeoCAD's AppImage continuous builds under Debian with Xfce4, and LeoCAD ignore my system theme.

BUT, when I tried to install it as regular package (using DEB builds) it successfully recognize system themes.

BTW, I prefer that each app should has option for setting own themes independently from my system theme, as Olive and many other Qt-based apps implemented it by adding option for user specifying custom QSS-file stylesheets via app preferences:

@nathaneltitane
Copy link

There is issue where AppImage package would not detect system themes if not directly configure it:

Even with appimage or debs, I have come upon instances where LeoCad, LDView and other qt based apps would not resolve systemk theming properly - it has to do with qt and not how Leo or other devs create their applications and the solution is a system workaround that I wrote on my third reply dating from jan 11th. I have unfortunately not com eacross any further details on why these are broken, and i'm sure it may also be distribution specific.

@leozide
Copy link
Owner

leozide commented Jul 12, 2020

My guess is this has something to do with the way the AppImage is created as it includes the Qt libraries from the build machine and that has some differences from what you have.

I have a dark theme I've been trying, it still needs some more work and I'll add it when it's ready (with an option to disable it).

@leozide leozide closed this as completed Dec 30, 2020
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