Qt 6.11 is out! See what's new in the release
blog
Accessing Image inside a Tab
QML and Qt Quick
2
Posts
1
Posters
1.2k
Views
1
Watching
-
I have a TabView in which Tab elements are added dynamically with a child Scrollview and Image, to make the image scrollable.
I use the addTab(title, component) method of TabView to add this Component:
@
Component {
id: itemTabScrollView { anchors.fill: parent Image { fillMode: Image.PreserveAspectFit width: tabView.width height: tabView.height } }}
@
Now, as my image source has to be dynamic, how can I access the Image element to set its source from the addTab() method?