Synchronize the component with the one in Kirigami

Summary: Using the height property together with paintedHeight had binding loops.

Reviewers: #plasma, mart

Reviewed By: #plasma, mart

Subscribers: broulik, plasma-devel, #frameworks

Tags: #plasma, #frameworks

Differential Revision: https://phabricator.kde.org/D8870
This commit is contained in:
Aleix Pol 2017-11-17 16:46:22 +01:00
parent 228e15e20a
commit aa4aa72d63

View File

@ -48,14 +48,19 @@ Label {
id: heading id: heading
/** /**
* level: int
* The level determines how big the section header is display, values * The level determines how big the section header is display, values
* between 1 (big) and 5 (small) are accepted * between 1 (big) and 5 (small) are accepted
*/ */
property int level: 1 property int level: 1
/**
* step: int
* adjust the point size in between a level and another.
*/
property int step: 2 property int step: 2
height: Math.round(paintedHeight * 1.2) lineHeight: 1.2
font.pointSize: headerPointSize(level) font.pointSize: headerPointSize(level)
font.weight: Font.Light font.weight: Font.Light
wrapMode: Text.WordWrap wrapMode: Text.WordWrap