Progress Bar: continual spin

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller

Post Reply
townsend
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 430
Joined: Sun Feb 13, 2011 8:43 pm
Location: Seattle, USA

Progress Bar: continual spin

Post by townsend » Fri Oct 28, 2011 8:20 pm

Once when I was downloading some livecode sample apps,
I saw one where the Progress Bar just did a continual spin,
not based on any 'Thumb Position' property.

I thought, this could be useful. Now that I need it, I can't remember where I saw it.
Does anyone know how to set the Progress Bar to a continual spin?

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 6026
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: Progress Bar: continual spin

Post by dunbarx » Fri Oct 28, 2011 9:18 pm

Spin.

Do you mean it rotated? While it was progressing?

townsend
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 430
Joined: Sun Feb 13, 2011 8:43 pm
Location: Seattle, USA

Re: Progress Bar: continual spin

Post by townsend » Fri Oct 28, 2011 9:28 pm

The progress bar would move from start to finish and back again, over and over.

Kind of like an animated GIF.

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2776
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: Progress Bar: continual spin

Post by mwieder » Fri Oct 28, 2011 9:50 pm

Would one of the progress bar images in the Image Library do the trick for you?

townsend
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 430
Joined: Sun Feb 13, 2011 8:43 pm
Location: Seattle, USA

Re: Progress Bar: continual spin

Post by townsend » Fri Oct 28, 2011 10:18 pm

Good idea. I'll use that for now.

When I see that original app again,
I'll post the Progress Bar settings back in this thread.

deebee
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 89
Joined: Mon Jul 19, 2010 6:59 am
Location: Illinois, USA

Re: Progress Bar: continual spin

Post by deebee » Sat Oct 29, 2011 2:56 am

There's one on revOnline, maybe this one?
http://revonline2.runrev.com/stack/440/Spinner-Store

slylabs13
Posts: 10
Joined: Thu Jul 26, 2007 7:23 pm
Contact:

Re: Progress Bar: continual spin

Post by slylabs13 » Wed Dec 14, 2011 7:16 pm

The spinner does not work while a script is running, so far as I have been able to tell.

doc
Posts: 148
Joined: Fri Jun 09, 2006 4:30 pm
Location: Oklahoma, USA

Re: Progress Bar: continual spin

Post by doc » Sat Dec 17, 2011 10:23 pm

Howdy townsend,

I've put together a custom progress bar control using an image aligned inside a simple graphic rectangle...
...you can use whatever image you want of your own preference and adjust the maximum "bar" width, speed and number of iterations pretty easily to suit your needs.

Works pretty well on my Win7 machine, but I haven't checked it out on any other platform. The stack and original image used is attached to this message if you want to take it for a test spin.

Best regards,
Doc
Attachments
CustomProgressBar.zip
(2.61 KiB) Downloaded 139 times

doc
Posts: 148
Joined: Fri Jun 09, 2006 4:30 pm
Location: Oklahoma, USA

Re: Progress Bar: continual spin

Post by doc » Sat Dec 17, 2011 10:29 pm

I should note that you can easily code around using the reset button...
...I basically just used that while getting things set up, and didn't think about removing it.

-Doc-

Edit:
Added a slightly different variation in this test stack and without the reset button.
Attachments
CustomProgressBar2.zip
(22 Bytes) Downloaded 141 times

slylabs13
Posts: 10
Joined: Thu Jul 26, 2007 7:23 pm
Contact:

Re: Progress Bar: continual spin

Post by slylabs13 » Mon Dec 19, 2011 6:10 pm

I have created a simple Spinner runtime to address the problem of blocking operations preventing the spinner from animating. Apparently attachments here are very limited, so contact me off list at bobs @twft. com to get your hands on it. This is MAC ONLY, unless someone else wants to piddle with it to get it to work with Windows.

You run the app from a stack by executing a simple Applescript:
tell application "Spinner"
activate
end tell

You can then send the app a few commands:
to change the location: send "moveMe" && quote & theLoc & quote to program "Spinner" -- put the screen location into theLoc first!
to change the prompt: send "setPrompt" && quote & thePrompt & quote to program "Spinner" -- put some text into thePrompt first!
to show the spinner window: send "showMe" to program "Spinner" -- it starts up invisible
to hide the spinner window: send "hideMe" to program "Spinner" -- it floats above all windows, even those from other apps

I highly encourage anyone who wants, to add to it. The first thing it needs is the ability to change the kind of progress indicator it uses. Right now it has an animated gif of a spinning wheel, but a new command or property could be added along with some other animated gifs to change that. A real progress bar could also be added that you could send a percentage to fairly easily.

sturgis
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 1682
Joined: Sat Feb 28, 2009 11:49 pm

Re: Progress Bar: continual spin

Post by sturgis » Mon Dec 19, 2011 6:51 pm

If you zip it first it should attach ok.

slylabs13
Posts: 10
Joined: Thu Jul 26, 2007 7:23 pm
Contact:

Re: Progress Bar: continual spin

Post by slylabs13 » Mon Dec 19, 2011 7:00 pm

sturgis wrote:If you zip it first it should attach ok.
I did. It was rejected for being too large.

sturgis
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 1682
Joined: Sat Feb 28, 2009 11:49 pm

Re: Progress Bar: continual spin

Post by sturgis » Mon Dec 19, 2011 7:03 pm

Ah k. Knew that! *hides*

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2776
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: Progress Bar: continual spin

Post by mwieder » Mon Dec 19, 2011 7:05 pm

It's also basic spammer rejection - you have to have built up a certain credibility here by x number of posts before you can attach files.

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”