[comp.sys.mac.hypercard] How about static fields???

t-jacobs@wasatch.UUCP (Tony Jacobs) (01/27/89)

Suggestion:

I am always running into the need for static text fields on backgrounds.  By
static I mean they are the same for every card and they need to be changed
once in a while.  I have maneuvered around this limitation in a couple of ways.
One, I use a button and set the name of it to the text I want. This is fine
for small fields. For large fields I save the text in a global field and then
put the text into the field upon entering the card and put empty into it upon
leaving.  For stacks with large numbers of cards this can save A LOT of space
but it does slow things down a little.

How hard would it be to add a checkbox to the field attributes dialog which
makes the field the same for every card.



One more suggestion:

Backgrounds are wonderful things, how about a FOREGROUND? By this I mean a
layer where objects can be put where they appear on top of cards and the
scripts are handled before card scripts. Foregrounds could be very much like
backgrounds or they could be quite different, I don't know which would be
better. All I know is that card objects are always drawn on top of background
objects and many times I wish it were the other way around.-- 
Tony Jacobs * Center for Engineering Design * U of U * t-jacobs@ced.utah.edu

dan@Apple.COM (Dan Allen) (01/28/89)

In article <979@wasatch.UUCP> t-jacobs@wasatch.UUCP (Tony Jacobs) writes:
>Suggestion:
>I am always running into the need for static text fields on backgrounds.  By
>
>One more suggestion:
>
>Backgrounds are wonderful things, how about a FOREGROUND? By this I mean a

Good ideas... we'll see what we can do.  (Let me see now, our suggestion
list is over 80 pages... !!)

Dan Allen
Apple Computer

GAB100@PSUVM.BITNET (George A. Brownfield) (02/03/89)

In article <979@wasatch.UUCP>, t-jacobs@wasatch.UUCP (Tony Jacobs) says:

>I am always running into the need for static text fields on backgrounds.  By
>static I mean they are the same for every card and they need to be changed
>once in a while. I have maneuvered around this limitation in a couple of ways.
(...some complex kludges deleted...)
>How hard would it be to add a checkbox to the field attributes dialog which
>makes the field the same for every card.

     How hard is it to use the text tool under the paint tools menu?
Go into the background editor, select the text tool, place your cursor
at the appropriate place, and type in the information.  The result will
be the same text on all cards.  If you need to arrange/format it, use
the lasso or marquee.  You can even paint in a nice border if it's needed.

     For the occasional card that you need something different, go into
the painting mode while in the card editor rather than background, and
just type the new text over it.

-----
BORROWED ACCOUNT  -- NOT George Brownfield.

James D. Maloy, PSU Class of '87

Replies can go to dev/null -- I'm in State College for
today only and won't see them anyway.

t-jacobs@wasatch.UUCP (Tony Jacobs) (02/03/89)

In article <69824GAB100@PSUVM> GAB100@PSUVM.BITNET (George A. Brownfield) writes:
>In article <979@wasatch.UUCP>, t-jacobs@wasatch.UUCP (Tony Jacobs) says:
>>I am always running into the need for static text fields on backgrounds.  By

>     How hard is it to use the text tool under the paint tools menu?
>James D. Maloy, PSU Class of '87


Three problems with this technique. 1) It is slower than "put mytext into
field" and 2) you can't read the text! (Unless you have an Optical Character
Recognition XCMD handy) 3) I may want the text to be scrollable.

There are actually many other reasons but I won't get into them.

-- 
Tony Jacobs * Center for Engineering Design * U of U * t-jacobs@ced.utah.edu

stone@hydra.unm.edu (Andrew Stone CS.DEPT) (02/04/89)

There is a simple solution: keep the static text in a field on any given 
card, and on new card, put that text into the new card's field.

on newcard
  put fld "info" of card "master" into fld "info"
  ...
end newcard.


||<<++>>||<<-->>||<<==>>||<<++>>||<<??>>||<<++>>||<<-->>||<<==>>||<<++>>||
||                                  ||                                  ||
||	   Andrew Stone	            ??		2 + 2 = 5;		|| 
||         stone@hydra.unm.edu	    <> 	    for sufficiently large 2    ||
||	   			    ||					||
||<<++>>||<<-->>||<<==>>||<<++>>||<<??>>||<<++>>||<<-->>||<<==>>||<<++>>||

t-jacobs@wasatch.UUCP (Tony Jacobs) (02/04/89)

In article <4339@charon.unm.edu> stone@hydra.unm.edu.UUCP (Andrew Stone CS.DEPT) writes:
>
>There is a simple solution: keep the static text in a field on any given 
>card, and on new card, put that text into the new card's field.
>
>on newcard
>  put fld "info" of card "master" into fld "info"
>  ...
>end newcard.


If you read my origional post, that is almost exactly what I said I was doing.
If you want to do that with a lot of fields then you need a script for every
field and as I origionally mentioned you need to remove the text upon leaving
the card if you don't want a large stack to get way bigger than it needs to be.
Also with a lot of static fields of this type it slow things down quite a bit
waiting to copy each time you go to a card.

I agree it was simple to do what I wanted to do but "simple" is not always easy
to edit nor is it always as fast as it could be.







-- 
Tony Jacobs * Center for Engineering Design * U of U * t-jacobs@ced.utah.edu

annie@cs.swarthmore.edu (Annie Fetter) (02/04/89)

> >I am always running into the need for static text fields on backgrounds.  By
>      How hard is it to use the text tool under the paint tools menu?
>   (etc.)
> James D. Maloy, PSU Class of '87

The main reason why I would like to have static text fields is that the painted
text is ugly and unreadable, compared to 'field' text.  I often use locked
field instead of painting just for aesthetic purposes.  Besides, this doesn't
seem like a tough thing to implement :-).


-- 
       Annie Fetter           |      annie@cs.swarthmore.edu    |  "We got the
VGP-Department of Mathematics |      fetter@swarthmr.bitnet     |   grant! We
    Swarthmore College        |  ...!rutgers!bpa!swatsun!annie  |    Open the
   Swarthmore, PA 19081       |         (215) 328-8225          |   champagne!"

jonathan@eleazar.dartmouth.edu (Jonathan Altman) (02/04/89)

In article <69824GAB100@PSUVM> GAB100@PSUVM.BITNET (George A. Brownfield) writes:
>In article <979@wasatch.UUCP>, t-jacobs@wasatch.UUCP (Tony Jacobs) says:
>
>>(good suggestion asking for background fields that are static
     between cards and a description of kludges to accomplish
     something similar)
>
>     How hard is it to use the text tool under the paint tools menu?
>Go into the background editor, select the text tool, place your cursor
>at the appropriate place, and type in the information.  The result will
>be the same text on all cards.  If you need to arrange/format it, use
>the lasso or marquee.  You can even paint in a nice border if it's needed.
>
(some stuff deleted)
>BORROWED ACCOUNT  -- NOT George Brownfield.
>
>James D. Maloy, PSU Class of '87

Actually, I was going to let this message pass.  Here's why the
suggestion of using the text paint tool isn't enough.  What I wanted to
do was write a stack that I thought was one of the best things
hypercard did-walk someone through a demonstration of something, in
this case the use of a database of commentaries on the Divine Comedy.
So, I had a sequential set of cards which represented the steps of a
session on our database.  Depending on which operation the stack was
showing, I wanted the user of the stack to be able to click on any part
of the screen dump on that card, and have a piece of explanatory text
pop up, and then go away when the user wanted to get rid of it.  Now,
there are at least ten cards for each of two backgrounds.  There are
about ten items on each screen dump for which I'd like to show
information.  It's the same information for each card in a background.
To show help for any item on each card requires one of several things:

1. Use background fields, and write the information for each card in
each card.  This is, obviously tedious.  Then I can use "show field"
when a user wants to see some information, and "hide field" when the
user wants it to go away.  This is a HUGE hack, especially if I ever
want to CHANGE anything(oh, yeah.  Forgot to change the text on card 37
of 52-sorry.)

2. Paint the information onto the card, and then erase it.  Good
solution.  Especially since I like painting my cards grey, so that
erasing doesn't work.  Besides, it's always fun to watch a script run
the paint tools.  (I know, you could lock the card, but painting is
still slow, and a user could possibly interrupt it)

3. Use background fields.  Put the information in the fields for one
card.  Show the information in other cards by getting the contents from
that one card, then put it into the field for the current card.  Still
a hack, and the particular hack that I used.

Now, if backgrounds can stay around between cards, certainly a new type
of field could also.  This seems a much cleaner solution.

