paydarfa@hatteras.cs.unc.edu (Joe Paydarfar) (01/24/91)
I have a problem trying to create a stack that makes use of backgrounds that I have already created in a previous stack. From what I understand, HyperCard has a command called 'create stack' in which you can specify one background from another stack but what should you do if there is more than one background that you want to use from the other stack? Any info on this would be greatly appreciated!!
mandel@vax.anes.tulane.edu (Jeff E Mandel MD MS) (01/24/91)
In article <735@borg.cs.unc.edu> paydarfa@hatteras.cs.unc.edu (Joe Paydarfar) writes: > > I have a problem trying to create a stack that makes use of >backgrounds that I have already created in a previous stack. From >what I understand, HyperCard has a command called 'create stack' in which >you can specify one background from another stack >but what should you do if there is more than one background that >you want to use from the other stack? Any info on this would be greatly >appreciated!! > > I have this problem in a project of mine, in which I need to clone an empty stack which is then populated (by CL/1). My solution is an XCMD which copies the entire stack using the file manager. It is reasonably fast, opens the source file readOnly, so it can work with an open stack or one on a write-locked volume, and I have not encountered any bugs in the last 2 weeks of using it. I will eventually post it, but anyone who needs it desperately, mail me for a beta copy. Of note to the busy HyperCard team, I would much prefer that the command doMenu "Save a copy..." without dialog did just that. Jeff E Mandel MD MS Asst. Professor of Anesthesiology Tulane University School of Medicine New Orleans, LA
jkc@Apple.COM (John Kevin Calhoun) (01/25/91)
>I have this problem in a project of mine, in which I need to clone an empty >stack which is then populated (by CL/1). My solution is an XCMD which copies >the entire stack using the file manager. It is reasonably fast, opens the >source file readOnly, so it can work with an open stack or one on a >write-locked volume, and I have not encountered any bugs in the last 2 weeks >of using it. [...] Of note to the busy HyperCard team, I would much prefer >that the command doMenu "Save a copy..." without dialog did just that. The "save" command in HyperCard 2.0 does what you want. Examples: save this stack as "Fred" save stack "Template" as "The stack I'm going to work with" Kevin Calhoun HyperCard Team Apple Computer, Inc.
jkc@Apple.COM (John Kevin Calhoun) (01/25/91)
In article <735@borg.cs.unc.edu> paydarfa@hatteras.cs.unc.edu (Joe Paydarfar) writes: > > I have a problem trying to create a stack that makes use of >backgrounds that I have already created in a previous stack. From >what I understand, HyperCard has a command called 'create stack' in which >you can specify one background from another stack >but what should you do if there is more than one background that >you want to use from the other stack? Any info on this would be greatly >appreciated!! When you use the "create stack" command, you can specify which background you want the new stack to have. Some examples: create stack "New Stack" with background 3 create stack "Magyar" with this background create stack "Slogans" with background "Fahrvergnugen" The stack will be created and then opened. If you want it to be opened in a new window, add the phrase "in a new window" to the command. create stack "Berenstein Bears" with background 1 in a new window If you don't specify a background, "create stack" creates a new stack with a blank background. The create stack command is new in HyperCard 2.0. It doesn't exist in HyperCard 1.x. If you want to create a stack with several cards, each with a different background from the same source stack, you can create the stack first and then copy additional cards into it. Suppose a stack has four backgrounds, and you want to create a new stack with four cards, one for each of the backgrounds of the source stack. You could do it this way: push card create stack "My New Stack" with this background pop card set lockMessages to true repeat 3 times go next background doMenu "Copy Card" push card go last card of stack "My New Stack" doMenu "Paste Card" pop card end repeat Of course, when you copy cards over to the new stack, they will retain all of their card objects as well as their background objects. Unfortunately, there still isn't a good way to copy just a background from one stack into another already existing stack. Kevin Calhoun HyperCard Team Apple Computer, Inc.