Problem with Pathview Alignment
-
I have been trying to get a simple 5 img pathview slider working for the past little
while now but ca'nt seem to get the thing centered properly. Also my images seem to have
the tops cut off and the pathview does not center in the window correcly. can someone
give me some pointers.GameWindow {
property int imgHeight:150
property int imgWidth:165Backgrounds {} Scene { id: scene width: 960 height: 640 PathView { id: view width: imgWidth*pathItemCount height: imgHeight y:25 anchors.horizontalCenter: parent.horizontalCenter cacheItemCount: 2 pathItemCount: 5 snapMode: "SnapToItem" focus: true clip: true preferredHighlightBegin: .5 preferredHighlightEnd: .5 highlightRangeMode: PathView.StrictlyEnforceRange model: sliderModel delegate: Image { id: name source: front width: imgWidth height: imgHeight Text { text: albumid color:'white' } } path: Path { startX: view.x startY: view.y PathLine { x: view.x + (imgWidth * view.pathItemCount); y: view.y } } } }
}