Some help needed!
Roger.E.Eller at sealedair.com
Roger.E.Eller at sealedair.com
Fri Sep 20 13:51:01 EDT 2002
Robin,
Something like this could be used to control the text size of buttons
or fields after the stack has been resized, still using geometry to control
the button sizes themselves.
on postResizeStack
repeat with i = 1 to the number of buttons of this card
if the width of btn i >= 170 then set the textSize of btn i to 18
if the width of btn i < 170 then set the textSize of btn i to 14
if the width of btn i < 125 then set the textSize of btn i to 10
if the width of btn i < 100 then set the textSize of btn i to 8
end repeat
end postResizeStack
Roger Eller
roger.e.eller at sealedair.com
> I hope someone can help me with two problems with a stack that I am
> creating. I am fairly new to Runtime Revolution though I have used
> Hypercard in the past.
>
> The problems relate to the fact that I intend to run a stack on several
> different machines. The problems are:
>
> 1) How can I ensure that if I need to resize the stack all buttons,
objects,
> font size etc. will scale down accordingly? I have looked at the
Geometry
> Manger but that doesn't seem to let me select more than one object at a
> time.
>
> 2) How can I export data from a text field to a text file on, say, a
floppy
> disk? I have successfully used 'put field 1 into URL "file:test.txt"' to
> put the contents of field 1 into test.txt in the current folder, but I
can't
> seem to get it to create or modify a file in any other location. I'm
> developing this in Mac OSX, but this export function will mainly be used
on
> Windows PCs, if that's relevant.
>
>
> Many thanks in advance.
>
> Robin
More information about the use-livecode
mailing list