File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -83,17 +83,18 @@ void InputBindingWidget::updateText()
8383 else
8484 {
8585 QString binding_text (QString::fromStdString (m_bindings[0 ]));
86- setToolTip (binding_text);
8786
88- // fix up accelerators, and if it's too long, ellipsise it
87+ // fix up accelerators
8988 if (binding_text.contains (' &' ))
9089 binding_text = binding_text.replace (QStringLiteral (" &" ), QStringLiteral (" &&" ));
9190
91+ setToolTip (QStringLiteral (" %1\n\n %2\n %3" ).arg (binding_text).arg (tr (help_text)).arg (tr (help_clear_text)));
92+
93+ // if it's too long, ellipsise it
9294 const int max_length = (width () < 300 ) ? 35 : 60 ;
9395 if (binding_text.length () > max_length)
9496 binding_text = binding_text.left (max_length).append (QStringLiteral (" ..." ));
9597 setText (binding_text);
96- setToolTip (QStringLiteral (" %1\n\n %2\n %3" ).arg (binding_text).arg (tr (help_text)).arg (tr (help_clear_text)));
9798 }
9899}
99100
You can’t perform that action at this time.
0 commit comments