File: qtooltip.html

package info (click to toggle)
python-qt4 4.0.1-5
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 18,632 kB
  • ctags: 2,639
  • sloc: python: 29,409; sh: 5,646; cpp: 3,168; xml: 149; makefile: 109
file content (18 lines) | stat: -rw-r--r-- 4,116 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
<html><head><title>QToolTip Class Reference</title><style>h3.fn,span.fn { margin-left: 1cm; text-indent: -1cm }
a:link { color: #004faf; text-decoration: none }
a:visited { color: #672967; text-decoration: none }
td.postheader { font-family: sans-serif }
tr.address { font-family: sans-serif }
body { background: #ffffff; color: black; }
</style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr /><td align="left" valign="top" width="32"><img align="left" border="0" height="32" src="images/rb-logo.png" width="32" /></td><td width="1">&#160;&#160;</td><td class="postheader" valign="center"><a href="../pyqt4ref.html"><font color="#004faf">Home</font></a>&#160;&#183; <a href="classes.html"><font color="#004faf">All Classes</font></a>&#160;&#183; <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QToolTip Class Reference<br /><sup><sup>[<a href="qtgui.html">QtGui</a> module]</sup></sup></h1><p>The QToolTip class provides tool tips (balloon help) for any widget. <a href="#details">More...</a></p>
<h3>Methods</h3><ul><li><div class="fn" /><b><a href="qtooltip.html#QToolTip">__init__</a></b> (<i>self</i>, QToolTip)</li></ul><h3>Static Methods</h3><ul><li><div class="fn" />QPalette <b><a href="qtooltip.html#palette">palette</a></b> ()</li><li><div class="fn" /><b><a href="qtooltip.html#showText">showText</a></b> (QPoint&#160;<i>pos</i>, QString&#160;<i>text</i>, QWidget&#160;<i>w</i>&#160;=&#160;None)</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QToolTip class provides tool tips (balloon help) for any widget.</p>
<p>The tip is a short piece of text reminding the user of the widget's function. It is drawn immediately below the given position in a distinctive black-on-yellow color combination. The tip can be any <a href="qtextedit.html">rich text</a> formatted string.</p>
<p>Rich text formatted tips implictely do word breaking, unless specified differently with <tt>&lt;p style='white-space:pre'&gt;</tt>.</p>
<p>The simplest and most common way to set a widget's tooltip is by calling its <a href="qwidget.html#toolTip-prop">QWidget.setToolTip</a>() function.</p>
<p>It is also possible to show different tool tips for different regions of a widget, by using a <a href="qhelpevent.html">QHelpEvent</a> of type <a href="qevent.html#Type-enum">QEvent.ToolTip</a>. Intercept the help event in your widget's <a href="qwidget.html#event">QWidget.event</a>() function and call <a href="qtooltip.html#showText">QToolTip.showText</a>() with the text you want to display. The <a href="widgets-tooltips.html">Tooltips</a> example illustrates this technique.</p>
<p>See also <a href="qwidget.html#toolTip-prop">QWidget.toolTip</a> and <a href="qaction.html#toolTip-prop">QAction.toolTip</a>.</p>
<hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QToolTip" />QToolTip.__init__ (<i>self</i>, <a href="qtooltip.html">QToolTip</a>)</h3><h3 class="fn"><a name="palette" /><a href="qpalette.html">QPalette</a> QToolTip.palette ()</h3><p>Returns the palette used to render tooltips.</p>
<h3 class="fn"><a name="showText" />QToolTip.showText (<a href="qpoint.html">QPoint</a>&#160;<i>pos</i>, <a href="qstring.html">QString</a>&#160;<i>text</i>, <a href="qwidget.html">QWidget</a>&#160;<i>w</i>&#160;=&#160;None)</h3><p>Shows <i>text</i> as a tool tip, at global position <i>pos</i>. The optional widget argument, <i>w</i>, is used to determine the appropriate screen on multi-head systems. If <i>text</i> is empty the tool tip is hidden.</p>
<address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td width="25%">PyQt&#160;4.0.1 for X11</td><td align="center" width="50%">Copyright &#169; <a href="http://www.riverbankcomputing.com">Riverbank&#160;Computing&#160;Ltd</a> and <a href="http://www.trolltech.com">Trolltech&#160;AS</a> 2006</td><td align="right" width="25%">Qt&#160;4.1.4</td></tr></table></div></address></body></html>