Unsolved Navigate QListWidget
-
*Hi,
I am trying to navigate two listwidgets by using arrow keys, but iam unable to do it.
Please give a solution to navigate by using arrow keys.Thanks in advance.*
-
@DivyaMuthyala Handle keyPressEvent() and set Current ListWidget item using *setCurrentItem(QListWidgetItem ) or setCurrentRow(int row) of QListWidget ...
-
@DivyaMuthyala Isn't it already supported by QListWidget? Or do I misunderstand you?
-
Hi,
Actually My requirement is that I have add two listwidgets in one widget,and i had to navigate both listwidgets items by using arrow keys keys,and I should emit using tab key
-
Hi,
Thanks for replying, my exact need is when i press the down-arrow key three times as you can see in the image the control has to be shifted from top listwidget to bottom listwidget.
Here is the image link.
https://s9.postimg.org/r0ylvqlzz/listwidget.png -
@DivyaMuthyala Use http://doc.qt.io/qt-5.8/qlistwidget.html#itemSelectionChanged and check the index of the selected element there, if it is the last one then set focus on the second QListWidget.
-
HI Jsulm,
Thanks for your advice,Now Iam able to Navigate.
Now I am adding button to QListwidget as a item, How to select that button text. -
@DivyaMuthyala Do you want to select the button or its text? If text then why?