groups and background

Dar Scott dsc at swcp.com
Sun Dec 29 14:34:01 EST 2002


On Sunday, December 29, 2002, at 02:43 AM, Geoff Canyon wrote:

>> A group may have its backgroundBehavior property set to true.  Such a 
>> group introduces interesting paths on any card it is on.  This group 
>> is also placed on new cards under some conditions.  The card/stack 
>> property backgroundNames lists all groups with this property set to 
>> true for the specified card or stack.
>
> BackgroundNames is a property of a stack, but not of a card.

But it works on Rev 1.1.1 on OS X.  I get different lists for "the 
backgroundNames of this stack" and "the backgroundNames of this card".

>
>> Groups may be shared.   "The number of backgrounds (of a stack)" is 
>> the number of sharable groups in the stack; shared groups are counted 
>> only once.  (The number of backgrounds of a card is 0.)  All groups 
>> are sharable except nested groups.  The property groupNames is a card 
>> property that lists all sharable groups on the card.  There is no such 
>> property for stacks.
>
> Everything here is right. I do think "sharable" is unnecessarily 
> confusing the issue for the sake of brevity.
>
> _All_ groups are "sharable," in the sense that they can appear on more 
> than one card. Groups contained in other groups appear on whatever 
> cards their parent groups appear on.


> You call them nested groups. I think of them as "subgroups," although 
> that term has no official standing.

I think subgroup is a better name.  "Nesting" is more a relationship 
among groups than an attribute of a group.  Another name might be 
"embedded group".  I'll run with subgroup.


> By "sharable," you might also be referring to the (more verbose) 
> concept of "able to be placed onto a card," which rules out 
> nested/subgroups.
>
Yes.  I was going to write placeable, but I kept spelling it "placable" 
and that didn't look right.  In light of your comment on sharable, I'd 
replace it with placeable.  But, dropping the qualifier is not right 
because that would include the subgroups.  (In my stacks, most groups 
are subgroups.)

So I revise this:
****
Groups may contain groups.  Those contained groups are subgroups.

All groups may be shared.  A group placed on a card is not a duplicate 
but is the same group shared by some number of cards. Subgroups may only 
be shared by the root parent group being placed on a card.  Groups that 
are not subgroups may be placed on cards.  The number of backgrounds of 
a stack is the number of placeable groups in the stack; groups are 
counted only once.  (The number of backgrounds of a card is 0.)  The 
property groupNames is a card property that lists all placeable groups 
on the card.  There is no such property for stacks.

A group may be removed from all cards but still exist in the stack.  
Getting the owner of such a stack creates an error.

The cards of a group may be referenced.  Expressions such as "card 1 of 
this background" or "the number of cards in this background" may be used.
****

Maybe this is better.




More information about the use-livecode mailing list