scrollbars for a stack?

Peter Brigham pmbrig at gmail.com
Wed Nov 5 10:21:20 EST 2014


Here's one solution, no scrollbars but allows scrolling using the
scrollwheel or two-finger touchpad scrolling if available. Put the
following into the card script of your stack (or the stack script if more
than one card):

on rawkeydown what
  put the top of stack "myStack" into t
  if what = 65308 then -- scroll down
    set the top of stack "myStack" to t-12
    -- adjust the parameter as desired
  else if what = 65309 then -- scroll up
    set the top of stack "myStack" to t+12
  else
    pass rawkeydown
  end if
end rawkeydown

-- Peter

Peter M. Brigham
pmbrig at gmail.com
http://home.comcast.net/~pmbrig


On Tue, Nov 4, 2014 at 12:13 PM, Dr. Hawkins <dochawk at gmail.com> wrote:

> My application generates pdf full pages (it has to; the forms are specified
> by the courts, and the program is to prepare them)
>
>
> Some of the text can be small (remember, I can't change that!), so I have
> coded to use scaleFactor to allow zooming.  On even a 15" screen, this will
> rapidly create a stack taller than the screen.  In other cases, someone
> might simply want to zoom yet use less screenspace.
>
> Currently, the rendering is done by placing the groups on card 1 of the
> output stack.  It would seem simpler to simply slap scrollbars onto the
> stack, and let the user scroll when desired--but this doesn't seem to be a
> supported feature of livecode, unless I've missed something.
>
> The cleanest (least dirty?) way I see to achieve this at the moment is to
> create yet another group containing all of my display groups, and resize
> that group each time the window resizes.
>
> Or is there a better way?
> --
> Dr. Richard E. Hawkins, Esq.
> (702) 508-8462
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>



More information about the use-livecode mailing list