Re: Need to filter out items of list

2014-06-03 Thread Geoff Canyon
As always, YMMV. I created a stack with two fields. Ran this script once: on mouseUp repeat with i = 1 to 15 repeat 20 if random(4) 1 then put random(100) - 30 after R put tab after R end repeat put cr into char -1 of R end repeat put R into fld

Flappy bird clone takes = 9 hours in Swift

2014-06-08 Thread Geoff Canyon
Apparently it was 9 hours with some interruptions. If we're talking basic functionality -- fly the bird, flap the wings, move the pillars left and count how many the user has passed, collision detection, start/end games and high score tracking -- then I'm guessing this wouldn't go much faster in

Re: please help!!

2014-06-09 Thread Geoff Canyon
I created a test stack. I created six buttons and grouped them. I ran the following in a seventh button. It never failed. I'm using 6.5.2. Somewhere along the way the more specific childControlIDs was added. I didn't know if it is available in 6.1.1 so I didn't use it. on mouseUp repeat 1000

Re: Put a stack into a variable?

2014-06-14 Thread Geoff Canyon
On Fri, Jun 13, 2014 at 9:26 AM, Richard Gaskin ambassa...@fourthworld.com wrote: I'd like to put a stack into a variable, but without reading the stack file from disk. Other languages have first class functions, you want first class stacks. ;-) ___

Re: Nested Repeat loops

2014-06-20 Thread Geoff Canyon
It's hard to say without context, but one way to handle things like this is to fold it all into a function/handler. Then if you want to exit you can exit/return. On Fri, Jun 20, 2014 at 8:55 PM, J. Landman Gay jac...@hyperactivesw.com wrote: I've needed that too occasionally but I've always

Checking on the status of playing sounds in LC

2014-07-09 Thread Geoff Canyon
Am I correct that LC's support for playing multiple sounds simultaneously is limited? For example, if I wanted to make a guitar simulator, allowing the user to play the strings individually and in chords would be difficult? Or has that improved? gc ___

Re: Checking on the status of playing sounds in LC

