Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!xlned.com!feeder5.xlned.com!newsfeed.xs4all.nl!newsfeed1a.news.xs4all.nl!xs4all!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.006 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'handler': 0.05; 'preferably': 0.05; 'canvas': 0.07; 'lookup': 0.09; 'gui': 0.12; 'template': 0.14; 'thread': 0.14; '(it': 0.16; 'received:10.20.200': 0.16; 'received:charter.net': 0.16; 'threads.': 0.16; 'do,': 0.16; 'wrote:': 0.18; 'app': 0.19; 'programming': 0.22; 'header:User-Agent:1': 0.23; 'button,': 0.24; 'certainly': 0.24; 'non': 0.24; 'sort': 0.25; 'header:In-Reply- To:1': 0.27; 'received:24': 0.27; 'chris': 0.29; 'absolute': 0.30; 'code': 0.31; 'getting': 0.31; 'trivial': 0.31; 'minimal': 0.33; 'received:10.20': 0.33; 'screen': 0.34; 'tool': 0.35; 'but': 0.35; 'received:10': 0.37; 'button': 0.38; 'message-id:@gmail.com': 0.38; 'handle': 0.38; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'to:addr:python.org': 0.39; 'guarantee': 0.63; 'maximum': 0.63; 'our': 0.64; 'shop': 0.69; 'heavy': 0.81; 'grew': 0.84 X-Authority-Analysis: v=2.0 cv=F7QP7ddN c=1 sm=1 a=LkTX9YPXWU1lnSxlYEpgVg==:17 a=zewopLiEtFcA:10 a=nDghuxUhq_wA:10 a=IkcTkHD0fZMA:10 a=pGLkceISAAAA:8 a=P-mS0o5O-Lp6QeSZtkcA:9 a=QEXdDO2ut3YA:10 a=LkTX9YPXWU1lnSxlYEpgVg==:117 Date: Thu, 10 Apr 2014 08:29:44 -0500 From: Mark H Harris User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: python-list@python.org Subject: Re: threading References: <87d2gt4td2.fsf@elektro.pacujo.net> <7xha651yx2.fsf@ruckus.brouhaha.com> <877g70wg8p.fsf@elektro.pacujo.net> <87lhveobeq.fsf@elektro.pacujo.net> <87k3ayl893.fsf@elektro.pacujo.net> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 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: 18 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1397136592 news.xs4all.nl 2843 [2001:888:2000:d::a6]:56732 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:70036 On 4/9/14 12:52 PM, Chris Angelico wrote: > People with a fear of threaded programming almost certainly never grew > up on OS/2. :) I learned about GUI programming thus: Write your > synchronous message handler to guarantee that it will return in an > absolute maximum of 0.1s, preferably a lot less. If you have any sort > of heavy processing to do, spin off a thread. heh very true. Any non trivial OS/2 GUI app required threads. We had a template at our shop that we gave to noobs for copy-n-tweak. It had not only the basics for getting the canvas on the screen with a tool bar and a button, but also the minimal code required to setup the thread to handle the button event (it was a database lookup in our case).