aisl@ur-tut.UUCP (Larry Landry) (02/04/88)
In article <422@stech.UUCP> sysop@stech.UUCP (Jan Harrington) writes: > >. . . . . . Assuming that >I've locked the text in each field, Hypercard doesn't detect the movement >of the scroll bar as a mouseUp event. To trigger the script, the user has >to click the pointer in the field that was scrolled (i.e., not in the scroll >bar area). > I do the same thing in one of my stacks. I have an idle handler in the card (could be anywhere above this) script. It says: on idle set the scroll of field n to the scroll of field n2 end idle Of course, you will probably want to set more than one additional field, but the idle message is where you should handle it. Larry Landry
sysop@stech.UUCP (Jan Harrington) (02/05/88)
in article <911@ur-tut.UUCP>, aisl@ur-tut.UUCP (Larry Landry) says: > > In article <422@stech.UUCP> sysop@stech.UUCP (Jan Harrington) writes: >> >>. . . . . . Assuming that >>I've locked the text in each field, Hypercard doesn't detect the movement >>of the scroll bar as a mouseUp event. To trigger the script, the user has >>to click the pointer in the field that was scrolled (i.e., not in the scroll >>bar area). >> > > I do the same thing in one of my stacks. I have an idle handler in the > card (could be anywhere above this) script. It says: > > on idle > set the scroll of field n to the scroll of field n2 > end idle > > Of course, you will probably want to set more than one additional field, but > the idle message is where you should handle it. > This will only work if the scroll should be pegged to one certain field, say the leftmost one in the set. However, I want to let people scroll any of the fields. Whenever _any_ of the scroll bars are moved, I want to adjust all of the fields to the last one that was moved, which, of course, is what is creating the problem. I did switch the handler to on mouseWithin, which is a bit better. As long as the mouse remains within the field that was scrolled, all the others will adjust. Unfortunately, if the user is quick on the mouse, it's possible that the mouse pointer will have left the field before the script can click in (at least, I can get the mouse out fast enough to make that happen). So, the mouseWithin isn't an ideal solution. The best answer I got to this question was someone who had written scripts to put his own scroll bars over the field's scroll bars. He offered to mail me the scripts, but my mailer couldn't construct a mail path back to him, and I lost contact ... Arg! Jan Harrington, sysop Scholastech Telecommunications ihnp4!husc6!amcad!stech!sysop or allegra!stech!sysop ******************************************************************************** Miscellaneous profundity: "No matter where you go, there you are." Buckaroo Banzai ********************************************************************************
news@siemens.UUCP (login for the netnews) (02/10/88)
-------- About the problem with keeping scrolling fields together: you could put this into your card script -- From: jts@demon.siemens-rtl (Jim Sasaki) Path: demon!jts on mouseWithin set scroll of card field a to scroll of target set scroll of card field b to scroll of target set scroll of card field c to scroll of target ... end mouseWithin You do get a lot of mouseWithin messages passed around, unfortunately. (Anyone know how expensive they are?) You can also use "mouseLeave" instead of "mouseWithin", but then the other fields only scroll to match when the mouse moves out of the field. (With "mouseWithin", the scrolling happens after every click in the scroll bar or whenever the elevator or scroll arrow is released.) ----- -- Jim Sasaki (jts%siemens.com@princeton.edu, princeton!siemens!jts) Any opinions above are my own, and not necessarily those of Siemens RTL, for whom I consult.