Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!ecngs!feeder2.ecngs.de!newsfeed.freenet.ag!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.018 X-Spam-Evidence: '*H*': 0.96; '*S*': 0.00; 'subject:Python': 0.05; 'behavior,': 0.09; 'command-line': 0.09; 'from:addr:torriem': 0.16; 'from:name:michael torrie': 0.16; 'wrote:': 0.17; 'app': 0.19; 'written': 0.20; 'flags': 0.22; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'am,': 0.27; 'question': 0.27; 'there.': 0.28; 'lines': 0.28; 'skip:q 20': 0.29; 'function': 0.30; 'code': 0.31; 'certain': 0.33; 'to:addr:python-list': 0.33; 'similar': 0.35; 'received:org': 0.36; 'but': 0.36; 'message- id:@gmail.com': 0.36; 'should': 0.36; 'author': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'received:192': 0.39; 'received:192.168': 0.40; 'header:Received:5': 0.40; 'rusi': 0.91 X-Virus-Scanned: amavisd-new at torriefamily.org Date: Mon, 16 Jul 2012 07:56:19 -0600 From: Michael Torrie User-Agent: Mozilla/5.0 (X11; Linux i686; rv:10.0.5) Gecko/20120601 Thunderbird/10.0.5 MIME-Version: 1.0 To: python-list@python.org Subject: Re: Python and Qt4 Designer References: <63ac761b-a0a2-4d77-a3ca-f93069fab82a@s1g2000vbj.googlegroups.com> <1bb0d4df-3937-4d5f-aedb-734e0c54eb85@f9g2000pbd.googlegroups.com> <500255BA.5080102@gmail.com> <5002782D.7080009@swing.be> In-Reply-To: <5002782D.7080009@swing.be> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 22 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1342446995 news.xs4all.nl 6914 [2001:888:2000:d::a6]:34575 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:25417 On 07/15/2012 01:58 AM, Vincent Vande Vyvre wrote: > Rusi is not the op, and his question is about these lines > > app = None > if ( not app ): Yeah that's a no-op. The original author of that code is clearly confused there. > > not this one > > app = QtGui.QApplication([]) > > which should be written like this > > app = QtGui.QApplication(sys.argv) Yeah. The QApplication not only is the main engine, but it also parses the command-line for certain flags that influence Qt's behavior, similar to gtk's main function that also parses command-line flags (specific to gtk's operation).