2014-07-10 Thread Geoff Canyon
On Wed, Jul 9, 2014 at 4:25 AM, Scott Rossi sc...@tactilemedia.com wrote: Mobile is multi-channel. Ooh, seems like a winner (I wasn't planning to build for desktop anyway). ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit

Re: Dragging an object

2014-07-12 Thread Geoff Canyon
On Fri, Jul 11, 2014 at 12:14 AM, Richmond richmondmathew...@gmail.com wrote: on mouseUp set the moveSpeed to 65000 put item 2 of the loc of me into LCK move me to ZZZ, LCK end mouseUp where 'ZZZ' is the fixed lateral location. I've set the moveSpeed way up high so the movement is

Re: Dragging an object

2014-07-12 Thread Geoff Canyon
On Thu, Jul 10, 2014 at 7:24 PM, Peter Bogdanoff bogdan...@me.com wrote: How can I drag it by clicking on one side of this group? local xOff -- the offset for dragging local dragging -- the flag set for dragging on mouseDown put item 1 of the loc of me - item 1 of the mouseLoc into xOff

Re: Conflicting paths

2014-07-12 Thread Geoff Canyon
On Wed, Jul 9, 2014 at 3:29 PM, Richmond richmondmathew...@gmail.com wrote: now img Saturns trots smoothly round my rather jagged, freehand oval, BUT img Mars jerks and pauses like an alcoholic on a major binge-drink. Getting back to this original question -- I can't replicate this in 6.5.2

Re: Speed

2014-08-23 Thread Geoff Canyon
This has several restrictions, but it generates all permutations of 10 items in about 6 seconds on my recent macbook. It uses two functions, one to generate a permuted list of single digits, and the other to replace in the actual items to be permuted. The restrictions are: 1. The general

Re: Re : Speed

2014-08-25 Thread Geoff Canyon
On Sun, Aug 24, 2014 at 11:09 AM, Beat Cornaz b.cor...@gmx.net wrote: I am a bit at a loss, as I would be surprised if my way would be like 25 times faster than the fastest known algorithm. Did I make a mistake in implementing Dicks code (although Dick also reports 2 minutes to do the job, as

Re: Re : Speed

2014-08-25 Thread Geoff Canyon
On Mon, Aug 25, 2014 at 6:21 AM, Beat Cornaz b.cor...@gmx.net wrote: But I think it quite a pity (to put it mildly) that LC 6.xx is so much slower thank 5.5. Could it be the unicode implementation? Agreed, that would be unfortunate. It would be nice to have a text setting for fields.

Re: Re : Speed

2014-08-25 Thread Geoff Canyon
This routine will permute to any depth that memory/time allows. It has the added benefit of using characters starting from any ASCII value you like, allowing you to work around what you want to eventually permute using the PLines routine. It also has the speed benefit you get from using items

Re: Speed

2014-08-26 Thread Geoff Canyon
On Tue, Aug 26, 2014 at 1:57 PM, Peter M. Brigham pmb...@gmail.com wrote: A followup on how to handle duplicate characters in the permuting algorithm. The following seems to work, not sure how it will scale. tString can contain any characters -- duplicates, digits, spaces, whatever. I don't

Re: permuting a string (was Re: Speed)

2014-08-29 Thread Geoff Canyon
On Wed, Aug 27, 2014 at 9:33 AM, Beat Cornaz b.cor...@gmx.net wrote: So, getting rid of the duplicates inside the script is quite important. I still don't see yet how I can do that in Geoff's script (I will look into that again, as soon as I can find a little time). If we can get that to

Re: permuting a string (was Re: Speed)

2014-08-30 Thread Geoff Canyon
On Sat, Aug 30, 2014 at 7:24 AM, Beat Cornaz b.cor...@gmx.net wrote: Sat, 30 Aug 2014 Geoff wrote : Used Alex's code to generate a list of the permutations of all the characters that were duplicates. Substituted in unique characters for each instance of the duplicates. Ran my

Re: permuting a string (was Re: Speed)

2014-08-30 Thread Geoff Canyon
Gah -- now I'm not convinced that my way will work at all. I'll test and reply later. On Sat, Aug 30, 2014 at 8:19 AM, Geoff Canyon gcan...@gmail.com wrote: On Sat, Aug 30, 2014 at 7:24 AM, Beat Cornaz b.cor...@gmx.net wrote: Sat, 30 Aug 2014 Geoff wrote : Used Alex's code to generate

Re: permuting a string (was Re: Speed)

2014-09-01 Thread Geoff Canyon
I have a set of code that seems to do the trick. It takes as an argument the number of each element to permute. So for your examples: On Mon, Sep 1, 2014 at 10:32 AM, Beat Cornaz b.cor...@gmx.net wrote: On my computer : Input : 1112223334568320 mSec Input : 1233

Re: permuting a string (was Re: Speed)

2014-09-01 Thread Geoff Canyon
On Mon, Sep 1, 2014 at 10:32 AM, Beat Cornaz b.cor...@gmx.net wrote: This is my fastest script so far : I think this is faster for many arguments. It might be slower for others. I removed the dependency on an external routine for removing duplicates. It also removes duplicates only when

Re: Speed testing: Fastest search method

2014-09-01 Thread Geoff Canyon
On Sun, Aug 31, 2014 at 4:04 PM, Alex Tweedly a...@tweedly.net wrote: I also added method4, which tries to get the best of both worlds. It restricts the additional memory usage (by building up a second variable, but removing sections of the input variable at the same time), and also does

Re: Strange group behavior

2014-09-01 Thread Geoff Canyon
I've experienced something that might be related. For several versions, culminating in 6.6.x, the activation dialog had multiple invisible controls, making it very difficult for me to activate LC. I also found that sometimes whole groups would go invisible in my stacks. I never found a consistent

Re: permuting a string (was Re: Speed)

2014-09-03 Thread Geoff Canyon
On Tue, Sep 2, 2014 at 1:45 PM, Beat Cornaz b.cor...@gmx.net wrote: Mon, 1 Sep 2014 19:47:58 -0500 From: Geoff Canyon gcan...@gmail.com I think this is faster for many arguments. It might be slower for others. Your right. The only thing with this script is, that it sometimes generates too

An interesting comparison with web development

2014-09-07 Thread Geoff Canyon
http://chromakode.com/post/notes-on-xkcd-pixels That's a description of how XKCD's Pixels panel http://www.xkcd.com/1416/ was developed using HTML 5 in three days. I wonder how long it would take in LiveCode. The basic parameters are: 1. Black and white 600x600 image, zoomable. 2. The zoom must

Re: Making data plots

2014-09-08 Thread Geoff Canyon
On Sun, Sep 7, 2014 at 3:49 PM, William Prothero proth...@earthednet.org wrote: Also, I am assuming that if I delete a group, all of the objects in it are also deleted. Another possibility is to simply hide the group. That way creating another graph will likely be faster -- depending on your

Re: Making data plots

2014-09-08 Thread Geoff Canyon
I generally use a utility command, something like: on forceNControls pID,N put max(2,N + 1) into M repeat (the number of controls of pID) - M + 1 delete control M of pID end repeat set the vis of control 1 of pID to (N 0) repeat with i = (the number of controls of pID) to N - 1

Small code: leap year

2014-09-23 Thread Geoff Canyon
I came across http://exercism.io/about It's an interesting site for developers to improve their skills with simple problems and organized peer review. One of the simpler challenges is writing a function to return whether a year is a leap year. I wrote this: function isLeapYear Y return Y mod 4

Re: sort lines by length

2014-09-23 Thread Geoff Canyon
On Tue, Sep 23, 2014 at 2:07 PM, Klaus major-k kl...@major-k.de wrote: this compiles and kinda works, but not as exspected :-/ ... sort lines of fld 1 by length(each) You want: sort lines of fld 1 numeric by length(each) Otherwise a line with length 13 will sort before a line with length

Re: Population puzzle

2014-09-26 Thread Geoff Canyon
This is a fun problem. My first, nearly brute force solution simply maintained an array with the keys being the sum of the value lists stored in the array -- so X[5] might contain 2,3. The only optimization inherent in this is that it doesn't worry about duplicate sums along the way. So if there

Re: the price of a context switch/function call

2014-10-04 Thread Geoff Canyon
On Sat, Oct 4, 2014 at 12:54 PM, Dr. Hawkins doch...@gmail.com wrote: If I'm going to call a routine, say, 100 times in a fraction of a second, do I really save much by inlining it rather than calling it as a function? Premature optimization is the root of some evil. If you write clean code,

Re: the price of a context switch/function call

2014-10-09 Thread Geoff Canyon
I took just about the worst case scenario: a single-line function I wrote a few weeks back: function isLeapYear Y return Y is a number and Y mod 4 = 0 and (Y mod 100 0 or Y mod 400 = 0) end isLeapYear If any function is going to pay the price for the cost of a function call, that's it --

Re: problem with counting words

2014-10-12 Thread Geoff Canyon
Here's a function to count the words disregarding quotes. Note that it's important to replace quotes with space, because there are three words in this isthree words and there are three words in this isthree words but you want to count four words, which this will do: function

Re: problem with counting words

2014-10-13 Thread Geoff Canyon
When the new language code becomes available I am going to write an extension just for you, Richard... gc On Oct 13, 2014, at 11:03 AM, Richard Gaskin ambassa...@fourthworld.com wrote: I think most of us (except Geoff Canyon who has a rare mind for this sort of stuff g) would agree

Re: lock screen question and detect field question

2014-10-13 Thread Geoff Canyon
One caveat: if you are assembling a great deal of text in small chunks, you should likely do it in a variable and then toss it into the field in one go. Field updates are slower than many (most?) other things you might be doing, and one field update with 10,000 lines will be *much* faster than

Re: Yosemite?

2014-10-17 Thread Geoff Canyon
So far so good with LC -- and the new fonts/design are much better for my eyes. On Fri, Oct 17, 2014 at 3:02 AM, Tiemo Hollmann TB toolb...@kestner.de wrote: Hello, any Yosemite issues found yet or everything smooth? Tiemo ___ use-livecode

Benchmarking 7.0 performance

2014-10-27 Thread Geoff Canyon
I'm wondering if anyone has benchmarked 7.0 performance? I did two quick tests and found: on mouseUp put the long seconds into T repeat with i = 1 to 2000 put A aa into X end repeat put the long seconds - T end mouseUp Took almost 5x as long to run as on 6.7, which I

Re: deleting lines in a field

2014-10-27 Thread Geoff Canyon
Depending on the size of your data, something like this could be (much) faster: function removeLines lineList,S put 0 into lineCounter split lineList with comma as set repeat for each line L in S add 1 to lineCounter if lineList[lineCounter] then next repeat put L cr

Re: hilitedline

2014-10-27 Thread Geoff Canyon
I replied in the other thread as well, but: function removeLines lineList,S put 0 into lineCounter split lineList with comma as set repeat for each line L in S add 1 to lineCounter if lineList[lineCounter] then next repeat put L cr after R end repeat return char

Re: deleting lines in a field

2014-10-28 Thread Geoff Canyon
On Mon, Oct 27, 2014 at 5:41 PM, Bob Sneidar bobsnei...@iotecdigital.com wrote: I’m kind of surprised at these suggestions. Why not rather build a memory variable containing the lines that are not selected, then replace the field with the variable? That's what the function I posted does.

Re: (Arbitrarily) Long-Division Script

2014-10-31 Thread Geoff Canyon
I've created similar routines in the past. Are you saying you do or don't want to allow for arbitrarily-large divisors? a pseudo-code algo for divisors that LC can handle: 1. remove the decimal points, remembering where they were 2. get the length of the divisor 3. grab that many characters from

Re: (Arbitrarily) Long-Division Script

2014-10-31 Thread Geoff Canyon
M - 3 to M of X) * (char N - M - 3 to N - M of Y) to S end repeat put char -4 to -1 of S before R delete char -4 to -1 of S end repeat if S is 0 then put empty into S return leadChar S R end bigTimes On Fri, Oct 31, 2014 at 11:32 PM, Geoff Canyon gcan...@gmail.com

Re: Major Bug in 6.7?

2014-11-05 Thread Geoff Canyon
On Tue, Nov 4, 2014 at 5:44 PM, Chipp Walters ch...@chipp.com wrote: I should mention I'm on Mac Yosemite. Also on Yosemite/6.7. Same here. ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe

Re: hair-pulling frustration

2014-11-12 Thread Geoff Canyon
On Wed, Nov 12, 2014 at 11:50 AM, Bob Sneidar bobsnei...@iotecdigital.com wrote: Let me just say that for some folks who do not have enough time to report bugs, they certainly have found an abundance of time to post their frustrations to this list! Just sayin’. It takes far less time to send

Re: hair-pulling frustration

2014-11-12 Thread Geoff Canyon
understand the need to not waste limited team resources on bad bug reports, but if the requirements are causing Jacque to fail to report a bug, that's a huge issue. On Wed, Nov 12, 2014 at 6:35 PM, Richard Gaskin ambassa...@fourthworld.com wrote: Geoff Canyon wrote: It takes far less time to send

Re: hair-pulling frustration

2014-11-13 Thread Geoff Canyon
On Thu, Nov 13, 2014 at 1:06 PM, J. Landman Gay jac...@hyperactivesw.com wrote: On 11/13/2014, 1:50 AM, Geoff Canyon wrote: if the requirements are causing Jacque to fail to report a bug, that's a huge issue. Well, to be fair, it doesn't always prevent me from reporting things. If I have

Re: hair-pulling frustration

2014-11-13 Thread Geoff Canyon
On Thu, Nov 13, 2014 at 3:10 PM, J. Landman Gay jac...@hyperactivesw.com wrote: I blame myself for the omissions (except when Richard G. forgives me.) :) Bless me Richard, for I have sinned. It has been two weeks since my last bug report. Since then I wrote three undocumented functions and one

