Path: csiph.com!feeder.erje.net!2.us.feeder.erje.net!nntp.club.cc.cmu.edu!micro-heart-of-gold.mit.edu!bloom-beacon.mit.edu!bloom-beacon.mit.edu!panix!not-for-mail From: Grant Edwards Newsgroups: comp.lang.python Subject: Re: pygtk button right/middle click Date: Wed, 30 Mar 2016 17:44:10 +0000 (UTC) Organization: PANIX Public Access Internet and UNIX, NYC Lines: 27 Message-ID: References: NNTP-Posting-Host: 67-130-15-94.dia.static.qwest.net X-Trace: reader1.panix.com 1459359850 14245 67.130.15.94 (30 Mar 2016 17:44:10 GMT) X-Complaints-To: abuse@panix.com NNTP-Posting-Date: Wed, 30 Mar 2016 17:44:10 +0000 (UTC) User-Agent: slrn/1.0.2 (Linux) Xref: csiph.com comp.lang.python:106100 On 2016-03-30, Chris Angelico wrote: > On Thu, Mar 31, 2016 at 2:36 AM, Grant Edwards wrote: >> I'm trying to figure out how to get a pygtk button respond to >> somehting other than just a simple "left click". With a standard >> 3-button mouse, X11 provides at least 9 different "click" types, but >> the pygtk button only seems to support one of them. > > You're looking at a couple of different, but related, things. The > clicked() event means "the button was activated", which might have > been caused by a mouse event, or possibly a keyboard or other > activation. Right. > What you want is to react to other forms of mouse event. For that, > you should be able to hook the generic widget handling... So I've got to re-implement all the low-level stuff that the button already does for the "left" button (changing appearance on button-press and restoring it on button-release), calling the handler, etc. I sure seems like the batteries are missing... -- Grant Edwards grant.b.edwards Yow! Hmmm ... A hash-singer at and a cross-eyed guy were gmail.com SLEEPING on a deserted island, when ...