Skip to content

Commit

Permalink
Colorize icon with Qt5Compat.GraphicalEffects instead MultiEffect fro…
Browse files Browse the repository at this point in the history
…m Qt6

At the moment, MultiEffect has limitations in its operation.
It does not work with black images. Therefore, the most logical solution would be to use the features from Qt5
  • Loading branch information
s-lisovenko authored and DonLakeFlyer committed Apr 7, 2024
1 parent 33129fc commit ea2a914
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions src/QmlControls/QGCColoredImage.qml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import QtQuick
import QtQuick.Controls
import QtQuick.Effects
import Qt5Compat.GraphicalEffects

import QGroundControl.Palette

Expand Down Expand Up @@ -35,10 +35,9 @@ Item {
sourceSize.height: height
}

MultiEffect {
source: image
anchors.fill: image
colorizationColor: parent.color
colorization: 1.0
ColorOverlay {
anchors.fill: image
source: image
color: parent.color
}
}

0 comments on commit ea2a914

Please sign in to comment.