Re: Comparison of Speed of LiveCode with PHP

2014-11-24 Thread Geoff Canyon
My PHP is weak, but if the memory access test is a regular array, then comparing it to a livecode array is somewhat apples and oranges, since LC is really a hash. But on the other hand, there's no way to do a simple array in LC, so it's not like you can do better. For the file access test, your

Re: Comparison of Speed of LiveCode with PHP

2014-11-25 Thread Geoff Canyon
On Tue, Nov 25, 2014 at 5:16 AM, Andre Garzia an...@andregarzia.com wrote: co-routines mmm, co-routines... ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription

Re: Missing properties

2014-12-07 Thread Geoff Canyon
On Sat, Dec 6, 2014 at 8:03 PM, Peter Haworth p...@lcsql.com wrote: Every now and again, I wonder why certain properties are not available in LC. The ones that puzzles me the most are the owning card and owning stack of an object. Do you mean some shortcut to get the owning card no matter

Re: I Hate the New Color Picker

2014-12-07 Thread Geoff Canyon
How does the color picker look different to you? I'm on Yosemite and it looks the same as I remember: color picker choices across the top: color wheel (default), color sliders, etc.; then the color wheel itself below that; then the saturation slider below that; then the actual color selected and

Re: Missing properties

2014-12-07 Thread Geoff Canyon
On Sun, Dec 7, 2014 at 12:12 PM, Peter Haworth p...@lcsql.com wrote: My point was that a lot of people have spent time coming up with various ways of getting a control's owning card/stack which to my way of thinking means there should be a built-in way of doing it. Agreed -- here's hoping

