Page 1 of 1

Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Mon May 25, 2020 1:26 pm
by mrcoollion
Hi all,

I have too many fields and buttons on one card and I am wondering.
What is the best/easiest way to make and maintain a vertical scrolling area in my card in which I can place all the Buttons and fields I need ?

Regards,

Paul

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Mon May 25, 2020 1:49 pm
by richmond62
Well, personally I'd just group everything and then set the Vertical scroll to true.
-
Screenshot 2020-05-25 at 15.48.15.png

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Mon May 25, 2020 2:18 pm
by mrcoollion
Ok, but how do I get objects past the card hight?

PS. Thanks for the tip and the sample!

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Mon May 25, 2020 2:27 pm
by mrcoollion
Found out how to put objects past the card hight (I think).

1) Make group height larger than the card (stack) height.
2) In run mode scroll up.
3) Then edit group and the area you scrolled to will be the area you can edit objects in.

Any other way's ?

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Mon May 25, 2020 4:48 pm
by Klaus
mrcoollion wrote:
Mon May 25, 2020 2:27 pm
way's
OUCH, this hurts! 8)

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Mon May 25, 2020 6:43 pm
by mrcoollion
Klaus wrote:
Mon May 25, 2020 4:48 pm
OUCH, this hurts! 8)
Well it would be nice if I would have been able to scroll the group in edit mode :wink:

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Mon May 25, 2020 6:54 pm
by FourthWorld
mrcoollion wrote:
Mon May 25, 2020 6:43 pm
Well it would be nice if I would have been able to scroll the group in edit mode :wink:
Does your app provide the pointer tool for your users, or are you referring to your own development work while making layouts in the IDE?

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Tue May 26, 2020 3:49 am
by PBH
You could try setting the stack scaleFactor to something like "0.75", then you can temporarily increase the depth of your stack and group for editing. Reset the size of the group and stack before setting the scaleFactor back to 1.

It does work pretty well, but be prepared for some small editing anomalies like dropping controls onto the card puts them in odd positions and you may need a good pair of glasses! 🤓

Paul

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Tue May 26, 2020 6:41 am
by FourthWorld
If you need a scrolling area of a specific size you can see the group's backsize property:
https://livecode.com/resources/api/#liv ... t/backsize

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Tue May 26, 2020 7:16 am
by mrcoollion
FourthWorld wrote:
Mon May 25, 2020 6:54 pm
Does your app provide the pointer tool for your users, or are you referring to your own development work while making layouts in the IDE?
I am referring to my own development work while making the layouts in the IDE.

Thanks Klaus, Paul and Richard for the great tips.

Re: Best or easiest way to make a vertical scrolling area with fields and buttons

Posted: Tue May 26, 2020 4:23 pm
by cpuandnet
mrcoollion wrote:
Mon May 25, 2020 6:43 pm
Klaus wrote:
Mon May 25, 2020 4:48 pm
OUCH, this hurts! 8)
Well it would be nice if I would have been able to scroll the group in edit mode :wink:
Open your message box and use the following command to scroll the group.

Code: Select all

set the vScroll of group "yourGroupName" to 100
The number you use (100 in this example) is really a hunt and peck method until you scroll to the area you desire. LC will automatically set the vScroll value to the max value if you try and use a number larger than the max. You can find the max vScroll value by executing the following command in the message box.

Code: Select all

put the formattedHeight of group "yourGroupName" - the height of group "yourGroupName"
This assumes you already have controls past the height of the group using one of the previously mentioned methods.