Documentation/Source/eric5.Utilities.uic.html

changeset 58
37f0444c3479
parent 21
b88a0e6268bd
child 110
c9a969db1469
--- a/Documentation/Source/eric5.Utilities.uic.html	Thu Jan 14 17:27:31 2010 +0000
+++ b/Documentation/Source/eric5.Utilities.uic.html	Thu Jan 14 18:35:52 2010 +0000
@@ -22,8 +22,8 @@
 <body><a NAME="top" ID="top"></a>
 <h1>eric5.Utilities.uic</h1>
 <p>
-&#77;&#111;&#100;&#117;&#108;&#101; &#105;&#109;&#112;&#108;&#101;&#109;&#101;&#110;&#116;&#105;&#110;&#103; &#97; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#111; &#99;&#111;&#109;&#112;&#105;&#108;&#101; &#97;&#108;&#108; &#117;&#115;&#101;&#114; &#105;&#110;&#116;&#101;&#114;&#102;&#97;&#99;&#101; &#102;&#105;&#108;&#101;&#115; &#111;&#102; &#97;
-&#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#111;&#114; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#116;&#114;&#101;&#101;.
+Module implementing a function to compile all user interface files of a
+directory or directory tree.
 </p>
 <h3>Global Attributes</h3>
 <table>
@@ -37,16 +37,16 @@
 <table>
 <tr>
 <td><a href="#compileUiDir">compileUiDir</a></td>
-<td>&#67;&#114;&#101;&#97;&#116;&#101;&#115; &#80;y&#116;&#104;&#111;&#110; &#109;&#111;&#100;&#117;&#108;&#101;&#115; &#102;&#114;&#111;&#109; &#81;&#116; &#68;&#101;&#115;&#105;&#103;&#110;&#101;&#114; .&#117;&#105; &#102;&#105;&#108;&#101;&#115; &#105;&#110; &#97; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#111;&#114; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#116;&#114;&#101;&#101;.</td>
+<td>Creates Python modules from Qt Designer .ui files in a directory or directory tree.</td>
 </tr><tr>
 <td><a href="#compileUiFiles">compileUiFiles</a></td>
-<td>&#77;&#111;&#100;&#117;&#108;&#101; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#111; &#99;&#111;&#109;&#112;&#105;&#108;&#101; &#116;&#104;&#101; .&#117;&#105; &#102;&#105;&#108;&#101;&#115; &#111;&#102; &#97; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#116;&#114;&#101;&#101; &#116;&#111; &#80;y&#116;&#104;&#111;&#110; &#115;&#111;&#117;&#114;&#99;&#101;&#115;.</td>
+<td>Module function to compile the .ui files of a directory tree to Python sources.</td>
 </tr><tr>
 <td><a href="#compile_ui">compile_ui</a></td>
-<td>&#76;&#111;&#99;&#97;&#108; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#111; &#99;&#111;&#109;&#112;&#105;&#108;&#101; &#97; &#115;&#105;&#110;&#103;&#108;&#101; .&#117;&#105; &#102;&#105;&#108;&#101;.</td>
+<td>Local function to compile a single .ui file.</td>
 </tr><tr>
 <td><a href="#pyName">pyName</a></td>
-<td>&#76;&#111;&#99;&#97;&#108; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#111; &#99;&#114;&#101;&#97;&#116;&#101; &#116;&#104;&#101; &#80;y&#116;&#104;&#111;&#110; &#115;&#111;&#117;&#114;&#99;&#101; &#102;&#105;&#108;&#101; &#110;&#97;&#109;&#101; &#102;&#111;&#114; &#116;&#104;&#101; &#99;&#111;&#109;&#112;&#105;&#108;&#101;&#100; .&#117;&#105; &#102;&#105;&#108;&#101;.</td>
+<td>Local function to create the Python source file name for the compiled .ui file.</td>
 </tr>
 </table>
 <hr /><hr />
@@ -54,30 +54,30 @@
 <h2>compileUiDir</h2>
 <b>compileUiDir</b>(<i>dir, recurse = False, map = None, **compileUi_args</i>)
 <p>
