-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make style model decoration icons size responsive
We hack the model a bit here, but as much as possible avoid bleeding view properties into the model API. So we use a QObject property ("icon_size") to specify icons sizes for the model to generate. This is set on instances of the model to indicate the required sizes for decorations in all views connected to the model, and allows the model to have size responsive icons. By using a QObject property we avoid having public GUI/view related API within the model, and mostly avoid view related properties contaminating the pure model, yet still have pixel-perfect symbol renders for the required view icon sizes.
- Loading branch information
1 parent
28836d2
commit d7edeac
Showing
2 changed files
with
70 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters