For example: *README.plugin* 6.1 Implement a plugin GUI menu The menu entries themselves are generated with the following code structure:
ext_menu_t * ext_menu, *os_menu = NULL; ext_menu = ext_menubar_register_menu ( <your_proto_item>, "Some Menu Entry", true ); *ext_menubar_add_entry*(ext_menu, "Test Entry 1", "*This is a tooltip*", menu_cb, <user_data>); *plugin_if.h* /* Registers a new menubar entry. * * This registers a new menubar entry, which will have the given name, and * call the provided callback on activation * * @param parent_menu the parent menu for this entry * @param name the entry name (the internal used one) for the menu item * @param label the entry label (the displayed name) for the menu item * *@param tooltip a tooltip to be displayed on mouse-over* * @param callback the action which will be invoked after click on the menu item */ WS_DLL_PUBLIC void ext_menubar_add_entry( ext_menu_t * parent_menu, const char *label, *const char *tooltip,* ext_menubar_action_cb callback, void *user_data); https://www.wireshark.org/docs/wsar_html/plugin__if_8h_source.html https://www.wireshark.org/docs/wsar_html/plugin__if_8h.html WS_DLL_PUBLIC void *ext_menubar_add_entry* (ext_menu_t <https://www.wireshark.org/docs/wsar_html/struct__ext__menubar__t.html> *parent_menu, const char *label, const char *tooltip, ext_menubar_action_cb callback, void *user_data) Beside of this, it seems there is one line of code also missing, to set the toolTip of the related QAction()... wireshark_main_window.cpp void WiresharkMainWindow::externalMenuHelper(ext_menu_t * menu, QMenu * subMenu, int depth) ... } else if (item->type == EXT_MENUBAR_ITEM || item->type == EXT_MENUBAR_URL) { itemAction = subMenu->addAction(item->name); itemAction->setData(QVariant::fromValue(static_cast<void *>(item))); itemAction->setText(item->label); *itemAction->setToolTip(item->tooltip); /* this line is missing */* connect(itemAction, &QAction::triggered, this, &WiresharkMainWindow::externalMenuItemTriggered); } On Wed, 4 Jun 2025 at 18:51, chuck c <bubbas...@gmail.com> wrote: > > external plugins or uses Lua code, documentation for those mentions and > supports tooltips > Where in the documentation? > > On Tue, Jun 3, 2025 at 8:33 AM Tamás Regős <reg...@gmail.com> wrote: > >> I was trying to Google it but I was not able to find. :) >> >> Thanks for those links, seems to be quite old but I guess the overall >> mindset has not changed then. >> >> Just for curiosity, I tested it with setToolTipsVisible(true) in cpp >> code and it worked on Windows. >> >> The reason I was checking this is that if someone develops external >> plugins or uses Lua code, documentation for those mentions and supports >> tooltips but it never ends up working obviously. So it's confusing a bit. >> >> Not sure if it's worth raising a follow up issue on Gitlab? >> >> Could there be a new preference option added to turn it on/off? >> >> On Tue, 3 Jun 2025 at 19:46, chuck c <bubbas...@gmail.com> wrote: >> >>> https://gitlab.com/wireshark/wireshark/-/issues/16590 (Tooltips on >>> menus don't work) >>> >>> https://gitlab.com/wireshark/wireshark/-/merge_requests/6221 (Tooltips >>> for menu items that open browser windows) >>> >>> >>> On Tue, Jun 3, 2025 at 6:22 AM Tamás Regős <reg...@gmail.com> wrote: >>> >>>> Dear Developers, >>>> >>>> Does anyone know why the toolTips for the Menu items are not enabled? >>>> >>>> Is this deliberate or a bug? >>>> >>>> It's only enabled for 'Help' in the ui file: >>>> <widget class="QMenu" name="menuHelp"> >>>> <property name="title"> >>>> <string>&Help</string> >>>> </property> >>>> <property name="toolTipsVisible"> >>>> <bool>true</bool> >>>> </property> >>>> >>>> toolTipsVisible : bool >>>> This property holds whether tooltips of menu actions should be visible >>>> This property specifies whether action menu entries show their tooltip. >>>> *By default, this property is false*. >>>> >>>> Thank you. >>>> >>>> Regards, >>>> Tamas >>>> _______________________________________________ >>>> Wireshark-dev mailing list -- wireshark-dev@wireshark.org >>>> To unsubscribe send an email to wireshark-dev-le...@wireshark.org >>>> >>> _______________________________________________ >>> Wireshark-dev mailing list -- wireshark-dev@wireshark.org >>> To unsubscribe send an email to wireshark-dev-le...@wireshark.org >>> >> _______________________________________________ >> Wireshark-dev mailing list -- wireshark-dev@wireshark.org >> To unsubscribe send an email to wireshark-dev-le...@wireshark.org >> > _______________________________________________ > Wireshark-dev mailing list -- wireshark-dev@wireshark.org > To unsubscribe send an email to wireshark-dev-le...@wireshark.org >
_______________________________________________ Wireshark-dev mailing list -- wireshark-dev@wireshark.org To unsubscribe send an email to wireshark-dev-le...@wireshark.org