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

[ColorWidget] Add CMYK support #57361

Merged
merged 12 commits into from May 23, 2024
Merged

[ColorWidget] Add CMYK support #57361

merged 12 commits into from May 23, 2024

Conversation

troopa81
Copy link
Contributor

@troopa81 troopa81 commented May 7, 2024

This is the first PR regarding CMYK QEP

It adds CMYK support in color widget so we can select CMYK color.

A new setting activeCmykComponent has been introduced, while the old one activeComponent refers now only to the Rgb/Hsv part

colorwidget

Funded by Métropôle de Bordeaux

@troopa81 troopa81 added Feature GUI/UX Related to QGIS application GUI or User Experience labels May 7, 2024
@github-actions github-actions bot added this to the 3.38.0 milestone May 7, 2024
Copy link

github-actions bot commented May 7, 2024

🪟 Windows builds ready!

Windows builds of this PR are available for testing here. Debug symbols for this build are available here.

(Built from commit 1ad2b4b)

@nyalldawson
Copy link
Collaborator

@troopa81 There's a fair amount of wasted space in the dialog caused by putting the combo box in the top left corner. Could we try moving it here instead?

image

How does this look in the vertical orientation mode used in the styling dock color buttons too? Can you share a screenshot showing that?

@nyalldawson
Copy link
Collaborator

Question: is the use of rounded integer 0-255 values an issue when using CMYK colors? It's been on my wishlist for a while to revisit these widgets and make them return qreal values for the color components, so that we aren't losing information when a color is changed via the widget and are better equipped to handle higher precision color models in future (since these are already supported by both Qt and our color reading/writing code, it's really only the color widget itself holding us back).

@troopa81
Copy link
Contributor Author

Question: is the use of rounded integer 0-255 values an issue when using CMYK colors?

As much as RGB color I think. Do you have a specific issue in mind ? or just the lack of precision when you use the color wheel widget for instance

@troopa81
Copy link
Contributor Author

@troopa81 There's a fair amount of wasted space in the dialog caused by putting the combo box in the top left corner. Could we try moving it here instead?

Way better indeed. Done and updated video accordingly

@spacehobo
Copy link

spacehobo commented May 16, 2024

Question: is the use of rounded integer 0-255 values an issue when using CMYK colors?

As much as RGB color I think. Do you have a specific issue in mind ?

One reason to use CMYK is so that you can hit very specific spot colours used by your printers. This allows prints to get very high DPI at the tones you specify, because they don't need to use screens to dither various colours together.

If I can't specify the exact percentages from my printer's catalogue of spot colours, and have them propagate all the way through to a CMYK-colourspace PDF put out by the Layout Manager, then the result will be a very expensive print of a map with degraded quality.

@troopa81
Copy link
Contributor Author

@nyalldawson I remoed the warning message

@spacehobo Good point, I'll try to deal with this in another PR if I have the time/budget.

@nyalldawson nyalldawson added the Freeze Exempt Feature Freeze exemption granted label May 17, 2024
src/gui/qgscolorwidgets.h Outdated Show resolved Hide resolved
src/gui/qgscolorwidgets.cpp Show resolved Hide resolved
src/ui/qgscompoundcolorwidget.ui Outdated Show resolved Hide resolved
src/ui/qgscompoundcolorwidget.ui Outdated Show resolved Hide resolved
src/gui/qgscompoundcolorwidget.cpp Show resolved Hide resolved
tests/src/python/test_qgscolorwidget.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@nyalldawson nyalldawson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one little change left

tests/src/gui/testqgscompoundcolorwidget.cpp Show resolved Hide resolved
@troopa81 troopa81 merged commit eaa0261 into qgis:master May 23, 2024
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Freeze Exempt Feature Freeze exemption granted GUI/UX Related to QGIS application GUI or User Experience
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants