Skip to content
Permalink
Browse files

plugin installer: split the description tooltip into multiple lines a…

…s needed

some plugins have so long descriptions, a single line tooltip doesn't fit
 on my 1366px screen. Would be even worse on mobile devices if they had
 the notion of mouse over tooltips. :I Example: MultiEdit
  • Loading branch information
lynxlynxlynx committed Jun 24, 2012
1 parent 3107512 commit 7d469dbf371cc595a9c71fd3ef1c9a540a424e0e
Showing with 10 additions and 1 deletion.
  1. +10 −1 python/plugins/plugin_installer/installer_gui.py
@@ -485,7 +485,16 @@ def addItem(p):
a.setText(2,ver)
a.setToolTip(2,verTip)
a.setText(3,desc)
a.setToolTip(3,descTip)
# split the tooltip into multiple lines when they are too long
tmp = ""
splitTip = ""
for word in descTip.split(" "):
if len(tmp + word) < 80:
tmp = tmp + " " + word
else:
splitTip += tmp + "\n"
tmp = word
a.setToolTip(3, splitTip+tmp)
a.setText(4,p["author"])
if p["homepage"]:
a.setToolTip(4,p["homepage"])

0 comments on commit 7d469db

Please sign in to comment.
You can’t perform that action at this time.