mirror of
https://github.com/arcan1s/awesome-widgets.git
synced 2025-07-23 10:39:56 +00:00
backport QML code changes from awesome-widgets to deskop-panel
This commit is contained in:
@ -84,7 +84,7 @@ Item {
|
||||
// ui
|
||||
Text {
|
||||
id: text
|
||||
anchors.fill: Layout
|
||||
anchors.fill: Plasmoid.Layout
|
||||
renderType: Text.NativeRendering
|
||||
textFormat: Text.RichText
|
||||
wrapMode: plasmoid.configuration.wrapText ? Text.WordWrap : Text.NoWrap
|
||||
|
@ -71,7 +71,9 @@ Item {
|
||||
title: i18n("Select a color")
|
||||
onAccepted: {
|
||||
var text = textPattern.text
|
||||
textPattern.text = "<body bgcolor=\"" + backgroundDialog.color + "\">" + text + "</body>"
|
||||
textPattern.text = "<body bgcolor=\"" +
|
||||
backgroundDialog.color + "\">" +
|
||||
text + "</body>"
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -292,10 +294,9 @@ Item {
|
||||
onClicked: {
|
||||
if (!tags.currentText) return
|
||||
if (debug) console.debug("Add tag button")
|
||||
var pos = textPattern.cursorPosition
|
||||
var selected = textPattern.selectedText
|
||||
textPattern.remove(textPattern.selectionStart, textPattern.selectionEnd)
|
||||
textPattern.insert(pos, selected + "$" + tags.currentText)
|
||||
textPattern.insert(textPattern.cursorPosition, selected + "$" + tags.currentText)
|
||||
}
|
||||
}
|
||||
QtControls.Button {
|
||||
|
Reference in New Issue
Block a user