Ubuntu Pastebin

Paste from debug at Fri, 17 Jul 2015 13:58:10 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import QtQuick 2.0
import Ubuntu.Components 1.2 
import QtQuick.Layouts 1.1

Item {
    Layout.preferredWidth: units.gu(6)
    Layout.preferredHeight: units.gu(6)
    
    Icon {
        id: avatarImage
        objectName: "avatar"
        anchors.fill: shape
        source: "file:///tmp/img.png"
    }
    ShaderEffectSource {
        id: source
        anchors.centerIn: parent // Placed under shape, so it's hidden
        sourceItem: avatarImage
        width: 1
        height: 1
        hideSource: true
    }
    
    UbuntuShape {
        id: shape
        source: source
        
        anchors.fill: parent
        sourceFillMode: UbuntuShape.PreserveAspectCrop
    }
}
Download as text