Capturing window events

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Capturing window events

Alexandre Bergel-4
Dear All,

Is there an easy way to capture windows related events such as  
resizing and hiding ?
I do not have the feeling this is supported currently. One way to  
implement this I guess, is to redefine the method  
SystemWindow>>extent: to emit an instance of a subclass of  
Announcement, which could be named MorphicWindowResize.

I plan to do this for Mondrian, but maybe this is of an interest to  
GUI guys.

Any comment before I proceed?

Cheers,
Alexandre

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.






_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Capturing window events

David Röthlisberger-2
Hi Alex,

> Is there an easy way to capture windows related events such as  
> resizing and hiding ?

I was seeking for the same things just last week...
For collapsing and expanding using the tool buttons in the window's task bar, the
methods #collapse and #expand of SystemWindow get executed.

Resizing and moving with the mouse is more difficult to intercept.
The best way I found was to hook into #doFastWindowReframe: (resizing) and
#doFastFrameDrag: (moving).
I had to override these methods to send a notification to my stuff. Not the best way,
so enhancing SystemWindow to announce resizing, moving, maybe also expanding,
collapsing, closing, etc. would be better.

David

> I do not have the feeling this is supported currently. One way to  
> implement this I guess, is to redefine the method  
> SystemWindow>>extent: to emit an instance of a subclass of  
> Announcement, which could be named MorphicWindowResize.
>
> I plan to do this for Mondrian, but maybe this is of an interest to  
> GUI guys.
>
> Any comment before I proceed?
>
> Cheers,
> Alexandre
>


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Capturing window events

Alexandre Bergel
Ok. I will propose something in the next few days.

Alexandre


On 11 May 2009, at 11:14, David Röthlisberger wrote:

> Hi Alex,
>
>> Is there an easy way to capture windows related events such as
>> resizing and hiding ?
>
> I was seeking for the same things just last week...
> For collapsing and expanding using the tool buttons in the window's  
> task bar, the
> methods #collapse and #expand of SystemWindow get executed.
>
> Resizing and moving with the mouse is more difficult to intercept.
> The best way I found was to hook into #doFastWindowReframe:  
> (resizing) and
> #doFastFrameDrag: (moving).
> I had to override these methods to send a notification to my stuff.  
> Not the best way,
> so enhancing SystemWindow to announce resizing, moving, maybe also  
> expanding,
> collapsing, closing, etc. would be better.
>
> David
>
>> I do not have the feeling this is supported currently. One way to
>> implement this I guess, is to redefine the method
>> SystemWindow>>extent: to emit an instance of a subclass of
>> Announcement, which could be named MorphicWindowResize.
>>
>> I plan to do this for Mondrian, but maybe this is of an interest to
>> GUI guys.
>>
>> Any comment before I proceed?
>>
>> Cheers,
>> Alexandre
>>
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.






_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Capturing window events

Alexandre Bergel
In reply to this post by David Röthlisberger-2
Hi David and Friends,
Morphic-Alexandre_Bergel.301 in PharoInbox extends SystemWindow with  
emitting announcement. The fix also contains a hierarchy of  
announcements
If someone would like to comment on it.

Cheers,
Alexandre


On 11 May 2009, at 11:14, David Röthlisberger wrote:

> Hi Alex,
>
>> Is there an easy way to capture windows related events such as
>> resizing and hiding ?
>
> I was seeking for the same things just last week...
> For collapsing and expanding using the tool buttons in the window's  
> task bar, the
> methods #collapse and #expand of SystemWindow get executed.
>
> Resizing and moving with the mouse is more difficult to intercept.
> The best way I found was to hook into #doFastWindowReframe:  
> (resizing) and
> #doFastFrameDrag: (moving).
> I had to override these methods to send a notification to my stuff.  
> Not the best way,
> so enhancing SystemWindow to announce resizing, moving, maybe also  
> expanding,
> collapsing, closing, etc. would be better.
>
> David
>
>> I do not have the feeling this is supported currently. One way to
>> implement this I guess, is to redefine the method
>> SystemWindow>>extent: to emit an instance of a subclass of
>> Announcement, which could be named MorphicWindowResize.
>>
>> I plan to do this for Mondrian, but maybe this is of an interest to
>> GUI guys.
>>
>> Any comment before I proceed?
>>
>> Cheers,
>> Alexandre
>>
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.






_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Capturing window events

Alexandre Bergel
> Morphic-Alexandre_Bergel.302
is in PharoInbox

Cheers,
Alexandre


On 11 May 2009, at 22:24, Alexandre Bergel wrote:

> Hi David and Friends,
> Morphic-Alexandre_Bergel.301 in PharoInbox extends SystemWindow with
> emitting announcement. The fix also contains a hierarchy of
> announcements
> If someone would like to comment on it.
>
> Cheers,
> Alexandre
>
>
> On 11 May 2009, at 11:14, David Röthlisberger wrote:
>
>> Hi Alex,
>>
>>> Is there an easy way to capture windows related events such as
>>> resizing and hiding ?
>>
>> I was seeking for the same things just last week...
>> For collapsing and expanding using the tool buttons in the window's
>> task bar, the
>> methods #collapse and #expand of SystemWindow get executed.
>>
>> Resizing and moving with the mouse is more difficult to intercept.
>> The best way I found was to hook into #doFastWindowReframe:
>> (resizing) and
>> #doFastFrameDrag: (moving).
>> I had to override these methods to send a notification to my stuff.
>> Not the best way,
>> so enhancing SystemWindow to announce resizing, moving, maybe also
>> expanding,
>> collapsing, closing, etc. would be better.
>>
>> David
>>
>>> I do not have the feeling this is supported currently. One way to
>>> implement this I guess, is to redefine the method
>>> SystemWindow>>extent: to emit an instance of a subclass of
>>> Announcement, which could be named MorphicWindowResize.
>>>
>>> I plan to do this for Mondrian, but maybe this is of an interest to
>>> GUI guys.
>>>
>>> Any comment before I proceed?
>>>
>>> Cheers,
>>> Alexandre
>>>
>>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
> --
> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
> Alexandre Bergel  http://www.bergel.eu
> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>
>
>
>
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.






_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project