Brought over from => WF bug 169659, <snip> The tooltips *only* appear in the 'Functions' block of the 'Keyboard' tab, but they do not show for the actual assignments in the UI's upper listing of 'Shortcut Keys'. Currently all that is shown on mouseover anywhere in the area of the UI is the generic tooltip: "To quickly find a shortcut in this list, simply press the key combination". This differs from the other panels of the 'Customize' dialog, where a tooltip (with UNO and shortcut if any) as assigned to the control is shown on mouseover. The tooltip duplicates what is shown in the 'Description' (though no Description was added for the Notebookbar customizations, but they get the same tooltips). It would be helpful to Keyboard customization if somehow similar descriptive tooltip could be shown on mouseover of the UNO assignments listed with their 'Shortcut Keys'. Seems this didn't get picked up as bug 112237 was implemented with https://gerrit.libreoffice.org/c/core/+/140142 @Jim, what do you think, can the work on bug 112237 be expanded? </snip> <snip> > @Jim, what do you think, can the work on bug 112237 be expanded? Sure can! If we want to make this a hack for a beginner I will supply code pointers. If we would like this enhancement sooner than later, please let me know ;) </snip>
Absent a major rework of the Customize dialog, adding the existing tooltip on mouseover of a UNO "Function" actually assigned to the keyboard shortcut would be helpful to users now. @Jim, did you want to go ahead and post up code pointers for an easyhack, or just implement?
(In reply to V Stuart Foote from comment #1) > @Jim, did you want to go ahead and post up code pointers for an easyhack, or > just implement? Let's first give some code pointers for any beginner that may be interested: include/tools/link.hxx: #define DECL_LINK #define LINK #define IMPL_LINK include/vcl/weld/TreeView.hxx: weld::TreeView::connect_query_tooltip cui/source/inc/acccfg.hxx: class SfxAcceleratorConfigPage: std::unique_ptr m_xEntriesBox<weld::TreeView> is the TreeView we want to connect a function to so we can supply a tooltip when TreeView::signal_query_tooltip happens. add: DECL_LINK to declare the LINK in weld::TreeView::connect_query_tooltip cui/source/customize/acccfg.cxx: SfxAcceleratorConfigPage: ctor: m_xEntriesBox(m_xBuilder->weld_tree_view(u"shortcuts"_ustr)) add: weld::TreeView::connect_query_tooltip(LINK) add: IMPL_LINK definition to return tooltip string cui/source/inc/acccfg.hxx: struct TAccInfo include/vcl/commandinfoprovider.hxx: vcl::CommandInfoProvider::GetCommandProperties vcl::CommandInfoProvider::GetTooltipForCommand cui/uiconfig/ui/accelconfigpage.ui: <object class="GtkTreeView" id="shortcuts"> set: property has-tooltip so signal_query_tooltip happens. Use glade or edit the .ui file directly. Search the codebase for 'connect_query_tooltip' for example usages.