different card sizes and transitions (was: Re: Looking at Rev)
Wilhelm Sanke
sanke at hrz.uni-kassel.de
Sun May 12 15:38:01 EDT 2002
As I only get the list digest, I am slower in responding and the
questions how to look at Rev stacks (to get the information to work with
different card sizes) have been expertly answered in the meantime.
Another problem comes up when you want to navigate between cards of
different sizes using visual transition effects.
When you use - for example - as part of a handler of the forward button
of a background navigation group:
" visual effect wipe right slowly to black
set the height of this window to NewHeight
set the top of this stack to savedtop
visual effect wipe left slowly
go to cd ID NewCard"
the NewHeight will be shown for the "old" card before applying the wipe
to black (even if you place "set the height.." later in the handler).
To overrule this too early resizing one solution would be:
- in the preopenstack handler set the backdrop to black and set the
decorations to empty
- set a custom property for each card that contains the card height
- create a card with a black background and no objects on it: card
"black"
- mark all cards and then unmark card "black"
- put the following handler into the forward button of the navigation
group:
"on mouseUp
put the CardHeight of next marked cd into NewHeight
put the ID of the next marked cd into NewCard
put the top of this stack into savedtop
visual effect wipe right slowly to black
go to card "black"
set the height of this window to NewHeight
set the top of this stack to savedtop
visual effect wipe left slowly
go to cd ID NewCard
end mouseUp"
This should work smoothly.
Regards, Wilhelm Sanke
More information about the use-livecode
mailing list