mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
Fix bug 3508:
* src/ToolbarBackend.cpp: * lib/ui/stdtoolbars.inc: - add tooltip to table widget * src/frontends/qt4/QLToolbar.cpp: - display tooltip as icon text git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18208 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
fabf9f5af3
commit
574b28db65
@ -30,7 +30,7 @@
|
||||
#
|
||||
# Minibuffer adds the command buffer (Qt only, only one may exist)
|
||||
#
|
||||
# TableInsert adds a special widget for quick insertion of tables
|
||||
# TableInsert "The tooltip" adds a special widget for quick insertion of tables
|
||||
#
|
||||
# PopupMenu "name" "GUI Name"
|
||||
#
|
||||
@ -74,7 +74,7 @@ ToolbarSet
|
||||
Separator
|
||||
Item "Insert math" "math-mode"
|
||||
Item "Insert graphics" "dialog-show-new-inset graphics"
|
||||
TableInsert
|
||||
TableInsert "Insert table"
|
||||
End
|
||||
|
||||
Toolbar "extra" "Extra"
|
||||
|
@ -181,8 +181,11 @@ ToolbarInfo & ToolbarInfo::read(Lexer & lex)
|
||||
break;
|
||||
|
||||
case TO_TABLEINSERT:
|
||||
add(ToolbarItem(ToolbarItem::TABLEINSERT,
|
||||
FuncRequest(kb_action(ToolbarItem::TABLEINSERT))));
|
||||
if (lex.next(true)) {
|
||||
docstring const tooltip = lex.getDocString();
|
||||
add(ToolbarItem(ToolbarItem::TABLEINSERT,
|
||||
FuncRequest(kb_action(ToolbarItem::TABLEINSERT)), tooltip));
|
||||
}
|
||||
break;
|
||||
|
||||
case TO_ENDTOOLBAR:
|
||||
|
@ -197,6 +197,7 @@ void QLToolbar::add(ToolbarItem const & item)
|
||||
tb->setIcon(QPixmap(toqstr(getIcon(FuncRequest(LFUN_TABULAR_INSERT)))));
|
||||
tb->setToolTip(qt_(to_ascii(item.label_)));
|
||||
tb->setStatusTip(qt_(to_ascii(item.label_)));
|
||||
tb->setText(qt_(to_ascii(item.label_)));
|
||||
InsertTableWidget * iv = new InsertTableWidget(owner_, tb);
|
||||
connect(tb, SIGNAL(clicked(bool)), iv, SLOT(show(bool)));
|
||||
connect(iv, SIGNAL(visible(bool)), tb, SLOT(setChecked(bool)));
|
||||
|
Loading…
Reference in New Issue
Block a user