[PyQt] PyKDE4 on FreeBSD, first impressions
Danny Pansters
danny at ricin.com
Mon Apr 7 01:10:39 BST 2008
Hi folks, and Jim (CC'd because lately it seems that seeing my post on the ML
might take a few days, hope you don't mind),
I started porting PyKDE4 to FreeBSD, using the kdelibs4 port from our "area
51" testing repo where all KDE stuff goes, most prominently the KDE4 ports.
For now I have only used and depended on kdelibs. This results in missing some
(lots of) icons that are to be taken from the oxygen theme it seems, but that
doesn't seem to be a show stopper. With only the "stock" kdelibs4 installed
pykde4 seems to default to the win95 qt style and after some modification it
will run the pykdedocs demo app.
I have split up pykde4 like this:
desktop# pkg_info | grep py25-kde4
py25-kde4-demo-4.0.2 Python bindings for KDE4, examples and demo
py25-kde4-doc-4.0.2 Python bindings for KDE4, documentation
py25-kde4-kdecore-4.0.2 Python bindings for KDE4, kdecore module
py25-kde4-kdeui-4.0.2 Python bindings for KDE4, kdeui module
py25-kde4-khtml-4.0.2 Python bindings for KDE4, khtml module
py25-kde4-kio-4.0.2 Python bindings for KDE4, kio module
py25-kde4-kparts-4.0.2 Python bindings for KDE4, kparts module
py25-kde4-kutils-4.0.2 Python bindings for KDE4, kutils module
py25-kde4-solid-4.0.2 Python bindings for KDE4, solid module
py25-kde4-uic-4.0.2 Python bindings for KDE4, pykdeuic4 UI compiler
The demo needs patches for the basePath and to add the toplevel QTreeListItems
for every module without duplicates (using doc/html/index.txt, I wonder if
another should be used instead, this one also has the same info four times
sequentially).
for line in m:
if lines and line.startswith("m:kdecore"):
break
else:
lines.append(line)
m.close()
for line in lines:
....
It then starts, and the tutorials and samples -- where present-- do work. I
noticed that when trying to add bookmark for e.g. sip or PyQt docs, it
crashes (bus error) when the actual loading is to be done (kio?). Loading a
web page works. This may be a freebsd/kde4 problem.
I also see the kdecore entry in the TreeList being 15 lines high, with 15
identical kde.png icons (Icons are off anyway, it seems to be using kde3
icons -- kde3 is installed here, for kde4 only libs so far -- but most work
or show the "unknown" icon, much complaints on the console though). The other
modules dont show that only kdecore. I don't really understand this, but I
think it has to do with "item1" being ambigious.
Other bugs I noticed is that pykdedocs should create the full
~/.kde4/share/apps/pykdedocs paths if they don't exist, as well as
~/.kde4/share/config/pykdedocsrc. The latter is never used though, instead it
uses ~/.kde/share/config/pykdedocsrc which also seems like a bug.
Also, there seems to be a rather severe bug in computePaths():
basePath = str (General.readEntry ("BasePath", sys.path [0]))
should be:
basePath = str (General.readEntry ("BasePath", sys.path [-1]))
if you have appended to sys.path earlier (not inserted).
Best regards.
Dan
More information about the PyQt
mailing list