Re: [PyQt] Fwd: translation of ui

2011-07-02 Thread Thorsten Kampe
* Yasar Arabaci (Fri, 1 Jul 2011 12:52:09 +0300) > I got it working but wanted to get an affimation, what do you think of > this approach? > > if __name__ == "__main__": > from locale import getlocale > from os.path import exists > app = QtGui.QApplication(sys.argv) > if getlocale(

Re: [PyQt] PyQt install on suse 11 SP1

2010-12-05 Thread Thorsten Kampe
* Anup Joshi (Sun, 5 Dec 2010 17:14:51 +0530) > I am trying to install pyQT on suse linux ( 11 sp1) . I have already > installed Qt. When I run configure.py in the PyQt folder, I get the > following error message: Use the one that is available via YaST (python-qt4-4.6.2) or the one available via

[PyQt] Translations failing when not using "self" for the instance

2010-12-03 Thread Thorsten Kampe
Hi, when using other names for the self idiom referring to the current instance (like "inst" for example - see [1]), the application is not correctly translated. If I open the generated ts file in Qt Linguist it shows two "contexts" ("MainWindow" and "inst") instead of just one ("MainWindow) w

Re: [PyQt] Python 3 import error

2010-12-03 Thread Thorsten Kampe
I just wanted to say that the amount of knowledgeable, fast help I received here yesterday was incredible. In this thread I experienced about six or so different problems porting a script to Python 3 and each one of that was immediately solved showing immense knowledge not just about PyQt itsel

Re: [PyQt] Python 3 import error

2010-12-02 Thread Thorsten Kampe
* Hans-Peter Jansen (Thu, 2 Dec 2010 20:16:13 +0100) > > > sip.setapi('QVariant', 2) Unfortunately, when I set "sip.setapi('QVariant', 2)" then I can't run the application as stand-alone Pyinstaller[1] executable (neither under Windows nor Linux): ValueError: API 'QVariant' has already been set

Re: [PyQt] Python 3 import error

2010-12-02 Thread Thorsten Kampe
* Hans-Peter Jansen (Thu, 2 Dec 2010 15:47:28 +0100) > On Thursday 02 December 2010, 14:25:21 Thorsten Kampe wrote: > > Okay, if I omit the ".toByteArray()", then the application starts > > with Python 3 - but it doesn't work with Python 2 anymore: > > >

Re: [PyQt] Python 3 import error

2010-12-02 Thread Thorsten Kampe
* Hans-Peter Jansen (Thu, 2 Dec 2010 15:47:28 +0100) > On Thursday 02 December 2010, 14:25:21 Thorsten Kampe wrote: > > Okay, if I omit the ".toByteArray()", then the application starts > > with Python 3 - but it doesn't work with Python 2 anymore: > > >

Re: [PyQt] Python 3 import error

2010-12-02 Thread Thorsten Kampe
* Phil Thompson (Thu, 02 Dec 2010 12:39:58 +) > On Thu, 2 Dec 2010 13:17:22 +0100, Thorsten Kampe > wrote: > > So the ImportError is gone. Adding -py3 to pyrcc4 yields: > > Traceback (most recent call last): > > File "my_application.pyw", line 63, in

Re: [PyQt] Python 3 import error

2010-12-02 Thread Thorsten Kampe
* Hans-Peter Jansen (Thu, 2 Dec 2010 12:49:17 +0100) > On Thursday 02 December 2010, 12:24:54 Thorsten Kampe wrote: > > I'm trying to port a PyQt4 application from Python 2 to Python 3. > > The application works fine with the latest Python 2 (2.7.1) but not > > with Pytho

Re: [PyQt] Python 3 import error

2010-12-02 Thread Thorsten Kampe
* Phil Thompson (Thu, 02 Dec 2010 11:31:13 +) > On Thu, 2 Dec 2010 12:24:54 +0100, Thorsten Kampe > wrote: > > I'm trying to port a PyQt4 application from Python 2 to Python 3. The > > application works fine with the latest Python 2 (2.7.1) but not with > > Pyt

[PyQt] Python 3 import error

2010-12-02 Thread Thorsten Kampe
Hi, I'm trying to port a PyQt4 application from Python 2 to Python 3. The application works fine with the latest Python 2 (2.7.1) but not with Python 3.1.2: Traceback (most recent call last): File "my_application.pyw", line 10, in import resource.ui File "F:\[path]\resource\ui.py", lin

Re: [PyQt] Overcoming slow startup

2010-04-11 Thread Thorsten Kampe
* Thorsten Kampe (Sun, 11 Apr 2010 22:27:04 +0200) > I wrote a simple application that displays output of an external CLI > tool in a QTreeWidget. In a normal setup, the external tool will take > less than one minute to terminate. OOOPS, I meant "In a normal setup, the external

[PyQt] Overcoming slow startup

2010-04-11 Thread Thorsten Kampe
Hi, I wrote a simple application that displays output of an external CLI tool in a QTreeWidget. In a normal setup, the external tool will take less than one minute to terminate. Unfortunately - depending on the setup of the external application - the external tool may also take between thirty

[PyQt] QTreeWidget and Qt Designer

2010-04-11 Thread Thorsten Kampe
Two short questions about creating QTreeWidgets with Qt Designer: 1. When I resize (increase the height of) my main window the tree widget "inside" only increases up to a certain size. After that the tree widget does not increase in size anymore and I get a (useless) grey border between the tre

[PyQt] QTreeWidget usage

2010-04-06 Thread Thorsten Kampe
Hi, while trying to read the Qt documentation, I came across the following: "In its simplest form, a tree widget can be constructed in the following way: QTreeWidget *treeWidget = new QTreeWidget(); treeWidget->setColumnCount(1); QList items; for (int i = 0; i < 10; ++i) items.append(new QT

Re: [PyQt] Simple Qt application

2010-04-04 Thread Thorsten Kampe
The overall structure is now clear to me: gather the "external data" via subprocess or QProcess and display it via QTreeView or QTreeWidget. Mark Summerfield's book also contains chapters "Using the Convenience Item Widgets" and "Representing Tabular Data in Trees" (including example code) whic

[PyQt] Simple Qt application

2010-04-02 Thread Thorsten Kampe
Hi, I want to create a simple application that displays hierarchical output. The idea comes from an application called "Slp Snoop" (http://www.novell.com/communities/node/782/slpsnoop%20utility) which doesn't work with Vista and above anymore. Basically the application should execute a CLI com

[PyQt] Re: PyQt4 and Qt plugins (imageformats, etc.) fully supported now

2009-02-24 Thread Thorsten Kampe
* Giovanni Bajo (Mon, 23 Feb 2009 12:33:11 +0100) > I've just added a new feature to PyInstaller: a module hook is now > able to specify additional data files that are needed for the module > to work correctly. Those data files are automatically collected when > using --onedir, or bundled within th

[PyQt] Re: LGPL license.

2009-02-11 Thread Thorsten Kampe
* Jim Bublitz (Tue, 10 Feb 2009 15:13:51 -0800) > I've never minded people using my software for free - even > commercially. I just hate it when they whine about software being > free, but not on terms where they can profit enormously from other > people's work. It's the whining, not the profiting,

[PyQt] Re: Preferred method to package PyQt-powered apps into .exes

2009-01-17 Thread Thorsten Kampe
* eliben (Sat, 17 Jan 2009 06:55:58 -0800 (PST)) > I'll want to package my applications into .exe files, on Windows. > Which of the existing options in the Python exe-packaging world works > best for PyQt? PyInstaller? Py2exe? Something else? You can try them all but probably Pyinstaller (grab the

[PyQt] Re: Re: Re: Deploying from Linux to Windows

2009-01-17 Thread Thorsten Kampe
* Doug Hackworth (Fri, 16 Jan 2009 14:44:57 -0600) > > ...Regarding that, doesn't "import" try to find .py files? Yes, but not exclusively (also pyc, pyo, pyd, and __init__. > There is no Lib/site-packages/PyQt4.py , so is that a problem? The path > Lib/site-packages/PyQt4 that got installed i

[PyQt] Re: Re: Deploying from Linux to Windows

2009-01-16 Thread Thorsten Kampe
* Doug Hackworth (Fri, 16 Jan 2009 14:04:50 -0600) > >> open a Python prompt and try to import any module, then try to > >> import PyQt4. > > > > Yep, did that -- it works just fine. > > Scratch that, I told you the wrong thing. The following is correct: > > 1. If I open a Python prompt and

[PyQt] Re: Re: Deploying from Linux to Windows

2009-01-16 Thread Thorsten Kampe
* piotr mali?ski (Fri, 16 Jan 2009 20:16:03 +0100) > Well, I had to do it for ActivePython. Maybe vanilla Python sets them No, Python has internal defaults. You need to set PYTHONHOME only if you would want to change the default of Lib to another directory and PYTHONPATH only to if you want

[PyQt] Re: Licensing for PyQt?

2009-01-16 Thread Thorsten Kampe
* Phil Thompson (Fri, 16 Jan 2009 14:03:50 +) > On Fri, 16 Jan 2009 13:37:47 + (UTC), David F > wrote: > > After the announcement that Qt 4.5 will be released as LGPL, > > has it been decided if PyQt will do the same? I have seen > > some speculation but no actual announcement. > > > > I

[PyQt] Re: Deploying from Linux to Windows

2009-01-16 Thread Thorsten Kampe
* piotr mali?ski (Fri, 16 Jan 2009 19:38:13 +0100) > you need to add paths to folder with installed python to PYTHONPATH > and PYTHONHOME in Control center / System / Advanced / System Paths No, he doesn't. Thorsten ___ PyQt mailing listPyQt@riverb

[PyQt] Re: Deploying from Linux to Windows

2009-01-16 Thread Thorsten Kampe
* Doug Hackworth (Fri, 16 Jan 2009 11:53:45 -0600) > I have developed a PyQt4 application on my Ubuntu machine, and itworks > fine, no problems. Now I want another user to be able to use it on his > Windows XP machine, so on his computer I do the following, in this > order: > > 1. Install Python

[PyQt] Re: Problem with apps build with Py2exe

2009-01-09 Thread Thorsten Kampe
* piotr mali?ski (Fri, 9 Jan 2009 10:07:00 +0100) > > Some MS Windows users have problem running PyQt4 applications - exe/binary > builds made with Py2exe. The problem is that Windows displays a message like > this (translation from Polish) "This application can't be run as it > configuration is w

[PyQt] Re: Re: PyQt menu and tool tip font

2008-10-26 Thread Thorsten Kampe
* Baz Walter (Sat, 25 Oct 2008 19:22:14 +0100) > Thorsten Kampe wrote: > > I've also tried changing the font with qtconfig. There I have DejaVu > > Sans 12 (which I probably set in the KDE Control Center). Changing > > that also doesn't make a difference with Py

[PyQt] Re: Re: PyQt menu and tool tip font

2008-10-25 Thread Thorsten Kampe
* Baz Walter (Sat, 25 Oct 2008 19:22:14 +0100) > Thorsten Kampe wrote: > > I've also tried changing the font with qtconfig. There I have DejaVu > > Sans 12 (which I probably set in the KDE Control Center). Changing that > > also doesn't make a difference with Py

[PyQt] Re: PyQt menu and tool tip font

2008-10-25 Thread Thorsten Kampe
* Mark Summerfield (Sat, 25 Oct 2008 09:01:39 +0100) > On 2008-10-24, Thorsten Kampe wrote: > > PyQt applications (like Sandbox[1]) on Linux have a horrible looking and > > much too small font for the menus, tool tips and for the status bar - > > while on Windows it looks tot

[PyQt] PyQt menu and tool tip font

2008-10-24 Thread Thorsten Kampe
Hi, not sure whether this is really a PyQt thing but I'll ask anyway: PyQt applications (like Sandbox[1]) on Linux have a horrible looking and much too small font for the menus, tool tips and for the status bar - while on Windows it looks totally normal (like all other applications). Where or

[PyQt] Re: Re: Internationalization and PyQt

2008-10-06 Thread Thorsten Kampe
* Giovanni Bajo (Sun, 05 Oct 2008 19:24:17 +0200) > On dom, 2008-10-05 at 18:19 +0200, Thorsten Kampe wrote: > > * Giovanni Bajo (Sun, 05 Oct 2008 12:46:15 +0200) > > > On sab, 2008-10-04 at 20:31 +0200, Thorsten Kampe wrote: > > > > So why does my code (that does n

[PyQt] Re: Internationalization and PyQt

2008-10-05 Thread Thorsten Kampe
* Giovanni Bajo (Sun, 05 Oct 2008 12:46:15 +0200) > On sab, 2008-10-04 at 20:31 +0200, Thorsten Kampe wrote: > > So why does my code (that does not query the locale and choose the > > right tranlation file according to the locale) work? > > Why it should not? QTranslator

[PyQt] Re: Internationalization and PyQt

2008-10-05 Thread Thorsten Kampe
* Giovanni Bajo (Sun, 05 Oct 2008 12:46:15 +0200) > On sab, 2008-10-04 at 20:31 +0200, Thorsten Kampe wrote: > > So why does my code (that does not query the locale and choose the > > right tranlation file according to the locale) work? > > Why it should not? QTranslator

[PyQt] Internationalization and PyQt

2008-10-04 Thread Thorsten Kampe
Hi, I've "upgraded" a PyQt demo application of mine so it includes not only a translation of the user interface in German but also in French. My problem is that it simply works but I think it shouldn't (no don't laugh). This is the code in my demo application (called my_application) that does

[PyQt] Re: PyQt 4.4.2 GPL installer / missing DLL

2008-05-24 Thread Thorsten Kampe
* Python(x,y) (Sat, 24 May 2008 09:33:00 +0200) > Phil Thompson a écrit : > > On Friday 23 May 2008 6:47:11 pm Pierre Raybaut wrote: > >> About this missing DLL issue, the main difference between the 4.3.3 and > >> 4.4.x Windows installer releases seems to be about the .dll management. > >> Apparen

[PyQt] Re: PyQt app not showing help and about box - 2 files [1/1]

2008-05-22 Thread Thorsten Kampe
* Phil Thompson (Thu, 22 May 2008 11:28:03 +0100) > On Thursday 22 May 2008 11:09:30 am Thorsten Kampe wrote: > > I've got a rather weird issue with an application. The program used to > > work fine but I did not test it for about six months. > > > > Now (maybe

[PyQt] PyQt app not showing help and about box - 2 files [1/1]

2008-05-22 Thread Thorsten Kampe
Hi, I've got a rather weird issue with an application. The program used to work fine but I did not test it for about six months. Now (maybe not connected) after updating to PyQt 4.4 I can't see the help and about box in this app on Linux (PyQt 4.4.0) while on Windows (PyQt 4.4.2) everything is

[PyQt] Re: PyQt app not displaying icons from ui file

2008-05-22 Thread Thorsten Kampe
* Thorsten Kampe (Wed, 21 May 2008 20:56:40 +0200) > I've got a rather weird issue with a (more or less proof of concept for > me) application. The program used to work fine but I did not start it > for more about six months. > > Now (maybe not directly connected) after up

[PyQt] Re: PyQt app not displaying icons from ui file - 2 files [1/1]

2008-05-22 Thread Thorsten Kampe
* Gustavo A. D??az (Wed, 21 May 2008 16:18:54 -0300) > This is supposed to be fixed with PyQt4.4.2 if i am not wrong, cause > same problem was happening to me, was reported here in the ML, and was > fixed in that release. > Maybe you should try to build that one. It's not available for my distribu

[PyQt] PyQt app not displaying icons from ui file

2008-05-21 Thread Thorsten Kampe
Hi, I've got a rather weird issue with a (more or less proof of concept for me) application. The program used to work fine but I did not start it for more about six months. Now (maybe not directly connected) after updating to PyQt 4.4 I can't see any icons in this app on Linux while on Windows

[PyQt] Re: running pyqt application on win*

2007-11-28 Thread Thorsten Kampe
* Giovanni Bajo (Wed, 28 Nov 2007 00:45:08 +0100) > On Mon, 2007-11-26 at 21:32 +0200, Markos Gogoulos wrote: > > there's py2exe to make windows executables, without the need to ship > > python or qt. Py2exe is easy to use and there's some cool > > documentation regarding pyqt, check > > http://ww

[PyQt] Re: running pyqt application on win*

2007-11-27 Thread Thorsten Kampe
* Jochen Georges (Mon, 26 Nov 2007 20:20:15 +0100) > i'm new to pyqt, on linux i wrote some little pyqt-applications for testing. > > how can i run them under win* ? > > PyQt-win-gpl-4.3.1.zip07MB > python-2.5.1.msi 11MB > qt-win-opensource-src

[PyQt] Re: PyQt book "Rapid GUI Programming with Python and Qt" now available

2007-10-25 Thread Thorsten Kampe
* Andreas Pakulat (Thu, 25 Oct 2007 15:36:43 +0200) > On 25.10.07 13:33:54, Mark Summerfield wrote: > > Of course, I don't have any control over the pricing, and this isn't > > just about my particular book---my guess is that outside the US > > booksellers sell for whatever they think the market wi

[PyQt] Re: QMessageBox with unicode text fails

2007-10-25 Thread Thorsten Kampe
* alteo_gange (Thu, 25 Oct 2007 14:08:28 +0200) > Le jeudi 25 octobre 2007, David Boddie a écrit : > > 3. The default encoding isn't UTF-8 > > What a shame! Wait for Python 3... ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankc

[PyQt] Re: Newbie needs help in installing PyQt

2007-10-25 Thread Thorsten Kampe
* Dick Moores (Thu, 25 Oct 2007 07:25:32 -0700) > says: > [...] > So I downloaded "PyQt v4 GPL for Windows and Python v2.5" using the > link just below the above. [...] And much of the documentation > "can't be found", or words to that effect.

[PyQt] Re: Have to close dialog boxes twice

2007-10-21 Thread Thorsten Kampe
* David Boddie (Sun, 21 Oct 2007 18:29:29 +0200) > On Sun Oct 21 09:33:32 BST 2007, Thorsten Kampe wrote: > > Now I tried to separate the layout from the code logic by using Qt > > Designer and generating and importing an Ui file. This works fine, > > too. Except that with t

[PyQt] Have to close dialog boxes twice

2007-10-21 Thread Thorsten Kampe
Hi, I've created a simple application with exit, help and about actions that are available via menu and via toolbars. This application works fine. Now I tried to separate the layout from the code logic by using Qt Designer and generating and importing an Ui file. This works fine, too. Except

[PyQt] Re: Re: Internationalization problem

2007-10-20 Thread Thorsten Kampe
* Andreas Pakulat (Sat, 20 Oct 2007 10:38:08 +0200) > On 20.10.07 03:13:08, Thorsten Kampe wrote: > > * Andreas Pakulat (Sat, 20 Oct 2007 00:40:04 +0200) > > > On 19.10.07 21:47:58, Thorsten Kampe wrote: > > > > reading through Mark Summerfield's book I've

[PyQt] Re: Internationalization problem

2007-10-19 Thread Thorsten Kampe
* Andreas Pakulat (Sat, 20 Oct 2007 00:40:04 +0200) > On 19.10.07 21:47:58, Thorsten Kampe wrote: > > reading through Mark Summerfield's book I've tried to localise my > > appliation. This works fine for my own translation but not for the one > > >from Trollte

[PyQt] Internationalization problem

2007-10-19 Thread Thorsten Kampe
[latest PyQt] Hi, reading through Mark Summerfield's book I've tried to localise my appliation. This works fine for my own translation but not for the one from Trolltech (qt_de.qm). This means that for instance all my menus are in German but the close, maximize, minimize and restore buttons in

[PyQt] Re: Help with help action

2007-09-27 Thread Thorsten Kampe
* Mark Summerfield (Thu, 27 Sep 2007 08:45:59 +0100) > On 2007-09-26, Thorsten Kampe wrote: > > I'm trying to teach myself GUI programmming with the help of the new > > PyQt book and the examples from the PyQt package. Although I've been > > doing Python for five yea

[PyQt] Help with help action

2007-09-26 Thread Thorsten Kampe
Hi, I'm trying to teach myself GUI programmming with the help of the new PyQt book and the examples from the PyQt package. Although I've been doing Python for five years I have a hard time doing OOP stuff. Frankly, I never know when and where to put this "self" thing. My script (see below) wor

[PyKDE] Re: How to use "kdialog"

2004-09-22 Thread Thorsten Kampe
* Jim Bublitz (2004-09-21 21:45 +0200) > On Tuesday 21 September 2004 12:10, Thorsten Kampe wrote: >> I want to integrate some simple message boxes in a Python script. Of >> course I could use EasyGUI (www.ferg.org) but the native KDE look is >> much nicer. > >&

[PyKDE] How to use "kdialog"

2004-09-21 Thread Thorsten Kampe
I want to integrate some simple message boxes in a Python script. Of course I could use EasyGUI (www.ferg.org) but the native KDE look is much nicer. So I installed PyKDE but I couldn't figure out how to code this simple task. Could anyone tell me the equivalent Python code to '"kdialog --msgbox "

[PyKDE] Re: GUI wrapper for modules

2004-05-30 Thread Thorsten Kampe
* Phil Thompson (2004-05-30 12:05 +0100) > On Sunday 30 May 2004 10:48 am, Thorsten Kampe wrote: >> For my first GUI Python application I thought of a wrapper for my >> utility modules I have already written. Kind of "EasyGUI"[1] style but >> much less sophist

[PyKDE] GUI wrapper for modules

2004-05-30 Thread Thorsten Kampe
For my first GUI Python application I thought of a wrapper for my utility modules I have already written. Kind of "EasyGUI"[1] style but much less sophisticated. I've got a module "test.py" in $PYTHONPATH containing one function: def multiply_by_two(x): return x * 2 Now the GUI app should do

[PyKDE] GUI and PyQt - how to begin?

2004-05-30 Thread Thorsten Kampe
I'm trying to wrap my head around my first GUI program with PyQt, but I still have big problems with the GUI "event driven" paradigm and the OOP terminlogy. I tried to study Boudewijn Rempt's "GUI Programming with Python: QT Edition" but it is "too much" for me. So how and where to start? I bought