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

[ENH] Color styled widget icons #271

Merged
merged 15 commits into from
Jun 7, 2023

Conversation

ales-erjavec
Copy link
Collaborator

@ales-erjavec ales-erjavec commented May 11, 2023

Issue

Fixes: gh-270

Changes

Color widget icons based on current palette where appropriate.

By default when running in dark mode the colors are inverted to fit the background to foreground grayscale range.

Screenshot_20230511_143619

Screenshot_20230511_143839

Note that 'Color' is quite badly drawn.

But also add support for explicitly using palette styled widget icons like in biolab/orange3#6444

Screenshot_20230511_152623

Screenshot_20230511_152231

@PrimozGodec
Copy link
Contributor

After checkout, these branch icons are oversized (see screenshot below). My setup is a laptop with a retina screen and an external "normal" screen plugged in. Everything is fine when I open Orange on the retina or only use an external screen. The problem happens when both screens are on, and I open orange on the external screen.

Screenshot 2023-05-26 at 08 36 27

@ales-erjavec
Copy link
Collaborator Author

After checkout, these branch icons are oversized (see screenshot below). My setup is a laptop with a retina screen and an external "normal" screen plugged in.

Is this happening using Qt6?

@PrimozGodec
Copy link
Contributor

PrimozGodec commented Jun 2, 2023

Is this happening using Qt6?

Yes, I have PyQt6. I can also try it later on PyQt5.
Edit: I tested it with PyQt5, and the same error is also present.

@codecov-commenter
Copy link

codecov-commenter commented Jun 2, 2023

Codecov Report

Patch coverage: 91.92% and project coverage change: +0.24 🎉

Comparison is base (ee765db) 75.06% compared to head (43b52f2) 75.30%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #271      +/-   ##
==========================================
+ Coverage   75.06%   75.30%   +0.24%     
==========================================
  Files          97       99       +2     
  Lines       20766    20953     +187     
==========================================
+ Hits        15588    15779     +191     
+ Misses       5178     5174       -4     
Impacted Files Coverage Δ
orangecanvas/registry/discovery.py 38.28% <0.00%> (ø)
orangecanvas/registry/utils.py 93.65% <ø> (ø)
orangecanvas/document/quickmenu.py 68.76% <36.36%> (+0.02%) ⬆️
orangecanvas/resources.py 75.69% <77.77%> (-0.69%) ⬇️
orangecanvas/utils/image.py 92.45% <92.45%> (ø)
orangecanvas/gui/iconengine.py 96.11% <96.11%> (ø)
orangecanvas/gui/svgiconengine.py 90.85% <96.42%> (+6.47%) ⬆️
orangecanvas/application/application.py 61.72% <100.00%> (+0.47%) ⬆️
orangecanvas/application/canvastooldock.py 70.55% <100.00%> (+0.68%) ⬆️
orangecanvas/application/widgettoolbox.py 61.29% <100.00%> (-0.16%) ⬇️
... and 4 more

... and 3 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@ales-erjavec
Copy link
Collaborator Author

Can you check again with the latest version.

@PrimozGodec
Copy link
Contributor

Can you check again with the latest version.

It looks good now.

@PrimozGodec PrimozGodec merged commit 1c90038 into biolab:master Jun 7, 2023
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.

Dark mode - Widgets icons not shown properly in the Edit Links menu
3 participants