Re: Using polygon as line and childControlNames

2014-12-07 Thread Geoff Canyon
On Sun, Dec 7, 2014 at 4:17 AM, Terence Heaford t.heaf...@btinternet.com wrote: There seems to be a bug with childControlNames in LC 7.0.1(RC3) as it all works correctly in LC 6.7.1(RC3). I think perhaps your code is taking advantage of a quirk in LC. If you don't give an object a name, the

Re: Missing properties

2014-12-07 Thread Geoff Canyon
On Sun, Dec 7, 2014 at 5:17 PM, Monte Goulding mo...@sweattechnologies.com wrote: On the whole I'm not sure if there's a big advantage to implementing it in the engine but like I said it's not difficult. I'm assuming that once we have the new syntax definition capability something like this

Re: Using polygon as line and childControlNames

2014-12-08 Thread Geoff Canyon
On Mon, Dec 8, 2014 at 2:33 AM, Terence Heaford t.heaf...@btinternet.com wrote: Thanks, this does work but I am confused why childControlNames only returns POLYGON and not graphic id 1011 as graphic id 1011” is it’s actual name as I have not renamed it. No idea. It's not doing that for me.

Re: Missing properties

2014-12-08 Thread Geoff Canyon
On Mon, Dec 8, 2014 at 1:40 AM, Monte Goulding mo...@sweattechnologies.com wrote: I would expect adding a property to all objects to still need do be done in the engine. Why? I know we don't have detailed documentation on the syntax morphing functionality, but why would this be any different

