mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-08-15 18:43:59 +00:00
Revert "Possibly fixed #117, format and also change a tiny thing in ActiveWindow"
This reverts commit 1e52e7ca40.
This commit is contained in:
@@ -41,15 +41,14 @@ Row {
|
||||
NText {
|
||||
id: fullTitleMetrics
|
||||
visible: false
|
||||
text: getTitle()
|
||||
font.pointSize: Style.fontSizeS * scaling
|
||||
font.weight: Style.fontWeightMedium
|
||||
text: titleText.text
|
||||
font: titleText.font
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
// Let the Rectangle size itself based on its content (the Row)
|
||||
visible: root.visible
|
||||
width: row.width + Style.marginS * scaling
|
||||
width: row.width + Style.marginM * scaling * 2
|
||||
height: Math.round(Style.capsuleHeight * scaling)
|
||||
radius: Math.round(Style.radiusM * scaling)
|
||||
color: Color.mSurfaceVariant
|
||||
@@ -61,7 +60,6 @@ Row {
|
||||
anchors.fill: parent
|
||||
anchors.leftMargin: Style.marginS * scaling
|
||||
anchors.rightMargin: Style.marginS * scaling
|
||||
clip: true
|
||||
|
||||
Row {
|
||||
id: row
|
||||
@@ -88,10 +86,9 @@ Row {
|
||||
NText {
|
||||
id: titleText
|
||||
|
||||
// For short titles, show full. For long titles, truncate and expand on hover
|
||||
width: mouseArea.containsMouse ? Math.min(fullTitleMetrics.contentWidth + 8,
|
||||
400 * scaling) : Math.min(fullTitleMetrics.contentWidth + 12,
|
||||
200 * scaling)
|
||||
// Collapsed width when not hovered, expand on hover
|
||||
width: mouseArea.containsMouse ? Math.min(fullTitleMetrics.contentWidth + (Style.marginS * scaling),
|
||||
400 * scaling) : (minWidth * scaling)
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
text: getTitle()
|
||||
font.pointSize: Style.fontSizeS * scaling
|
||||
|
||||
Reference in New Issue
Block a user