Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!dewey.soe.berkeley.edu!oster From: oster@dewey.soe.berkeley.edu (David Phillip Oster) Newsgroups: comp.sys.mac.programmer Subject: Re: scroll bar problem Keywords: programming issue Message-ID: <28634@ucbvax.BERKELEY.EDU> Date: 1 Apr 89 11:18:57 GMT References: <425ca822.1285f@maize.engin.umich.edu> Sender: usenet@ucbvax.BERKELEY.EDU Reply-To: oster@dewey.soe.berkeley.edu.UUCP (David Phillip Oster) Distribution: usa Organization: School of Education, UC-Berkeley Lines: 20 In article <425ca822.1285f@maize.engin.umich.edu> rpitt@caen.engin.umich.edu (Raymond Jeczen Pittman) writes: >I am writing an application that uses multiple windows and I would >like to know how I can access the control list in the window record >to reference a particular controlhandle such as the scroll bars. 1.) look at how the dialog manager associates a TEREcord with a window: it defins a struct that has a WindowRecord as its zeorth element, and has a field holding a handle to the TE further along. 2.) I like to put a handle to a struct in the refcon of my windows. My window structs have fields for the data that describes the contents of my windows. Two common fields I use are hScroll vScroll: the scroll bars of the window (or pane, for multiple panes, each with their own scroll bars.) Searching the ((WindowPeek)thePort)->controlList for the control you want will work, but is seems pretty funky to me. --- David Phillip Oster --"When we replace the mouse with a pen, Arpa: oster@dewey.soe.berkeley.edu --3 button mouse fans will need saxophone Uucp: {uwvax,decvax}!ucbvax!oster%dewey.soe.berkeley.edu --lessons." - Gasee