PDA

View Full Version : Hide and Show QMenu



febil
25th March 2009, 05:55
Hi all,
Is there any method to hide and then show the QMenu item.
Thanks in advance.

spirit
25th March 2009, 06:17
try show/hide. but I'm not sure that I understand what you wanna to achieve. :o

Lykurg
25th March 2009, 07:24
Side note: I don't know your case, but normally it's better not to hide a menu item. Better just set it to disabled (setEnabled(false)).

To hide an item you could also remove it from the QMenu and later if it is needed you can just put it in again.

febil
25th March 2009, 09:31
Thak u for the replies. It works for me by using:
parentMenu->menuAction()->setVisible( false );