The Artima Developer Community
Sponsored Link

Agile Buzz Forum
Pleasant Scrolling Surprises

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
James Robertson

Posts: 29924
Nickname: jarober61
Registered: Jun, 2003

David Buck, Smalltalker at large
Pleasant Scrolling Surprises Posted: Feb 23, 2004 4:57 PM
Reply to this message Reply

This post originated from an RSS feed registered with Agile Buzz by James Robertson.
Original Post: Pleasant Scrolling Surprises
Feed Title: Michael Lucas-Smith
Feed URL: http://www.michaellucassmith.com/site.atom
Feed Description: Smalltalk and my misinterpretations of life
Latest Agile Buzz Posts
Latest Agile Buzz Posts by James Robertson
Latest Posts From Michael Lucas-Smith

Advertisement

I've just finished the selecting code in WithStyle. It's one of those things you never think you're going to need to do.. write your own selecting algorithm. But it turns out that you do if you're building your own free layout text rendering widget.

Last night I had one more job on it to do.. if you drag the mouse outside the window, the scrolling area should scroll and keep selecting. To do this I knew I needed to grab and ungrab the mouse. Grabbing and ungrabbing the mouse allows you to keep track of its movements even when its outside your window.

But to my very surprise, once I'd grabbed and ungrabbed the mouse upon mouse up/down.. the window automatically scrolled when the mouse when outside its area! I believe this has to be a combination of the grabbing action, controller behaviour and the fact that my widget is subclassed off AutoScrollingView.

Needless to say I'm pleasantly surprised that I don't need to write this code myself. Object Orientedness wins again.

Read: Pleasant Scrolling Surprises

Topic: JOOP has a cool ST article Previous Topic   Next Topic Topic: Re: More outsourcing analysis

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use