[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    Re: [PyKDE] signatures for qt-classes?
From:       Gerard Vermeulen <gvermeul () grenoble ! cnrs ! fr>
Date:       2003-09-17 7:50:13
[Download RAW message or body]

On Mon, 15 Sep 2003 21:05:03 +0200
Detlev Offenbach <detlev@die-offenbachs.de> wrote:

> Am Montag, 15. September 2003 09:11 schrieb Gerard Vermeulen:
[ .. ]
> >
> > Or generate part of the doc-strings automatically, for instance
> >
> > >>> print filter.__doc__
> >
> > filter(function or None, sequence) -> list, tuple, or string
> >
> > Return those items of sequence for which function(item) is true.  If
> > function is None, return the items that are true.  If sequence is a
> > tuple or string, return the same type, else return a list.
> >
> >
> > here the first line is used by Idle as a tooltip hint (this is a
> > feature which seems to be missing from Eric-3.2).
> 
> Eric uses the QScintilla tooltips. Eric just initializes them and 
> QScintilla is displaying the tooltips. If you think that should be 
> added, please forward a QScintilla feature request to Phil.
> 
Yes, I admit I did not look careful enough. Apologies.

On the other hand, I had to fix gen_pyqt_api.py (patch attached).
Also, gen_python_api.py chokes on my Python setup (probably because of a
module that imports itself).  What to do? Disable the offending module
or sent it to fix gen_python_api.py (if you want, you will get all my
offending modules if I find more). 

Idle's interpreter-based approach of handling tooltips has less problems
with 'unconventional' modules and does not require regeneration of API file
after (des)installation of Python modules.

It is up to you and Phil to decide if it is worth the trouble to change
the QScintilla/Eric approach (yes, this is a feature request).


A few details with respect to the user interface of the API dialog:
(1) Why isn't it possible to select all *.api files in a directory at once?
(2) Why do I need to press on Add after having pressed on Open previously (to
    me this is superfluous and therefore annoying)?
(3) If you want to leave (2) as it is, why is the Add button not next to
    the ... button (clumsy me is being forced to make looong mouse movements
    and has a tendency to click OK instead of Add)?


Gerard

 


["eric-snapshot-20030914.patch" (application/octet-stream)]

--- eric-snapshot-20030914/eric/Tools/gen_pyqt_api.py.mgv	Wed Sep 17 06:20:16 2003
+++ eric-snapshot-20030914/eric/Tools/gen_pyqt_api.py	Wed Sep 17 06:29:54 2003
@@ -63,9 +63,25 @@
 else:
     plattag = "WS_X11"
     sip = "sip"
-    
-qversion = qVersion()
-qttag = "Qt_%s" % qversion.replace('.', '_')
+
+# Qt-snapshots return a qVersion() string longer than 5 chars
+qversion = qVersion()[:5]
+# some Qt-versions have no tag
+qttag = {
+    '3.0.0': 'Qt_3_0_0',
+    '3.0.1': 'Qt_3_0_1',
+    '3.0.2': 'Qt_3_0_2',
+    '3.0.3': 'Qt_3_0_2',
+    '3.0.4': 'Qt_3_0_4',
+    '3.0.5': 'Qt_3_0_5',
+    '3.0.6': 'Qt_3_0_6',
+    '3.0.7': 'Qt_3_0_6',
+    '3.1.0': 'Qt_3_1_0',
+    '3.1.1': 'Qt_3_1_1',
+    '3.1.2': 'Qt_3_1_2',
+    '3.2.0': 'Qt_3_2_0',
+    '3.2.1': 'Qt_3_2_0',
+    }.get(qversion)
 
 if not os.path.isdir(sipdir):
     print "The directory (%s) containing the sipfiles does not exist. Aborting..." % sipdir


_______________________________________________
PyKDE mailing list    PyKDE@mats.imk.fraunhofer.de
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic