Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Scolling faces

From: rebol:optushome:au at: 15-Dec-2001 7:44

Hi Andrew, The two events you need to trap are. scroll-line and scroll-page. scroll-line detects the mouse scroll scroll-page is mouse scroll + Pseudo example below detect: func [face event][ switch event/type [ scroll-line [do-myscroll event/offset/y * lineheight] scroll-page [do-myscroll event/offset/y * pageheight] ] ] The returned value for event/offset/y for scroll-line varies depending on the mousescroll settings on the persons machine (ie how many lines they set for mouse scrolling in their mouse software prefs, I have 3 in my prefs) For most cases the values returned are.(or multiples there of) for scroll-line scrolling button forward: -3 scrolling button backward: 3 for scroll-page scrolling button forward up: -1 scrolling button backward: 1 Cheers, Allen K