[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    Re: [PyQt] How to override mousePressEvent for an existing
From:       Dov Grobgeld <dov.grobgeld () gmail ! com>
Date:       2009-07-30 21:43:10
Message-ID: dc666480907301443m30c45df9q7c6d89840438872b () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Great! Though I'll have to wait a while until Fedora PyQt is updated to 4.5=
,
it seems.

Dov

2009/7/30 Phil Thompson <phil@riverbankcomputing.com>

> On Thu, 30 Jul 2009 21:26:42 +0300, Dov Grobgeld <dov.grobgeld@gmail.com>
> wrote:
> > Thanks! It seems like this is exactly what I was looking for.
> >
> > I have to say it is quite annoying that there is neither any compile ti=
me
> > nor any run time error reported for errors in the signal signatures.
> >
> > Regards,
> > Dov
>
> Use the new-style connection API...
>
> self.button.customContextMenuRequested.connect(self.context_menu)
>
> Phil
>
> > 2009/7/30 Henning Schr=F6der <henning.schroeder@gmail.com>
> >
> >> On Thu, Jul 30, 2009 at 7:10 PM, Dov Grobgeld<dov.grobgeld@gmail.com>
> >> wrote:
> >>
> >> > Regarding contextMenuPolicy, how would you use that. I tried the
> >> following,
> >> > but it didn't work...
> >> >   [..]
> >> >         self.connect(self.button,
> >> > QtCore.SIGNAL('customContextMenuRequested()'), self.context_menu)
> >> You always have  to use the complete signature. Please try:
> >> SIGNAL('customContextMenuRequested(const QPoint&)')
> >>
> >> Henning
> >>
>

[Attachment #5 (text/html)]

<div dir="ltr">Great! Though I&#39;ll have to wait a while until Fedora PyQt is \
updated to 4.5, it seems.<br> <br>Dov<br><br><div class="gmail_quote">2009/7/30 Phil \
Thompson <span dir="ltr">&lt;<a \
href="mailto:phil@riverbankcomputing.com">phil@riverbankcomputing.com</a>&gt;</span><br><blockquote \
class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt \
0pt 0.8ex; padding-left: 1ex;"> On Thu, 30 Jul 2009 21:26:42 +0300, Dov Grobgeld \
&lt;<a href="mailto:dov.grobgeld@gmail.com">dov.grobgeld@gmail.com</a>&gt;<br> \
wrote:<br> <div class="im">&gt; Thanks! It seems like this is exactly what I was \
looking for.<br> &gt;<br>
&gt; I have to say it is quite annoying that there is neither any compile time<br>
&gt; nor any run time error reported for errors in the signal signatures.<br>
&gt;<br>
&gt; Regards,<br>
&gt; Dov<br>
<br>
</div>Use the new-style connection API...<br>
<br>
self.button.customContextMenuRequested.connect(self.context_menu)<br>
<font color="#888888"><br>
Phil<br>
</font><div><div></div><div class="h5"><br>
&gt; 2009/7/30 Henning Schröder &lt;<a \
href="mailto:henning.schroeder@gmail.com">henning.schroeder@gmail.com</a>&gt;<br> \
&gt;<br> &gt;&gt; On Thu, Jul 30, 2009 at 7:10 PM, Dov Grobgeld&lt;<a \
href="mailto:dov.grobgeld@gmail.com">dov.grobgeld@gmail.com</a>&gt;<br> &gt;&gt; \
wrote:<br> &gt;&gt;<br>
&gt;&gt; &gt; Regarding contextMenuPolicy, how would you use that. I tried the<br>
&gt;&gt; following,<br>
&gt;&gt; &gt; but it didn&#39;t work...<br>
&gt;&gt; &gt;   [..]<br>
&gt;&gt; &gt;         self.connect(self.button,<br>
&gt;&gt; &gt; QtCore.SIGNAL(&#39;customContextMenuRequested()&#39;), \
self.context_menu)<br> &gt;&gt; You always have  to use the complete signature. \
Please try:<br> &gt;&gt; SIGNAL(&#39;customContextMenuRequested(const \
QPoint&amp;)&#39;)<br> &gt;&gt;<br>
&gt;&gt; Henning<br>
&gt;&gt;<br>
</div></div></blockquote></div><br><div style="display: none;" \
id="divCleekiAttrib"></div></div>



_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic