edc@aeras.UUCP (news guest account) (08/14/88)
I've been trying to simulate a cash register using Hypercard. Some of that I'm doing is similar to the hypercalc demo that comes with hypercard... Anyway, what I want is to have a field that acts like a LCD or LED display on a calculator or cash register. The user would type in something, and when he hits a carriage return, the something would be copied into a scrolling field. The display field would be cleared and the scrolling field would act like a a paper tape, holding a list of what has been typed. PROBLEM: I understand that the returnKey and enterKey interrups don't work in fields. How do I get around this? Am I making sense? -edc-
marc@rna.UUCP (Marc Johnson) (08/15/88)
In article <252@aeras.UUCP> edc@aeras.UUCP (news guest account) writes:
# . . . The user would type in something, and when
#he hits a carriage return, the something would be copied into a scrolling
#field. The display field would be cleared and the scrolling field would act
#like a a paper tape, holding a list of what has been typed.
#
#PROBLEM: I understand that the returnKey and enterKey interrups don't work
# in fields. How do I get around this?
#
I'm interested in this problem as well. Please e-mail workarounds to me
at: marc%rna@rockefeller.edu OR rna!marc@rockvax.bitnet. Thanks!
Marc Johnson
warner@scubed.UUCP (Ken Warner) (08/16/88)
I want to draw a rectangle around some painted text. Using the paint tools I can paint the text and draw a rectangle. I would like to be able to code the message handler in such a way as to be able to change the textFont and still know how big the extent rectangle is. What I mean by extent rectangle is the rectangle that will just enclose the painted text. How do I find the extent rectangle of some painted text? For example: on mouseUp choose text tool click at 50,50 type "1234567890" doMenu select ? How do I get the rectangle of the selection ? so I can draw a rectangle around the painted text? ? end mouseUp Is such an incantation possible? Ken Warner
dan@Apple.COM (Dan Allen) (08/17/88)
In article <214@rna.UUCP> marc@rna.UUCP (Marc Johnson) writes: >#PROBLEM: I understand that the returnKey and enterKey interrups don't work ># in fields. How do I get around this? In HyperCard 1.2 and later there are two new messages sent by HyperCard called returnInField and enterInField. They are very useful for handling either of these two keys when editing text. They are also related to the tab and auto-tab functions. More info and lots of great examples of how all this stuff works may be found in the HyperCard 1.2 Release Notes stack that ships with the HyperCard 1.2 product. I can understand people not reading the manuals, but come on folks, you can at least CLICK on a few buttons to puruse the help stacks, can't you? I know, I know, you probably don't have 1.2 yet and the Apple dealers aren't any help... Happy scripting. Dan Allen Software Explorer working on HyperCard Late at night at Apple Computer (well, okay, late at night at home)