-            &#67;&#114;&#101;&#97;&#116;&#101;&#115; &#80;y&#116;&#104;&#111;&#110; &#109;&#111;&#100;&#117;&#108;&#101;&#115; &#102;&#114;&#111;&#109; &#81;&#116; &#68;&#101;&#115;&#105;&#103;&#110;&#101;&#114; .&#117;&#105; &#102;&#105;&#108;&#101;&#115; &#105;&#110; &#97; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#111;&#114;
-            &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#116;&#114;&#101;&#101;.
+            Creates Python modules from Qt Designer .ui files in a directory or
+            directory tree.
 </p><p>
-            &#78;&#111;&#116;&#101;&#58; &#84;&#104;&#105;&#115; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#105;&#115; &#97; &#109;&#111;&#100;&#105;&#102;&#105;&#101;&#100; v&#101;&#114;&#115;&#105;&#111;&#110; &#111;&#102; &#116;&#104;&#101; &#111;&#110;&#101; &#102;&#111;&#117;&#110;&#100; &#105;&#110; &#80;y&#81;&#116;&#52;.
+            Note: This function is a modified version of the one found in PyQt4.
 </p><dl>
 <dt><i>dir</i></dt>
 <dd>
-&#78;&#97;&#109;&#101; &#111;&#102; &#116;&#104;&#101; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#116;&#111; &#115;&#99;&#97;&#110; &#102;&#111;&#114; &#102;&#105;&#108;&#101;&#115; w&#104;&#111;&#115;&#101; &#110;&#97;&#109;&#101; &#101;&#110;&#100;&#115; w&#105;&#116;&#104;
-                '.&#117;&#105;'. &#66;y &#100;&#101;&#102;&#97;&#117;&#108;&#116; &#116;&#104;&#101; &#103;&#101;&#110;&#101;&#114;&#97;&#116;&#101;&#100; &#80;y&#116;&#104;&#111;&#110; &#109;&#111;&#100;&#117;&#108;&#101; &#105;&#115; &#99;&#114;&#101;&#97;&#116;&#101;&#100; &#105;&#110; &#116;&#104;&#101; &#115;&#97;&#109;&#101;
-                &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#101;&#110;&#100;&#105;&#110;&#103; w&#105;&#116;&#104; '.&#112;y'.
+Name of the directory to scan for files whose name ends with
+                '.ui'. By default the generated Python module is created in the same
+                directory ending with '.py'.
 </dd><dt><i>recurse</i></dt>
 <dd>
-&#102;&#108;&#97;&#103; &#105;&#110;&#100;&#105;&#99;&#97;&#116;&#105;&#110;&#103; &#116;&#104;&#97;&#116; &#97;&#110;y &#115;&#117;&#98;-&#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;&#105;&#101;&#115; &#115;&#104;&#111;&#117;&#108;&#100; &#98;&#101; &#115;&#99;&#97;&#110;&#110;&#101;&#100;.
+flag indicating that any sub-directories should be scanned.
 </dd><dt><i>map</i></dt>
 <dd>
