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

Refactored SVG widget and button and improved drag container #23

Merged
merged 7 commits into from
Nov 26, 2022

Conversation

gentlegiantJGC
Copy link
Member

@gentlegiantJGC gentlegiantJGC commented Nov 23, 2022

Refactored the SVG widget and button to allow styling via style sheets rather than code.
This will allow more flexibility to custom styles.
Depreciated QSvgIcon and both QIconButton classes.

Refactored and improved QDragContainer.
ADragContainer now uses the styleable svg button to make styling easier.
Improved drag behaviour. The widgets rearrange as you a dragging making the outcome more obvious.

This adds a custom SVG widget that can be styled via the widget background.
This allows changing the style via style sheets rather than code making style sheets more useful.
It also adds a button containing a stylable SVG widget and the same with a tool tip.
The latter should be refactored to work with any class and remove the need for a subclass.
replaced some references to the old icon button.
There are still some uses of the old icon button still to replace.
ALinkCard replaces QLinkCard.
They are functionally the same but the new class uses the stylable svg widget.
The new class can contain any widget.
This removes the need for custom classes for the widgets inside the draggable container.
The new class also supports live rearranging to make it clearer where the dragged widget will end up.
@gentlegiantJGC gentlegiantJGC changed the title Refactor svg Refactored SVG widget and button and improved drag container Nov 23, 2022
@gentlegiantJGC gentlegiantJGC marked this pull request as ready for review November 23, 2022 11:21
@gentlegiantJGC gentlegiantJGC merged commit a8f67ad into main Nov 26, 2022
@gentlegiantJGC gentlegiantJGC deleted the refactor-svg branch November 26, 2022 09:23
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.

1 participant