Re: [OT]DryLab Plus v5.81 announcement

2014-12-08 Thread Geoff Canyon
On Mon, Dec 8, 2014 at 8:01 AM, revolut...@duncansoftware.on-rev.com revolut...@duncansoftware.on-rev.com wrote: 1994 for Windows 3.1 using ToolBook ... it has wandered through Authorware, Director, Flash, mTropolis, Oracle Media Objects, et al to finally and happily arrive at Livecode.

Re: Using polygon as line and childControlNames

2014-12-08 Thread Geoff Canyon
Mac with Yosemite 10,10,1 here. I've only checked in LC 7.0.0. On Mon, Dec 8, 2014 at 9:51 AM, Terence Heaford t.heaf...@btinternet.com wrote: I’m using a Mac with Yosemite 10.10.1 Are you Windows or Linux? That may explain it. All the best Terry On 8 Dec 2014, at 14:46, Geoff Canyon

Re: Using polygon as line and childControlNames

2014-12-08 Thread Geoff Canyon
Dec 2014, at 14:46, Geoff Canyon gcan...@gmail.com wrote: On Mon, Dec 8, 2014 at 2:33 AM, Terence Heaford t.heaf...@btinternet.com wrote: Thanks, this does work but I am confused why childControlNames only returns POLYGON and not graphic id 1011 as graphic id 1011” is it’s actual name

Re: Missing properties

2014-12-08 Thread Geoff Canyon
On Sun, Dec 7, 2014 at 7:47 AM, Geoff Canyon gcan...@gmail.com wrote: If the object in question is inside a group, you'd have to recurse your way out, or you could use: put word -5 to -1 of the long id of btn 1 or if you prefer: put word -5 to -1 of the long name of btn 1

Re: I Hate the New Color Picker

2014-12-08 Thread Geoff Canyon
patches. I was used to using multiple rows to record and manage multiple projects. I realize now that It’s no biggie, and I overreacted! I’ll build a better tool for what I need and offer to all to make up for petulance. Roger On Dec 7, 2014, at 10:59 AM, Geoff Canyon gcan

Re: I Hate the New Color Picker

2014-12-08 Thread Geoff Canyon
on a 21,5 inch iMac. https://www.dropbox.com/s/pkqwsgvu6i5q7tz/ColorPickerYosemite.png?dl=0 greetings, William 2014-12-08 19:57 GMT+01:00 Geoff Canyon gcan...@gmail.com: William, I'm with you: no small dot, no resizing -- vertically, at least -- I can make the color picker

Re: Missing properties

2014-12-08 Thread Geoff Canyon
On Mon, Dec 8, 2014 at 5:33 PM, Scott Rossi sc...@tactilemedia.com wrote: Admittedly, the cardOwnerID function could fail if a control was located within a nested group that was explicitly named “card id” but. . . Exactly why I did it the way I did. I do like the use of the id in returning

Re: Missing properties

2014-12-09 Thread Geoff Canyon
It's been a long time since I saw anything on the syntax extension functionality, but my recollection was that it was supposed to be the all-singing, all-dancing wonder of the universe -- meaning that if I wanted to use a C-like dot-notation (I don't, usually) that would be easy to build. And that