Anyway, this isn't a flame of hypercard, nor a strong flame of the
person who suggested the paint tools (although I thought it WAS a bit
condescending).  But I hope that I've presented adequate reason why
static background text fields might be nice.  Maybe this'll move the
idea up a couple of pages on the 80-page feature list.

Jonathan Altman           jonathan@eleazar.Dartmouth.edu
Database Administrator    (ihnp4,decvax)!dartvax!eleazar!jonathan
Dartmouth Dante Project   jonathan@eleazar.UUCP (I think)
HB 6087                   voice: 603-646-2633
Hanover, NH 03755

dan@Apple.COM (Dan Allen) (02/04/89)

In article <69824GAB100@PSUVM> GAB100@PSUVM.BITNET (George A. Brownfield) writes:
>     How hard is it to use the text tool under the paint tools menu?
>Go into the background editor, select the text tool, place your cursor
>at the appropriate place, and type in the information.  The result will
>be the same text on all cards.  If you need to arrange/format it, use
>the lasso or marquee.  You can even paint in a nice border if it's needed.

Obviously this is what people generally do.  However, the problem is
that paint text does not print out at full 300 dpi resolution on a
LaserWriter.  Shared background text is needed to support PostScript
printers (and better resolution with ImageWriters as well).


Dan Allen                **    dan@apple.COM (Unix mail)
Software Explorer        **    ALLEN.DAN (AppleLink)
HyperCard Team           **    20525 Mariani Ave. MS 22AE
Apple Computer           **    Cupertino, CA 95014
***********************************************************
** Sam:    "You know what they say, 'You can catch more  **
**          flys with honey than with vinegar.'"         **
** Woody:  "I don't mean to butt in, but you can catch   **
**          the most with dead squirrels."               **
***********************************************************

taylorj@byuvax.bitnet (02/05/89)

Whoah, wait a minute!  Am I missing something here?

Annie Fetter in <2396@babylon.cs.swarthmore.edu> says she prefers field text to
paint text because it looks better.  Unless I am sorely mistaken (notice the
"escape clause" brought about by "net-foot-in-mouth paranoia"?), they're both
exactly the same.  In fact, painted text is usually safer than field text
because it won't be screwed up if you run your stack on a different system
which doesn't contain the fonts you use.  Whenever I want my text to look good
no matter who's Mac it's running on, I paint it.  (Unless there's a lot of it;
in which case I make sure to install the appropriate fonts in my stack with
Font/DA Mover.)

Jim Taylor
Microcomputer Support for Curriculum, Brigham Young University
BITNET: taylorj@byuvax.bitnet   INTERNET: taylorj@yvax.byu.edu

kurtzman@pollux.usc.edu (Stephen Kurtzman) (02/06/89)

In article <392taylorj@byuvax.bitnet> taylorj@byuvax.bitnet writes:

>Annie Fetter says she prefers field text to paint text because it looks
>better.  Unless I am sorely mistaken [...] they're both exactly the same.
>In fact, painted text is usually safer than field text
>because it won't be screwed up if you run your stack on a different system
>which doesn't contain the fonts you use.

Field text looks a whole lot better when printed on a LaserWriter. When print-
ing the painted text HyperCard can't tell that it should use a LaserWriter
font, so it just does a bit map dump.

If Apple is listening: Please make HyperCard use LaserWriter fonts for
button text. When I print my cards on the LaserWRiter the button names always
look terrible compared to the text fields.

langford@reed.UUCP (Chris Langford) (02/08/89)

One solution I have been using is sort of a hack also, but it works
well for information that has to be the same for every card.  There are
a couple of XCMDs around that manipulate PICT resources.  One converts
the clipboard to a PICT, the other shows the PICT on the screen.
I chose the marquee tool, and selected the part of the screen where I
had typed the text.  Then I used the clipToPict XCMD to convert the
clipboard to a PICT, then used the showPICT XCMD to show it on the screen.

The XCMD and the PICT are attached to the stack, so it is available from
all the cards.  The only problem is that you have to click on the screen
to have the PICT go away, but the click doesn't make anything else happen.
It works well enough, but only if the amount of text fits on one screen.
There is still a need for scrolling static fields!

-- 
Chris Langford  {backbone}!tektronix!reed!langford -or- langford@reed.bitnet
"As an adolescent I aspired to lasting fame, I craved factual certainty, and
I thirsted for a meaningful vision of human life -- so I became a scientist.
This is like becoming an archbishop so you can meet girls." -Matt Cartmill-