src/eric7/Documentation/Source/eric7.PipInterface.PipDialog.html

Sat, 26 Apr 2025 12:34:32 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sat, 26 Apr 2025 12:34:32 +0200
branch
eric7
changeset 11240
c48c615c04a3
parent 10690
fab36645aa7d
permissions
-rw-r--r--

MicroPython
- Added a configuration option to disable the support for the no longer produced Pimoroni Pico Wireless Pack.

<!DOCTYPE html>
<html><head>
<title>eric7.PipInterface.PipDialog</title>
<meta charset="UTF-8">
<link rel="stylesheet" href="styles.css">
</head>
<body>
<a NAME="top" ID="top"></a>
<h1>eric7.PipInterface.PipDialog</h1>
<p>
Module implementing a dialog showing the output of a pip command.
</p>

<h3>Global Attributes</h3>
<table>
<tr><td>None</td></tr>
</table>

<h3>Classes</h3>
<table>
<tr>
<td><a href="#PipDialog">PipDialog</a></td>
<td>Class implementing a dialog showing the output of a 'python -m pip' command.</td>
</tr>
</table>

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

<hr />
<hr />
<a NAME="PipDialog" ID="PipDialog"></a>
<h2>PipDialog</h2>
<p>
    Class implementing a dialog showing the output of a 'python -m pip'
    command.
</p>

<h3>Derived from</h3>
QDialog, Ui_PipDialog
<h3>Class Attributes</h3>
<table>
<tr><td>None</td></tr>
</table>

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

<h3>Methods</h3>
<table>
<tr>
<td><a href="#PipDialog.__init__">PipDialog</a></td>
<td>Constructor</td>
</tr>
<tr>
<td><a href="#PipDialog.__addOutput">__addOutput</a></td>
<td>Private method to add some text to the output pane.</td>
</tr>
<tr>
<td><a href="#PipDialog.__cancel">__cancel</a></td>
<td>Private slot to cancel the current action.</td>
</tr>
<tr>
<td><a href="#PipDialog.__finish">__finish</a></td>
<td>Private slot called when the process finished or the user pressed the button.</td>
</tr>
<tr>
<td><a href="#PipDialog.__procFinished">__procFinished</a></td>
<td>Private slot connected to the finished signal.</td>
</tr>
<tr>
<td><a href="#PipDialog.__readStderr">__readStderr</a></td>
<td>Private slot to handle the readyReadStandardError signal.</td>
</tr>
<tr>
<td><a href="#PipDialog.__readStdout">__readStdout</a></td>
<td>Private slot to handle the readyReadStandardOutput signal.</td>
</tr>
<tr>
<td><a href="#PipDialog.closeEvent">closeEvent</a></td>
<td>Protected slot implementing a close event handler.</td>
</tr>
<tr>
<td><a href="#PipDialog.on_buttonBox_clicked">on_buttonBox_clicked</a></td>
<td>Private slot called by a button of the button box clicked.</td>
</tr>
<tr>
<td><a href="#PipDialog.startProcess">startProcess</a></td>
<td>Public slot used to start the process.</td>
</tr>
<tr>
<td><a href="#PipDialog.startProcesses">startProcesses</a></td>
<td>Public method to issue a list of commands to be executed.</td>
</tr>
</table>

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


<a NAME="PipDialog.__init__" ID="PipDialog.__init__"></a>
<h4>PipDialog (Constructor)</h4>
<b>PipDialog</b>(<i>text, parent=None</i>)
<p>
        Constructor
</p>

<dl>

<dt><i>text</i> (str)</dt>
<dd>
text to be shown by the label
</dd>
<dt><i>parent</i> (QWidget)</dt>
<dd>
reference to the parent widget
</dd>
</dl>
<a NAME="PipDialog.__addOutput" ID="PipDialog.__addOutput"></a>
<h4>PipDialog.__addOutput</h4>
<b>__addOutput</b>(<i>txt</i>)
<p>
        Private method to add some text to the output pane.
</p>

<dl>