-&#97;&#110; &#111;&#112;&#116;&#105;&#111;&#110;&#97;&#108; &#99;&#97;&#108;&#108;&#97;&#98;&#108;&#101; &#116;&#104;&#97;&#116; &#105;&#115; &#112;&#97;&#115;&#115;&#101;&#100; &#116;&#104;&#101; &#110;&#97;&#109;&#101; &#111;&#102; &#116;&#104;&#101; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y
-                &#99;&#111;&#110;&#116;&#97;&#105;&#110;&#105;&#110;&#103; &#116;&#104;&#101; '.&#117;&#105;' &#102;&#105;&#108;&#101; &#97;&#110;&#100; &#116;&#104;&#101; &#110;&#97;&#109;&#101; &#111;&#102; &#116;&#104;&#101; &#80;y&#116;&#104;&#111;&#110; &#109;&#111;&#100;&#117;&#108;&#101; &#116;&#104;&#97;&#116; w&#105;&#108;&#108; &#98;&#101;
-                &#99;&#114;&#101;&#97;&#116;&#101;&#100;. &#84;&#104;&#101; &#99;&#97;&#108;&#108;&#97;&#98;&#108;&#101; &#115;&#104;&#111;&#117;&#108;&#100; &#114;&#101;&#116;&#117;&#114;&#110; &#97; &#116;&#117;&#112;&#108;&#101; &#111;&#102; &#116;&#104;&#101; &#110;&#97;&#109;&#101; &#111;&#102; &#116;&#104;&#101; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y
-                &#105;&#110; w&#104;&#105;&#99;&#104; &#116;&#104;&#101; &#80;y&#116;&#104;&#111;&#110; &#109;&#111;&#100;&#117;&#108;&#101; w&#105;&#108;&#108; &#98;&#101; &#99;&#114;&#101;&#97;&#116;&#101;&#100; &#97;&#110;&#100; &#116;&#104;&#101; (&#112;&#111;&#115;&#115;&#105;&#98;&#108;y &#109;&#111;&#100;&#105;&#102;&#105;&#101;&#100;)
-                &#110;&#97;&#109;&#101; &#111;&#102; &#116;&#104;&#101; &#109;&#111;&#100;&#117;&#108;&#101;.
+an optional callable that is passed the name of the directory
+                containing the '.ui' file and the name of the Python module that will be
+                created. The callable should return a tuple of the name of the directory
+                in which the Python module will be created and the (possibly modified)
+                name of the module.
 </dd><dt><i>compileUi_args</i></dt>
 <dd>
-&#97;&#110;y &#97;&#100;&#100;&#105;&#116;&#105;&#111;&#110;&#97;&#108; &#107;&#101;yw&#111;&#114;&#100; &#97;&#114;&#103;&#117;&#109;&#101;&#110;&#116;&#115; &#116;&#104;&#97;&#116; &#97;&#114;&#101; &#112;&#97;&#115;&#115;&#101;&#100; &#116;&#111;
-                &#116;&#104;&#101; &#99;&#111;&#109;&#112;&#105;&#108;&#101;&#85;&#105;() &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#104;&#97;&#116; &#105;&#115; &#99;&#97;&#108;&#108;&#101;&#100; &#116;&#111; &#99;&#114;&#101;&#97;&#116;&#101; &#101;&#97;&#99;&#104; &#80;y&#116;&#104;&#111;&#110; &#109;&#111;&#100;&#117;&#108;&#101;.
+any additional keyword arguments that are passed to
+                the compileUi() function that is called to create each Python module.
 </dd>
 </dl>
 <div align="right"><a href="#top">Up</a></div>
@@ -86,14 +86,14 @@
 <h2>compileUiFiles</h2>
 <b>compileUiFiles</b>(<i>dir, recurse = False</i>)
 <p>
-    &#77;&#111;&#100;&#117;&#108;&#101; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#111; &#99;&#111;&#109;&#112;&#105;&#108;&#101; &#116;&#104;&#101; .&#117;&#105; &#102;&#105;&#108;&#101;&#115; &#111;&#102; &#97; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#116;&#114;&#101;&#101; &#116;&#111; &#80;y&#116;&#104;&#111;&#110; &#115;&#111;&#117;&#114;&#99;&#101;&#115;.
+    Module function to compile the .ui files of a directory tree to Python sources.
 </p><dl>
 <dt><i>dir</i></dt>
 <dd>
-&#110;&#97;&#109;&#101; &#111;&#102; &#97; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#116;&#111; &#115;&#99;&#97;&#110; &#102;&#111;&#114; .&#117;&#105; &#102;&#105;&#108;&#101;&#115; (&#115;&#116;&#114;&#105;&#110;&#103; &#111;&#114; &#81;&#83;&#116;&#114;&#105;&#110;&#103;)
+name of a directory to scan for .ui files (string or QString)
 </dd><dt><i>recurse</i></dt>
 <dd>
-&#102;&#108;&#97;&#103; &#105;&#110;&#100;&#105;&#99;&#97;&#116;&#105;&#110;&#103; &#116;&#111; &#114;&#101;&#99;&#117;&#114;&#115;&#101; &#105;&#110;&#116;&#111; &#115;&#117;&#98;&#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;&#105;&#101;&#115; (&#98;&#111;&#111;&#108;&#101;&#97;&#110;)
+flag indicating to recurse into subdirectories (boolean)
 </dd>
 </dl>
 <div align="right"><a href="#top">Up</a></div>
