Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Changing element property while being flicked

Changing element property while being flicked

Scheduled Pinned Locked Moved QML and Qt Quick
2 Posts 2 Posters 570 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    droconut
    wrote on last edited by
    #1

    I'm trying to bind an elements opacity to its (simplified) position when / while being flicked. the opacity is being set, according to
    @onOpacityChanged { console.log(opacity) }@

    but as long as the element is not released the changes wont take place / are not shown. This (mis-)behavior is true for all other visual property changes like color, scale ...

    I guess this is due to the way dragged / flicked elements are drawn in QML?
    Could there be a workaround to this shortcoming?

    greets, droco

    1 Reply Last reply
    0
    • p3c0P Offline
      p3c0P Offline
      p3c0
      Moderators
      wrote on last edited by
      #2

      Hi,

      Just another suggestion, would PathView be suitable to you requirement ?
      Check "PathView":http://qt-project.org/doc/qt-5/qml-qtquick-pathview.html docs. There's "PathAttribute":http://qt-project.org/doc/qt-5/qml-qtquick-pathattribute.html object which can be used to set Opacity or Scale etc.. Once used the corresponding properties are set properly as per the Item's position in the List. Check the example in it's description.
      With PathView you can simulate a Simple ListView or other Complex paths by setting the proper Path like PathQuad, PathLine etc..

      157

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved