How difficult is it to change focus on scroll?

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

How difficult is it to change focus on scroll?

Eliot Miranda-2
Hi All,

    the recent click-to-focus changes are good but not perfect.  I find using the scroll wheel frustrating because I have to click to focus before scrolling will affect the desired window.  So would it be possible to select the morph under the cursor on a scroll wheel event?

--
best,
Eliot


Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

marcel.taeumel (old)
As long as mouse wheel events are actually keyboard events (ctrl+up/down), this would be tricky. :) You need keyboard focus for them to be effective.

Best,
Marcel
Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

timrowledge

On 08-08-2014, at 12:43 PM, Marcel Taeumel <[hidden email]> wrote:

> As long as mouse wheel events are actually keyboard events (ctrl+up/down),
> this would be tricky. :) You need keyboard focus for them to be effective.

At least on OS X there must be a way to discriminate since the OS enables scrolling of windows not holding the keyboard focus. Which is important because its almost as good as the ancient and wonderful RISC OS approach that allows the window with keyboard focus to not be the topmost window. Which means you can have a large window open to read stuff from whilst a window into which you need to type something can be almost hidden underneath, leaving the view clear. Yes, it’s less important if you have huge screens.


tim
--
tim Rowledge; [hidden email]; http://www.rowledge.org/tim
Law of Logical Argument: Anything is possible if you don't know what you are talking about.




Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

J. Vuletich (mail lists)
Hi Tim,

(private answer)

Quoting tim Rowledge <[hidden email]>:

> On 08-08-2014, at 12:43 PM, Marcel Taeumel  
> <[hidden email]> wrote:
>
>> As long as mouse wheel events are actually keyboard events (ctrl+up/down),
>> this would be tricky. :) You need keyboard focus for them to be effective.
>
> At least on OS X there must be a way to discriminate since the OS  
> enables scrolling of windows not holding the keyboard focus. Which  
> is important because its almost as good as the ancient and wonderful  
> RISC OS approach that allows the window with keyboard focus to not  
> be the topmost window. Which means you can have a large window open  
> to read stuff from whilst a window into which you need to type  
> something can be almost hidden underneath, leaving the view clear.  
> Yes, it’s less important if you have huge screens.

Well, this was also the Squeak behavior. And it is the current Cuis  
behavior. I find it useful when on my 800x600 netbook.

Cheers,
Juan Vuletich

>
>
> tim
> --
> tim Rowledge; [hidden email]; http://www.rowledge.org/tim
> Law of Logical Argument: Anything is possible if you don't know what  
> you are talking about.




Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

J. Vuletich (mail lists)
No, that wasn't a private answer at all :) . Apologies for the noise.

Quoting "J. Vuletich (mail lists)" <[hidden email]>:

> Hi Tim,
>
> (private answer)
>
> Quoting tim Rowledge <[hidden email]>:
>
>> On 08-08-2014, at 12:43 PM, Marcel Taeumel  
>> <[hidden email]> wrote:
>>
>>> As long as mouse wheel events are actually keyboard events (ctrl+up/down),
>>> this would be tricky. :) You need keyboard focus for them to be effective.
>>
>> At least on OS X there must be a way to discriminate since the OS  
>> enables scrolling of windows not holding the keyboard focus. Which  
>> is important because its almost as good as the ancient and  
>> wonderful RISC OS approach that allows the window with keyboard  
>> focus to not be the topmost window. Which means you can have a  
>> large window open to read stuff from whilst a window into which you  
>> need to type something can be almost hidden underneath, leaving the  
>> view clear. Yes, it’s less important if you have huge screens.
>
> Well, this was also the Squeak behavior. And it is the current Cuis  
> behavior. I find it useful when on my 800x600 netbook.
>
> Cheers,
> Juan Vuletich
>
>>
>>
>> tim
>> --
>> tim Rowledge; [hidden email]; http://www.rowledge.org/tim
>> Law of Logical Argument: Anything is possible if you don't know  
>> what you are talking about.




Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

Karl Ramberg
In reply to this post by Eliot Miranda-2
It could maybe be done using mouseFocus. Mouse focus is hardly used in the image and I,m not sure it works but it could be worth a try.

Karl


