Debian Codegraph @

modules/Lomiri/Components/Extras/qml6/TabsBar/TabContourHalf.qml

raw
1 /*
2 * Copyright (C) 2016 Canonical Ltd.
3 *
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 3 as
6 * published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * Authored-by: Florian Boucault <[email protected]>
17 */
18 import QtQuick 2.4
19 import Lomiri.Components
20
21 ShaderEffect {
22 id: tabContour
23
24 property Image source: Image {
25 width: tabContour.width
26 height: tabContour.height
27 source: "[email protected]"
28 scale: units.gridUnit / 24
29 fillMode: Image.Pad
30 horizontalAlignment: Image.AlignLeft
31 verticalAlignment: Image.AlignTop
32 visible: false
33 cache: true
34 asynchronous: true
35 }
36
37 property color backgroundColor
38 property color contourColor
39 property color outsideColor
40 property real sourceWidth: source.paintedWidth / tabContour.width
41 property real sourceHeight: source.paintedHeight / tabContour.height
42
43 fragmentShader: "qrc:/shaders/tabsbar/tab-contour.frag.qsb"
44 }