eric6/Documentation/Source/eric6.E5Gui.E5PassivePopup.html

Thu, 06 May 2021 19:46:00 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Thu, 06 May 2021 19:46:00 +0200
changeset 8294
cb4e5bbf3a2c
parent 8270
6ba3564b7161
permissions
-rw-r--r--

Updated source docu.

<!DOCTYPE html>
<html><head>
<title>eric6.E5Gui.E5PassivePopup</title>
<meta charset="UTF-8">
<style>
body {
    background: #EDECE6;
    margin: 0em 1em 10em 1em;
    color: black;
}

h1 { color: white; background: #85774A; }
h2 { color: white; background: #85774A; }
h3 { color: white; background: #9D936E; }
h4 { color: white; background: #9D936E; }
    
a { color: #BA6D36; }

</style>
</head>
<body>
<a NAME="top" ID="top"></a>
<h1>eric6.E5Gui.E5PassivePopup</h1>

<p>
Module implementing dialog-like popup that displays messages without
interrupting the user.
</p>
<h3>Global Attributes</h3>

<table>
<tr><td>None</td></tr>
</table>
<h3>Classes</h3>

<table>

<tr>
<td><a href="#E5PassivePopup">E5PassivePopup</a></td>
<td>Class implementing dialog-like popup that displays messages without interrupting the user.</td>
</tr>
<tr>
<td><a href="#E5PassivePopupStyle">E5PassivePopupStyle</a></td>
<td>Class defining the popup styles.</td>
</tr>
</table>
<h3>Functions</h3>

<table>
<tr><td>None</td></tr>
</table>
<hr />
<hr />
<a NAME="E5PassivePopup" ID="E5PassivePopup"></a>
<h2>E5PassivePopup</h2>

<p>
    Class implementing dialog-like popup that displays messages without
    interrupting the user.
</p>
<h3>Signals</h3>
<dl>

<dt>clicked</dt>
<dd>
emitted to indicate a mouse button click
</dd>
</dl>
<h3>Derived from</h3>
QFrame
<h3>Class Attributes</h3>

<table>
<tr><td>DefaultPopupTime</td></tr>
</table>
<h3>Class Methods</h3>

<table>
<tr><td>None</td></tr>
</table>
<h3>Methods</h3>

<table>

<tr>
<td><a href="#E5PassivePopup.__init__">E5PassivePopup</a></td>
<td>Constructor</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.__calculateNearbyPoint">__calculateNearbyPoint</a></td>
<td>Private method to calculate the position to place the popup near the specified rectangle.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.__defaultArea">__defaultArea</a></td>
<td>Private method to determine the default rectangle to be passed to moveNear().</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.__moveNear">__moveNear</a></td>
<td>Private method to move the popup to be adjacent to the specified rectangle.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.__positionSelf">__positionSelf</a></td>
<td>Private method to position the popup.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.getCustomData">getCustomData</a></td>
<td>Public method to get some custom data.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.hideEvent">hideEvent</a></td>
<td>Protected method to handle the hide event.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.mouseReleaseEvent">mouseReleaseEvent</a></td>
<td>Protected method to handle a mouse release event.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.setCustomData">setCustomData</a></td>
<td>Public method to set some custom data.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.setTimeout">setTimeout</a></td>
<td>Public method to set the delay for the popup is removed automatically.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.setView">setView</a></td>
<td>Public method to set the message view.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.setVisible">setVisible</a></td>
<td>Public method to show or hide the popup.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.show">show</a></td>
<td>Public slot to show the popup.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.timeout">timeout</a></td>
<td>Public method to get the delay before the popup is removed automatically.</td>
</tr>
<tr>
<td><a href="#E5PassivePopup.view">view</a></td>
<td>Public method to get a reference to the message view.</td>
</tr>
</table>
<h3>Static Methods</h3>

<table>
<tr><td>None</td></tr>
</table>

<a NAME="E5PassivePopup.__init__" ID="E5PassivePopup.__init__"></a>
<h4>E5PassivePopup (Constructor)</h4>
<b>E5PassivePopup</b>(<i>style=E5PassivePopupStyle.BOXED, parent=None</i>)

<p>
        Constructor
</p>
<dl>

<dt><i>style</i> (E5PassivePopupStyle)</dt>
<dd>
style of the popup
</dd>
<dt><i>parent</i> (QWidget)</dt>
<dd>
reference to the parent widget
</dd>
</dl>
<a NAME="E5PassivePopup.__calculateNearbyPoint" ID="E5PassivePopup.__calculateNearbyPoint"></a>
<h4>E5PassivePopup.__calculateNearbyPoint</h4>
<b>__calculateNearbyPoint</b>(<i>target</i>)

<p>
        Private method to calculate the position to place the popup near the
        specified rectangle.
</p>
<dl>

<dt><i>target</i></dt>
<dd>
rectangle to be placed at (QRect)
</dd>
</dl>
<dl>
<dt>Return:</dt>
<dd>
position to place the popup (QPoint)
</dd>
</dl>
<a NAME="E5PassivePopup.__defaultArea" ID="E5PassivePopup.__defaultArea"></a>
<h4>E5PassivePopup.__defaultArea</h4>
<b>__defaultArea</b>(<i></i>)

<p>
        Private method to determine the default rectangle to be passed to
        moveNear().
</p>
<dl>
<dt>Return:</dt>
<dd>
default rectangle (QRect)
</dd>
</dl>
<a NAME="E5PassivePopup.__moveNear" ID="E5PassivePopup.__moveNear"></a>
<h4>E5PassivePopup.__moveNear</h4>
<b>__moveNear</b>(<i>target</i>)

<p>
        Private method to move the popup to be adjacent to the specified
        rectangle.
</p>
<dl>

<dt><i>target</i></dt>
<dd>
rectangle to be placed at (QRect)
</dd>
</dl>
<a NAME="E5PassivePopup.__positionSelf" ID="E5PassivePopup.__positionSelf"></a>
<h4>E5PassivePopup.__positionSelf</h4>
<b>__positionSelf</b>(<i></i>)

<p>
        Private method to position the popup.
</p>
<a NAME="E5PassivePopup.getCustomData" ID="E5PassivePopup.getCustomData"></a>
<h4>E5PassivePopup.getCustomData</h4>
<b>getCustomData</b>(<i>key</i>)

<p>
        Public method to get some custom data.
</p>
<dl>

<dt><i>key</i> (str)</dt>
<dd>
key for the custom data
</dd>
</dl>
<dl>
<dt>Return:</dt>
<dd>
stored data
</dd>
</dl>
<dl>
<dt>Return Type:</dt>
<dd>
any
</dd>
</dl>
<a NAME="E5PassivePopup.hideEvent" ID="E5PassivePopup.hideEvent"></a>
<h4>E5PassivePopup.hideEvent</h4>
<b>hideEvent</b>(<i>evt</i>)

<p>
        Protected method to handle the hide event.
</p>
<dl>

<dt><i>evt</i></dt>
<dd>
reference to the hide event (QHideEvent)
</dd>
</dl>
<a NAME="E5PassivePopup.mouseReleaseEvent" ID="E5PassivePopup.mouseReleaseEvent"></a>
<h4>E5PassivePopup.mouseReleaseEvent</h4>
<b>mouseReleaseEvent</b>(<i>evt</i>)

<p>
        Protected method to handle a mouse release event.
</p>
<dl>

<dt><i>evt</i></dt>
<dd>
reference to the mouse event (QMouseEvent)
</dd>
</dl>
<a NAME="E5PassivePopup.setCustomData" ID="E5PassivePopup.setCustomData"></a>
<h4>E5PassivePopup.setCustomData</h4>
<b>setCustomData</b>(<i>key, data</i>)

<p>
        Public method to set some custom data.
</p>
<dl>

<dt><i>key</i> (str)</dt>
<dd>
key for the custom data
</dd>
<dt><i>data</i> (any)</dt>
<dd>
data to be stored
</dd>
</dl>
<a NAME="E5PassivePopup.setTimeout" ID="E5PassivePopup.setTimeout"></a>
<h4>E5PassivePopup.setTimeout</h4>
<b>setTimeout</b>(<i>delay</i>)

<p>
        Public method to set the delay for the popup is removed automatically.
</p>
<p>
        Setting the delay to 0 disables the timeout. If you're doing this, you
        may want to connect the clicked() signal to the hide() slot. Setting
        the delay to -1 makes it use the default value.
</p>
<dl>

<dt><i>delay</i></dt>
<dd>
value for the delay in milliseconds (integer)
</dd>
</dl>
<a NAME="E5PassivePopup.setView" ID="E5PassivePopup.setView"></a>
<h4>E5PassivePopup.setView</h4>
<b>setView</b>(<i>child</i>)

<p>
        Public method to set the message view.
</p>
<dl>

<dt><i>child</i></dt>
<dd>
reference to the widget to set as the message view
            (QWidget)
</dd>
</dl>
<a NAME="E5PassivePopup.setVisible" ID="E5PassivePopup.setVisible"></a>
<h4>E5PassivePopup.setVisible</h4>
<b>setVisible</b>(<i>visible</i>)

<p>
        Public method to show or hide the popup.
</p>
<dl>

<dt><i>visible</i></dt>
<dd>
flag indicating the visibility status (boolean)
</dd>
</dl>
<a NAME="E5PassivePopup.show" ID="E5PassivePopup.show"></a>
<h4>E5PassivePopup.show</h4>
<b>show</b>(<i>p=None</i>)

<p>
        Public slot to show the popup.
</p>
<dl>

<dt><i>p</i></dt>
<dd>
position for the popup (QPoint)
</dd>
</dl>
<a NAME="E5PassivePopup.timeout" ID="E5PassivePopup.timeout"></a>
<h4>E5PassivePopup.timeout</h4>
<b>timeout</b>(<i></i>)

<p>
        Public method to get the delay before the popup is removed
        automatically.
</p>
<dl>
<dt>Return:</dt>
<dd>
the delay before the popup is removed automatically (integer)
</dd>
</dl>
<a NAME="E5PassivePopup.view" ID="E5PassivePopup.view"></a>
<h4>E5PassivePopup.view</h4>
<b>view</b>(<i></i>)

<p>
        Public method to get a reference to the message view.
</p>
<dl>
<dt>Return:</dt>
<dd>
reference to the message view (QWidget)
</dd>
</dl>
<div align="right"><a href="#top">Up</a></div>
<hr />
<hr />
<a NAME="E5PassivePopupStyle" ID="E5PassivePopupStyle"></a>
<h2>E5PassivePopupStyle</h2>

<p>
    Class defining the popup styles.
</p>
<h3>Derived from</h3>
enum.Enum
<h3>Class Attributes</h3>

<table>
<tr><td>BOXED</td></tr><tr><td>CUSTOM</td></tr><tr><td>STYLED</td></tr>
</table>
<h3>Class Methods</h3>

<table>
<tr><td>None</td></tr>
</table>
<h3>Methods</h3>

<table>
<tr><td>None</td></tr>
</table>
<h3>Static Methods</h3>

<table>
<tr><td>None</td></tr>
</table>

<div align="right"><a href="#top">Up</a></div>
<hr />
</body></html>

eric ide

mercurial