<dt><i>txt</i> (str)</dt>
<dd>
text to be added
</dd>
</dl>
<a NAME="PipDialog.__cancel" ID="PipDialog.__cancel"></a>
<h4>PipDialog.__cancel</h4>
<b>__cancel</b>(<i></i>)
<p>
        Private slot to cancel the current action.
</p>

<a NAME="PipDialog.__finish" ID="PipDialog.__finish"></a>
<h4>PipDialog.__finish</h4>
<b>__finish</b>(<i></i>)
<p>
        Private slot called when the process finished or the user pressed
        the button.
</p>

<a NAME="PipDialog.__procFinished" ID="PipDialog.__procFinished"></a>
<h4>PipDialog.__procFinished</h4>
<b>__procFinished</b>(<i>_exitCode, _exitStatus</i>)
<p>
        Private slot connected to the finished signal.
</p>

<dl>

<dt><i>_exitCode</i> (int)</dt>
<dd>
exit code of the process (unused)
</dd>
<dt><i>_exitStatus</i> (QProcess.ExitStatus)</dt>
<dd>
exit status of the process (unused)
</dd>
</dl>
<a NAME="PipDialog.__readStderr" ID="PipDialog.__readStderr"></a>
<h4>PipDialog.__readStderr</h4>
<b>__readStderr</b>(<i></i>)
<p>
        Private slot to handle the readyReadStandardError signal.
</p>
<p>
        It reads the error output of the process and inserts it into the
        error pane.
</p>

<a NAME="PipDialog.__readStdout" ID="PipDialog.__readStdout"></a>
<h4>PipDialog.__readStdout</h4>
<b>__readStdout</b>(<i></i>)
<p>
        Private slot to handle the readyReadStandardOutput signal.
</p>
<p>
        It reads the output of the process, formats it and inserts it into
        the contents pane.
</p>

<a NAME="PipDialog.closeEvent" ID="PipDialog.closeEvent"></a>
<h4>PipDialog.closeEvent</h4>
<b>closeEvent</b>(<i>e</i>)
<p>
        Protected slot implementing a close event handler.
</p>

<dl>

<dt><i>e</i> (QCloseEvent)</dt>
<dd>
close event
</dd>
</dl>
<a NAME="PipDialog.on_buttonBox_clicked" ID="PipDialog.on_buttonBox_clicked"></a>
<h4>PipDialog.on_buttonBox_clicked</h4>
<b>on_buttonBox_clicked</b>(<i>button</i>)
<p>
        Private slot called by a button of the button box clicked.
</p>

<dl>

<dt><i>button</i> (QAbstractButton)</dt>
<dd>
button that was clicked
</dd>
</dl>
<a NAME="PipDialog.startProcess" ID="PipDialog.startProcess"></a>
<h4>PipDialog.startProcess</h4>
<b>startProcess</b>(<i>cmd, args, showArgs=True</i>)
<p>
        Public slot used to start the process.
</p>

<dl>

<dt><i>cmd</i> (str)</dt>
<dd>
name of the pip executable to be used
</dd>
<dt><i>args</i> (list of str)</dt>
<dd>
list of arguments for the process
</dd>
<dt><i>showArgs</i> (bool)</dt>
<dd>
flag indicating to show the arguments
</dd>
</dl>
<dl>
<dt>Return:</dt>
<dd>
flag indicating a successful start of the process
</dd>
</dl>
<dl>
<dt>Return Type:</dt>
<dd>
bool
</dd>
</dl>
<a NAME="PipDialog.startProcesses" ID="PipDialog.startProcesses"></a>
<h4>PipDialog.startProcesses</h4>
<b>startProcesses</b>(<i>processParams</i>)
<p>
        Public method to issue a list of commands to be executed.
</p>

<dl>

<dt><i>processParams</i> (list of tuples of (str, list of str))</dt>
<dd>
list of tuples containing the command
            and arguments
</dd>
</dl>
<dl>
<dt>Return:</dt>
<dd>
flag indicating a successful start of the first process
</dd>
</dl>
<dl>
<dt>Return Type:</dt>
<dd>
bool
</dd>
</dl>
<div align="right"><a href="#top">Up</a></div>
<hr />
</body></html>

eric ide

mercurial