Important: Please read the Qt Code of Conduct -

List View Zooming

  • Hello, I'm trying to make a lightweight pdf-like viewer based on a proprietary format. I'm relatively new to Qt (strict hobby), and I was thinking of using list view to render each page. My issue is that I'm having difficulty with zooming feature on lsit view. I thought maybe just scaling the contentitem will be fine, but this seems to change the area by which the view registers mouse events. For instance, scaling by 0.5, I can only scroll if my mouse is over a smaller rectangle, and not the whole listview item.

    1. Any ideas about how to fix this?
    2. Do you think QML listview is the best way to implement a pdf-like renderer? If not, any other recommendations?


  • Hmm, i think as main container is "StackView": a good element. For the pages use a "flickable container": with a child item to render the content. Change the size of the child item for zooming should have a direct effect to the flickable element for scrolling.

Log in to reply