Skip navigation.
 
mlRe: Getting mousecoordinates in scrollview
FROM : Steven Noyes
DATE : Fri Dec 13 14:58:08 2002

Are you looking at the NSScrollView's documentView and contentView. 
These should return
the visible aspects of the view.

Steven

On Friday, December 13, 2002, at 03:46 PM, Florian Soenens wrote:

> Hello, i'm stuck withthe following:
>
> I have an NSMatrix containing images of about 50x50 pixels.
> The NSMatrix is part of a scrollview.
>
> In the mousedown event of the matrix i do some things according to the
> position of the mouse, wich i calculated, to select the right image of
> the matrix.
> This works fine, however, when the matrix has more images than can be
> displayed, i have to scroll my scrollview, obviously. When the
> scrollview is scrolled, the coordinates seem to be incorrect, thus the
> wrong image gets selected.
> Is there any way to get the scrollamount of a scrollview so i can
> change my calculations, or is there a much simpler way wich i have not
> yet discovered?
>
> Thanks in advance,
>
> Flor.
>
> _______________________________________________
> MacOSX-dev mailing list
> <email_removed>
> http://www.omnigroup.com/mailman/listinfo/macosx-dev
>



Related mailsAuthorDate
mlGetting mousecoordinates in scrollview Florian Soenens Dec 13, 14:47
mlRe: Getting mousecoordinates in scrollview Steven Noyes Dec 13, 14:58
mlRe: Getting mousecoordinates in scrollview John C. Randolph Dec 13, 15:10