Re: I Love my Colour Picker

2014-12-10 Thread Geoff Canyon
Anyone here remember that way back when (maybe OS 7) if you set your Mac's calendar far in the future, maybe 2020, the crayon picker would change so the crayons' tips were worn down? On Wed, Dec 10, 2014 at 9:08 AM, Richmond richmondmathew...@gmail.com wrote: On 10/12/14 15:33, Roger Guay

Re: Missing properties

2014-12-10 Thread Geoff Canyon
On Wed, Dec 10, 2014 at 12:16 PM, Richard Gaskin ambassa...@fourthworld.com wrote: The main goal of OL is two-fold: to provide OS API access, and to allow custom components (libraries, widgets, etc.) to be integrated as smoothly in usage as engine-native routines and objects. I don't

Re: Missing properties

2014-12-10 Thread Geoff Canyon
On Wed, Dec 10, 2014 at 3:50 PM, Richard Gaskin ambassa...@fourthworld.com wrote: If longevity of language features is inversely proportionate to their value, C must be a total waste of time. :) Ha -- of course I'm not suggesting that; anyone who wants to take away repeat for each or URL

Re: controlids and controlnames properties

2014-12-15 Thread Geoff Canyon
Yes: the childControlIDs and childConbtrolNames only go one level down; anything in a group will not be reported. the controlIDs and controlNames list everything everywhere. So given this structure: card id 1002 group id 1007 [1007] | button Button [1004] | button Button [1006] put the

Anyone wired up the Cloudinary API?

2014-12-16 Thread Geoff Canyon
I'm thinking about uploading/retrieving images, and wondering if anyone has already done it? ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences:

Re: Vertically aligning text in a field

2014-12-19 Thread Geoff Canyon
What requirement am I missing that this isn't sufficient -- and capable of handling multiple fonts and font sizes throughout the text? get the formattedrect of line 1 to -1 of fld 1 set the topmargin of fld 1 to (the height of fld 1 - item 4 of it + item 2 of it) div 2 On Fri, Dec 19,

Re: Vertically aligning text in a field

2014-12-20 Thread Geoff Canyon
On Fri, Dec 19, 2014 at 2:32 PM, BNig bernd.niggem...@uni-wh.de wrote: Hi Geoff, I think I found a solution for variable textHeight and different fonts in a field. If the formattedRect breaks on mobile, then that's a bug for the LC team, but other than that, doesn't my two-line solution

Re: Scaling images and printing...

2014-12-20 Thread Geoff Canyon
Don't you have to set the lockLoc of the image to true to make the resizing stick reliably? On Thu, Dec 18, 2014 at 2:43 PM, Paul Dupuis p...@researchware.com wrote: I have a problem with scaling images and printing. I have the following portion of code where tObj is an image and tPrecent is

Re: [OT] HyperCard and the Interactive Web

2012-02-26 Thread Geoff Canyon
We're wandering a bit here, but I disagree completely, so of course I should reply ;-) Some 100 years ago, it was considered necessary to memorize log tables. That skill is now useless. I remember (near 50 here as well) learning how to derive a square root. That skill is also useless. I agree

Re: [OT] HyperCard and the Interactive Web

2012-02-26 Thread Geoff Canyon
It's interesting that you bring up the slaughterhouse analogy -- I've used it on many occasions to make the opposite point: I know that cows are butchered to make steaks. I've seen videos of it, in fact. I shouldn't have to learn how to do it to order at McDonalds. There's a world of difference

Re: [OT] HyperCard and the Interactive Web

2012-02-26 Thread Geoff Canyon
On Sun, Feb 26, 2012 at 12:14 PM, Richmond richmondmathew...@gmail.comwrote: Kids should learn how to think, but in the context of the environment they are/will operate in. Which may change at any moment; so the more things they are exposed to the better chance they have to adapt to

Re: [OT] HyperCard and the Interactive Web

2012-02-26 Thread Geoff Canyon
I think I still have a slide rule stashed away somewhere. It was my step-father's. I once asked (circa 1983) in a chemistry class if slide rules were allowed in addition to calculators, and everyone's head turned. Richmond, to your point, check out what MIT is doing with Scratch Jr.:

Re: [OT] HyperCard and the Interactive Web

2012-02-27 Thread Geoff Canyon
On Feb 27, 2012, at 2:36 AM, Richmond richmondmathew...@gmail.com wrote: ... it is valuable knowledge insofar as you then are aware that by eating meat you do it at a price; the suffering of vast numbers of animals, that can, quite easily be avoided. Having eaten veggie burgers, we'll have

