-
Notifications
You must be signed in to change notification settings - Fork 68
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
feat: added an amount of good to destinguish colors #2143 #2265
Conversation
Signed-off-by: AryanBakliwal <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -44,11 +44,45 @@ | |||
WMS = 0 | |||
|
|||
|
|||
class CustomColorDialog(QtWidgets.QColorDialog): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
that is now doubling the code lines,
there should be only one definition, you can move it to
mpl_qtwidget and import it then.
usually the tests done in 5mins now it gets into a timeout at 10mins. That is a bit strange. |
This is not changed in the PR it is shown to solve the test issue. sigkill on the test where it gets stuck shows:
|
Colors | ||
------ | ||
|
||
We utilize custom colors for distinguishing routes using the color palette provided by SashaMaps. | ||
Link: https://sashamaps.net/docs/resources/20-colors/ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was inserted in the middle of the "Identity Provider" section, i.e. above and below is stuff about pysaml2. It should not split that section.
def getColor(self, button): | ||
return QtGui.QPalette(button.palette()).color(QtGui.QPalette.Button) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to do something different than the default getColor method of QColorDialog that is being overridden. Is it possible to drop this and use the class as CustomColorDialog.getColor(colour)
, i.e. how the QColorDialog class was previously used as well?
The CI timeout is happening because some tests mock the QColorDialog.getColor
method, which now no longer works as intended and instead leaves the widget open, which blocks the tests from finishing.
the issue was solved differently during GSOC-2024 |
Purpose of PR?: To add good to distinguish colors
Fixes #2143
The predefined color swatches in QColorDialog are typically determined by the system's color scheme or the default color palette. Unfortunately, PyQt5's QColorDialog does not provide a direct method to modify these predefined color swatches.
I created a custom dialog that mimics the behavior of the QColorDialog to customize the color swatches.
Previous dialog
![image](https://private-user-images.githubusercontent.com/106430579/309566771-0ab41329-110b-4f6f-b6a6-2104a52d720a.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjM5MDkyMDksIm5iZiI6MTcyMzkwODkwOSwicGF0aCI6Ii8xMDY0MzA1NzkvMzA5NTY2NzcxLTBhYjQxMzI5LTExMGItNGY2Zi1iNmE2LTIxMDRhNTJkNzIwYS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwODE3JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDgxN1QxNTM1MDlaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wMTI0ZDhjZTEwNjFjYzlmZWM4N2QwNDMyNjdjMzY1OGFiYjhiYmI3NmNiNmVjZmZjNjE4OGI1ZDliNGQwYTZlJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.agZjDIANpNPFinEtQCmV_pHTtLUp4O9Spn2fAXQ4cGg)
New dialog
![image](https://private-user-images.githubusercontent.com/106430579/309576466-79c26039-31d6-4a1d-968a-354f7dda970d.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjM5MDkyMDksIm5iZiI6MTcyMzkwODkwOSwicGF0aCI6Ii8xMDY0MzA1Nz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