Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt for Python
  4. Inbuilt searching in pyside6 for qtableview
Forum Updated to NodeBB v4.3 + New Features

Inbuilt searching in pyside6 for qtableview

Scheduled Pinned Locked Moved Unsolved Qt for Python
2 Posts 2 Posters 460 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.
  • N Offline
    N Offline
    Nandini
    wrote on last edited by
    #1

    So I have made a GUI with the following constraints:

    1. populating table data in qtableview using QAbstractablemodel
    2. Switching the data in the table using button( I populate two csv's using this button)

    I want to have an in-built searching feature in qtableview in each cell of row 0 in order to search the columns

    What happens is on using custom delegate in qtableview and switching the data, my search row disappears. It also disappears when i start typing in the cell.

    I tried searching for a lot of examples and found this is possible in qtablewidget. But i dont want to change my code to that. It will be a lot of rework. How do I make this work on qtableview

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      You can use a proxy model, you can also use a different widget like the frozen column example shows.

      Or you can simply have a generic search and set which row the search applies to.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      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