Home   Archive   Permalink



Mouse Wheel useless?

I am trying to incorporate scrolling via the Mouse Wheel into Text-Lists and Area text boxes. I've seen scripts like the built-in editor recognize the Wheel but haven't found the source for it. Assuming it's either a Feel or an Engage type function. I'm so used to how Windows handles Lists and scrollable widgets, it has spoiled me.

posted by:   Michael Todd       4-Dec-2018/23:15:47-8:00



There are 'scoll-line and 'scoll-page events--I believe you need to use INSERT-EVENT-FUNC to capture these events as I don't think they are applied to every face. I'll take a look and see if I have some example code.

posted by:   Chris       5-Dec-2018/18:31:02-8:00



Thanks Chris for checking...

posted by:   Michael Todd       5-Dec-2018/19:41:34-8:00



I believe I will just not look to Rebol GUIs to have the responsiveness and tweaks that are standard in MS Windows.

posted by:   Michael Todd       11-Dec-2018/12:31:27-8:00



Check here for more about the SCROLL-LINE/SCROLL-PAGE events: http://www.rebol.com/docs/view-face-events.html
    
Per this section, neither event is handled at the face level: http://www.rebol.com/docs/view-face-events.html#section-19
    
This means you have to handle these events at a higher level and pass them down to the face you're targeting. This is way more convoluted than it should be, I've isolated a minimal strategy for capturing these events and passing them down to their intended recipient:
    
https://gist.github.com/rgchris/4a8c3691b730899fb674b9e17d5f409e
    
Note that I tested this on Mac and was only able to get it to work with a mouse with a scroll-wheel, not a scroll gesture on a track pad. YMMV.

posted by:   Chris       17-Dec-2018/1:18:11-8:00



Also, would strongly recommend adding this to any Rebol/View 2.7.8 reading list:
    
http://codeconscious.com/rebol/#REBOLInformationandTips

posted by:   Chris       17-Dec-2018/22:24:03-8:00



Thanks Chris for the additional information. I will check it out. I have been reading through the helpful info on the code conscious site as well.
    
It's too bad things like this aren't documented up front as many features of Windows GUIs have to be tacked onto View layouts. I think this extra work turns off a lot of potential users of Rebol.
    
Mike

posted by:   Michael Todd       27-Dec-2018/18:37:33-8:00



Agreed. Trouble was that development shifted to Rebol 3 before everything in Rebol 2 was fully documented. Sadly Rebol 3 GUI work halted before it ever made it to reasonably complete or cross-platform state and some of the quirks of the Rebol 2 system were neither addressed nor documented. All in all a discouraging state of affairs where the potential is so great.
    
On the plus side, Red is pushing ahead with its own take on View/VID and Ren-C will persevere with an attempt at getting Rebol into the browser controlling the DOM. Still enough bright points to have hope...

posted by:   Chris       28-Dec-2018/17:25:33-8:00



...and Atronix is testing an Alpha version of Rebol 3 that uses the Skia graphics library instead of the venerable AGG library. Early FPS benchmarks show that Skia Rebol is about 6x faster than AGG Rebol with a modest Intel 630 GPU. We haven't yet done benchmarks with better graphic cards.
    
We'll be showing off the latest ZOE running on top of Skia Rebol at our Promat booth in April.
    
https://www.promatshow.com/listing.aspx?ref=attendees&id=45506
    
It's the MHS booth. Atronix is now a subsidiary of MHS.

posted by:   David den Haring       21-Jan-2019/15:10:52-8:00



It's fantastic to here that you're forging ahead Dave!

posted by:   Nick       22-Jan-2019/7:31:10-8:00



Name:


Message:


Type the reverse of this captcha text: "m u m i n i m"



Home