Review Request 116673: Display the distance property editor for all the anchor margins

Denis Steckelmacher steckdenis at yahoo.fr
Sun Mar 9 17:54:47 UTC 2014


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/116673/
-----------------------------------------------------------

(Updated March 9, 2014, 5:54 p.m.)


Status
------

This change has been marked as submitted.


Review request for KDevelop.


Repository: kdev-qmljs


Description
-------

This patch adds two features to the property preview widget :

- If a property "some.long.property" is not found in the dictionary of supported properties, then "property" is also tried. This is useful because some users may want to type "some.long { property: foo, property2: bar}".
- margins, topMargin, bottomMargin, leftMargin and rightMargin are added. Due to the first point, they match "anchors.margins" and "anchors { topMargin: 2, bottomMargin: 4 }". Are there other margins that I missed?

I did not touch "font.family" and "font.pointSize" in order to keep the diff small and to show that if properties need their prefix to be explicit (like "shutter.speed" compared to "animation.speed"), then the dots can be kept in the property name.


Diffs
-----

  navigation/propertypreviewwidget.cpp fdfbb1e 

Diff: https://git.reviewboard.kde.org/r/116673/diff/


Testing
-------

I get a nice distance editor for every margin-related property in this snippet:

Item {
    anchors.margins: 3
    anchors.bottomMargin: 6

    Item {
        anchors {
            fill: parent
            leftMargin: 10
        }
    }
}


Thanks,

Denis Steckelmacher

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20140309/95b1bf09/attachment.html>


More information about the KDevelop-devel mailing list