@@ -102,14 +102,14 @@
 <h2>compile_ui</h2>
 <b>compile_ui</b>(<i>ui_dir, ui_file</i>)
 <p>
-                &#76;&#111;&#99;&#97;&#108; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#111; &#99;&#111;&#109;&#112;&#105;&#108;&#101; &#97; &#115;&#105;&#110;&#103;&#108;&#101; .&#117;&#105; &#102;&#105;&#108;&#101;.
+                Local function to compile a single .ui file.
 </p><dl>
 <dt><i>ui_dir</i></dt>
 <dd>
-&#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#99;&#111;&#110;&#116;&#97;&#105;&#110;&#105;&#110;&#103; &#116;&#104;&#101; .&#117;&#105; &#102;&#105;&#108;&#101; (&#115;&#116;&#114;&#105;&#110;&#103;)
+directory containing the .ui file (string)
 </dd><dt><i>ui_file</i></dt>
 <dd>
-&#102;&#105;&#108;&#101; &#110;&#97;&#109;&#101; &#111;&#102; &#116;&#104;&#101; .&#117;&#105; &#102;&#105;&#108;&#101; (&#115;&#116;&#114;&#105;&#110;&#103;)
+file name of the .ui file (string)
 </dd>
 </dl>
 <div align="right"><a href="#top">Up</a></div>
@@ -118,19 +118,19 @@
 <h2>pyName</h2>
 <b>pyName</b>(<i>py_dir, py_file</i>)
 <p>
-        &#76;&#111;&#99;&#97;&#108; &#102;&#117;&#110;&#99;&#116;&#105;&#111;&#110; &#116;&#111; &#99;&#114;&#101;&#97;&#116;&#101; &#116;&#104;&#101; &#80;y&#116;&#104;&#111;&#110; &#115;&#111;&#117;&#114;&#99;&#101; &#102;&#105;&#108;&#101; &#110;&#97;&#109;&#101; &#102;&#111;&#114; &#116;&#104;&#101; &#99;&#111;&#109;&#112;&#105;&#108;&#101;&#100; .&#117;&#105; &#102;&#105;&#108;&#101;.
+        Local function to create the Python source file name for the compiled .ui file.
 </p><dl>
 <dt><i>py_dir</i></dt>
 <dd>
-&#115;&#117;&#103;&#103;&#101;&#115;&#116;&#101;&#100; &#110;&#97;&#109;&#101; &#111;&#102; &#116;&#104;&#101; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y (&#115;&#116;&#114;&#105;&#110;&#103;)
+suggested name of the directory (string)
 </dd><dt><i>py_file</i></dt>
 <dd>
-&#115;&#117;&#103;&#103;&#101;&#115;&#116;&#101;&#100; &#110;&#97;&#109;&#101; &#102;&#111;&#114; &#116;&#104;&#101; &#99;&#111;&#109;&#112;&#105;&#108;&#101; &#115;&#111;&#117;&#114;&#99;&#101; &#102;&#105;&#108;&#101; (&#115;&#116;&#114;&#105;&#110;&#103;)
+suggested name for the compile source file (string)
 </dd>
 </dl><dl>
 <dt>Returns:</dt>
 <dd>
-&#116;&#117;&#112;&#108;&#101; &#111;&#102; &#100;&#105;&#114;&#101;&#99;&#116;&#111;&#114;y &#110;&#97;&#109;&#101; (&#115;&#116;&#114;&#105;&#110;&#103;) &#97;&#110;&#100; &#115;&#111;&#117;&#114;&#99;&#101; &#102;&#105;&#108;&#101; &#110;&#97;&#109;&#101; (&#115;&#116;&#114;&#105;&#110;&#103;)
+tuple of directory name (string) and source file name (string)
 </dd>
 </dl>
 <div align="right"><a href="#top">Up</a></div>

eric ide

mercurial