On Fri, Aug 8, 2014 at 7:35 PM, Eliot Miranda <[hidden email]> wrote:
Hi All,

    the recent click-to-focus changes are good but not perfect.  I find using the scroll wheel frustrating because I have to click to focus before scrolling will affect the desired window.  So would it be possible to select the morph under the cursor on a scroll wheel event?

--
best,
Eliot






Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

Karl Ramberg
In reply to this post by Eliot Miranda-2
Here is a simple test of concept.

Karl


On Fri, Aug 8, 2014 at 7:35 PM, Eliot Miranda <[hidden email]> wrote:
Hi All,

    the recent click-to-focus changes are good but not perfect.  I find using the scroll wheel frustrating because I have to click to focus before scrolling will affect the desired window.  So would it be possible to select the morph under the cursor on a scroll wheel event?

--
best,
Eliot







Scrollwheel.1.cs (4K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

Chris Muller-3
It breaks Berts blue-drag and pinch-zoom, which I use 1000 times per day.


On Sat, Aug 9, 2014 at 11:57 AM, karl ramberg <[hidden email]> wrote:
Here is a simple test of concept.

Karl


On Fri, Aug 8, 2014 at 7:35 PM, Eliot Miranda <[hidden email]> wrote:
Hi All,

    the recent click-to-focus changes are good but not perfect.  I find using the scroll wheel frustrating because I have to click to focus before scrolling will affect the desired window.  So would it be possible to select the morph under the cursor on a scroll wheel event?

--
best,
Eliot










Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

Bert Freudenberg
In reply to this post by marcel.taeumel (old)
On 08.08.2014, at 21:43, Marcel Taeumel <[hidden email]> wrote:

> As long as mouse wheel events are actually keyboard events (ctrl+up/down),
> this would be tricky. :) You need keyboard focus for them to be effective.

(Ab-)using keyboard events for scrolling was a hack to get scroll events from the VM to the image without having to define a new VM event type. And dispatching them in the image as keyboard events was also TSTTCPW.

The Right Thing to do now would be to define a completely new Morphic event type for scroll events. They would be dispatched similar to mouse events, so you always scroll the pane under the mouse pointer, even if it is not active.

This does not necessitate a VM change. HandMorph>>processEvents could look for scrolling keyboard events and create a ScrollEvent for them.

Eventually VMs could generate native scroll events, of course, but that's independent of creating a real scrolling framework inside the image.

- Bert -




smime.p7s (5K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

marcel.taeumel (old)
I implemented mouse wheel events in my widgets project in terms of a custom event class, whose instances are created in a custom event handler:

https://github.com/marceltaeumel/widgets/tree/master/repository/Widgets.package/UiMouseWheelEvent.class
https://github.com/marceltaeumel/widgets/tree/master/repository/Widgets.package/UiEventHandler.class

One could think of creating such an event directly in the HandMorph as Bert suggested.

Notice: It is not necessarily about scrolling here. It is just the mouse wheel. For some recent references, maybe look here:

http://qt-project.org/doc/qt-5/qml-qtquick-wheelevent.html
http://qt-project.org/doc/qt-5/qwheelevent.html

Best,
Marcel
Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

marcel.taeumel (old)
Nevertheless, Eliot, the VM should generate those wheel events. :) We want to handle Ctrl+Up/Down in the image and do something different with it. :D This also reminds me of this other "hack" in the VM, which obscures mouse click events if several modifiers are pressed... ;)

Best,
Marcel
Reply | Threaded
Open this post in threaded view
|

Re: How difficult is it to change focus on scroll?

Eliot Miranda-2
On Aug 19, 2014, at 7:13 AM, Marcel Taeumel <[hidden email]> wrote:

> Nevertheless, Eliot, the VM should generate those wheel events. :) We want to
> handle Ctrl+Up/Down in the image and do something different with it. :D This
> also reminds me of this other "hack" in the VM, which obscures mouse click
> events if several modifiers are pressed... ;)

+1.  Also the VM should generate the same codes on different platforms.  The current situation is a mess.


Eliot (phone)


> Best,
> Marcel
>
>
>
> --
> View this message in context: http://forum.world.st/How-difficult-is-it-to-change-focus-on-scroll-tp4772542p4773812.html
> Sent from the Squeak - Dev mailing list archive at Nabble.com.
>