Re: Failing to understand the oddities of the line chunk

2012-03-18 Thread Geoff Canyon
So from a consistency standpoint, you are certainly correct; putting something into a negative range should behave the same whether the chunk involved is characters, items, words, or lines. But I'd still argue that the use of into instead of before or after demands that the target resolve to a

Re: Failing to understand the oddities of the line chunk

2012-03-19 Thread Geoff Canyon
On Mon, Mar 19, 2012 at 12:54 PM, J. Landman Gay jac...@hyperactivesw.comwrote: I think it should behave the same way character selections do. A negative range has been a valid construct since HyperCard and is, actually, the only way to set the insertion point by script. It's a necessary

Re: Failing to understand the oddities of the line chunk

2012-03-20 Thread Geoff Canyon
I understand that this is what the engine returns when the selection is empty, and I'm prepared to accept it as a necessary method for the engine to describe an empty insertion point, but just because the engine reports char 13 to 12 doesn't mean the engine should accept setting the selection to

Re: revCopyFile

2012-03-21 Thread Geoff Canyon
Funny, I went through this just a week ago. I found four reasons to abandon revCopyFile for a shell command: 1. The sound. 2. It's slow. 3. For large numbers of commands it died on me. 4. It can't change the name of the file as part of the copy process. I was trying to turn 1,700 files in one

Re: revCopyFile

2012-03-22 Thread Geoff Canyon
be possible if I used put URL. Pete On Wed, Mar 21, 2012 at 11:35 AM, Geoff Canyon gcan...@gmail.com wrote: I went straight to the shell command, so I don't know for sure, but this sounds reasonable. There's also the overhead of spinning up AppleScript in the first place. If Apple is doing

Re: revCopyFile

2012-03-23 Thread Geoff Canyon
I posted it earlier. Here it is again. *on* shellCopyFile tSource,tTarget -- tSource and tTarget are both full paths *get* shell(cp quote tSource quote quote tTarget quote) *if* it is not empty *then* *-- handle errors here* *end* *if* *end* shellCopyFile On Thu, Mar

Re: revCopyFile

2012-03-23 Thread Geoff Canyon
No clue how it would work on Windows. Here it is again: *on* shellCopyFile tSource,tTarget -- full paths *get* shell(cp quote tSource quote quote tTarget quote) *if* it is not empty *then* *-- handle errors here* *end* *if* *end* shellCopyFile On Thu, Mar 22, 2012 at

Re: revCopyFile

2012-03-23 Thread Geoff Canyon
. That's an inconvenience because it means extra coding, but not a show stopper. Thanks, Pete On Wed, Mar 21, 2012 at 11:25 PM, Geoff Canyon gcan...@gmail.com wrote: The advantages derive from the fact that LiveCode isn't doing the actual copying with revCopyFile -- the Finder

Re: Collisions

2012-03-25 Thread Geoff Canyon
This works only if the balls hit head-on. Otherwise you need to do the trig. As a simple example, say there are two balls headed toward each other. Each has a radius of 2^.5. Ball A is moving at -2 units per second on the x axis, i.e. to the left, and its center has a Y coordinate of 2. Ball B is

Re: Clean Plugins

2012-03-28 Thread Geoff Canyon
You're asking me about something I haven't touched in about ten years. ;-) I don't think I did anything in particular other than prefix the stack name with rev so it wouldn't show up in stack lists unless the show rev stacks item in the preferences was set. Other than that, as Richard said, it's

Re: Progress Bar

2012-03-31 Thread Geoff Canyon
I'll throw my 2 cents in here as well -- I've found that it doesn't impact performance significantly to check ticks() each time through the loop. So instead of a fixed number of iterations, which can lead to a jumpy progress bar or excessive updates if what you're doing in the loop varies much,

MobGUI, what am I doing wrong?

2012-04-05 Thread Geoff Canyon
I have a field object, a button object, and a browser object. If the button script is this, it works as expected: *on* touchEnd pId mobGUIUntouch the long id of me *put* the uText of *group* URL into tURL *if* char 1 to 7 of tURL is not http://; *then* *put* http://; beforetURL

Re: MobGUI, what am I doing wrong?

2012-04-06 Thread Geoff Canyon
I figured it out. I had forgotten to include global gBrowserA :-/ On Thu, Apr 5, 2012 at 8:20 AM, Geoff Canyon gcan...@gmail.com wrote: *on* touchEnd pId mobGUIUntouch the long id of me *put* the uText of *group* URL into tURL *if* char 1 to 7 of tURL is not http

