Add PrimitivePropertyType with visual color indicators#4421
Add PrimitivePropertyType with visual color indicators#4421kanishka0411 wants to merge 3 commits intomapeditor:masterfrom
Conversation
|
Hey @kanishka0411 , I was looking through the Linux build failure in your pr. It looks like it might be a header issue, I noticed QAction (and possibly std::make_unique) are being used, but their headers ( Hope this helps! |
bjorn
left a comment
There was a problem hiding this comment.
I think this is a good start, thanks @kanishka0411! There are a number of issues in the details though, so I've left some comments.
It's good that this PR focuses on the basics rather than adding any more involved visualizations. It does leave an interesting challenge for whoever is going to look into enabling that. :-)
@saurabh-zz007 I'm not sure what missing header you're referring to. I only see a build failure for the snap, which appears to have been due to a network error:
Cannot process request (Service Unavailable: 503): https://github.com/mapeditor/qaseprite/releases/download/1.0.3/qaseprite-1.0.3-source.tar.gz
src/tiled/tilesetview.cpp
Outdated
|
|
||
| // Draw property visual indicators | ||
| { | ||
| const auto &propertyTypes = *ProjectManager::instance()->project().propertyTypes(); |
There was a problem hiding this comment.
We can use Object::propertyTypes() to get the currently active property types.
|
Hey @bjorn, thanks for the review! i have made the changes based on your suggestions.
Let me know if there's anything else you'd like me to change :-) |
Fixes #4169
Summary
Implements the initial version of property visualization as discussed . Introduces a new
PrimitivePropertyTypethat can be assigned a visual color, which is then displayed as a colored circle overlay on tiles in the tileset view.What this PR does
PrimitivePropertyTypewith configurable storage type (bool, int, float, string, color) and an optional visual colorHow to test
Interactable), pick a color