Is this possible on iOS?

2012-04-09 Thread Geoff Canyon
For most of my apps I build a launcher that then loads the actual working stack from a remote location. I assume that's impossible due to Apple's restrictions on loading code remotely. But is it possible to save out a stack from the app locally, allowing it to be saved periodically and loaded

Re: Interesting breach of iOS terms or something for LC users?

2012-04-18 Thread Geoff Canyon
This would be the best job ever. On Wed, Apr 18, 2012 at 12:27 PM, Colin Holgate co...@verizon.net wrote: As an aside to your aside… the husband of a ex-colleague of mine was the person the studio turned to when figuring out the things MacGyver could do. They would call him up and say

Re: Chained Behaviors

2013-07-13 Thread Geoff Canyon
Can you share this 200-line handler? Sent from my iPad On Jul 12, 2013, at 3:31 PM, J. Landman Gay jac...@hyperactivesw.com wrote: One of the mouseUp behaviors is 200 lines long. ___ use-livecode mailing list use-livecode@lists.runrev.com Please

Re: Managing Long IDs?

2013-07-16 Thread Geoff Canyon
Arrays are your friend here. If that's too much trouble, you could switch to numtochar(N) with N 9, or simply escape the commas on the way in and out, but still: arrays. Sent from my iPad On Jul 15, 2013, at 6:30 PM, Scott Rossi sc...@tactilemedia.com wrote: For example, a line contains an

Reliable script to handle selection/drag-and-drop in a list field?

2013-07-17 Thread Geoff Canyon
Does anyone have code to share that allows discontiguous selection and drag and drop within a list field? i.e. if I have a list field with: 1 2 3 4 5 I can click 3 to select it, shift-click 5 to select 3 to 5, command-click 4 so that 3 and 5 are selected, and then click and drag 3 (with 5 along

Re: Reliable script to handle selection/drag-and-drop in a list field?

2013-07-18 Thread Geoff Canyon
, Jul 17, 2013 at 1:51 PM, Geoff Canyon gcan...@gmail.com wrote: Does anyone have code to share that allows discontiguous selection and drag and drop within a list field? i.e. if I have a list field with: 1 2 3 4 5 I can click 3 to select it, shift-click 5 to select 3 to 5, command-click 4

Re: Reliable script to handle selection/drag-and-drop in a list field?

2013-07-22 Thread Geoff Canyon
On Mon, Jul 22, 2013 at 3:44 PM, Peter Haworth p...@lcsql.com wrote: Resending because the original got caught in the dreaded message is too long vortex. This is very useful, thanks Geoff. I can't quite figure out what's going on with the format statement that's part of the send of

Re: Reliable script to handle selection/drag-and-drop in a list field?

2013-07-22 Thread Geoff Canyon
that message with dragLines = 12,18 and dropLines = 1,2 gc On Mon, Jul 22, 2013 at 4:03 PM, Geoff Canyon gcan...@gmail.com wrote: On Mon, Jul 22, 2013 at 3:44 PM, Peter Haworth p...@lcsql.com wrote: Resending because the original got caught in the dreaded message is too long vortex

Re: Reliable script to handle selection/drag-and-drop in a list field?

2013-07-23 Thread Geoff Canyon
/13 9:39 AM, Klaus major-k kl...@major-k.de wrote: Hi Geoff, Am 18.07.2013 um 18:23 schrieb Geoff Canyon gcan...@gmail.com: I did some quick research, and this looks to be as much of a pain as I remember -- or am I missing something? All I want is to place a scrolling list field

Re: Reliable script to handle selection/drag-and-drop in a list field?

2013-07-23 Thread Geoff Canyon
, UX/UI Design On 7/21/13 11:45 AM, Geoff Canyon gcan...@gmail.com wrote: Thanks Kaus for pointing it out, and particularly Scott who wrote the thing in the first place. When I think back on all I went through with Navigator trying to make the built-in drag-drop messages work (badly) it's

Re: Reliable script to handle selection/drag-and-drop in a list field?

2013-07-23 Thread Geoff Canyon
On Tue, Jul 23, 2013 at 12:34 PM, Peter Haworth p...@lcsql.com wrote: It looks like this is probably not going to work as a behavior for me since the field I'm using it on includes mouseUp/Down handlers to handle situations other than drag/drop, but other than that, this is great, thanks

  1   2   3   4   5   6   7   8   9   10   >