Re: On the dangers of automated refactoring

2021-04-14 Thread Peter W A Wood via use-livecode
Thanks Andre

I enjoyed putting the library together though at the time unit testing and 
LiveCode just don’t go together. Personally I find developing with tests gives 
me peace of mind about my code. 

As for refactoring, normally defined as the process of improving code without 
changing it’s behaviour, having a set of tests make it so much more productive.

LiveCode provides a really great platform for unit testing. The language makes 
it so much more simple to write unit tests of GUIs than any other language that 
I know. Even my small testing library could drive a GUI script.

I don’t spend much time with LiveCode these days. I always wanted to explore 
the multimedia capabilities of LiveCode which seem to surfing off into the 
ether. I never really put the time into getting on top of the multimedia 
aspects of LiveCode and, in all probability, lack the creativity to build 
anything of note.

PS Red Lang is going slowly. I haven’t been involved for a while. It’s mainly 
legacy Rebol, JavaScript, a little Lua and more JavaScript work for me these 
days.

> On 13 Apr 2021, at 19:10, Andre Garzia via use-livecode 
>  wrote:
> 
> Peter,
> 
> This is neat!
> 
> I also have a small test library, but mine is way less complete than yours. I 
> never released it because it was quite incomplete.
> 
> Maybe writing a tutorial or doing a small screencast showing it working might 
> help people understand why it is important. I bet many here never used a unit 
> testing library.
> 
> PS: How’s Red Lang going? :D
> 
>> On 13 Apr 2021, at 12:02, Peter W A Wood via use-livecode 
>>  wrote:
>> 
>> Hi Andre
>> 
>>> On 13 Apr 2021, at 18:05, Andre Garzia via use-livecode 
>>>  wrote:
>>> 
>>> We don’t even have unit testing libraries so that we can make sure our code 
>>> works as expected.
>> 
>> I published a simple unit testing library on GitHub but it din’t get any 
>> traction - https://github.com/PeterWAWood/LiveCode-MiniTest 
>> <https://github.com/PeterWAWood/LiveCode-MiniTest>
>> 
>> Peter
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: On the dangers of automated refactoring

2021-04-13 Thread Peter W A Wood via use-livecode
Hi Andre

> On 13 Apr 2021, at 18:05, Andre Garzia via use-livecode 
>  wrote:
> 
> We don’t even have unit testing libraries so that we can make sure our code 
> works as expected.

I published a simple unit testing library on GitHub but it din’t get any 
traction - https://github.com/PeterWAWood/LiveCode-MiniTest 


Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: ...and a challenge

2019-10-05 Thread Peter W A Wood via use-livecode
Colin

> On 6 Oct 2019, at 11:34, Colin Holgate via use-livecode 
>  wrote:
> 
> Pi is a reserved work, so I used pie. I haven’t seen this way of producing Pi 
> before, and in both JavaScript and LivceCode it seems to be instantaneous. I 
> think it’s a rewording of 4*(1-1/3+1/5-1/7+1/9…)

…

> set numberformat to “x.xxx"
> 
Your solution seems to be missing a few hundred thousand digits ;-) The 
JavaScript solution prints the first 1,000,000 digits of Pi.

Actually, the article says that the script only can produce 1,000,000 digits 
when run in a Chrome console. It will only print the first 315,633 digits in 
Firefox. (I haven’t tried that to confirm it.)

...


> BTW, I haven’t seen JavaScript using ‘let’ before, or having ’n’ to indicate 
> a floating point number. That could be a dot net thing.

“Let” was introduced into JavaScript some time ago. It provides block-level 
scope. This console session may demonstrate the difference:
>>> j = 0;
0
>>> for (var j = 0; j < 10; j++) {};
>>> print(j);
10

>>> k = 0;
0
>>> for (let k = 0; k < 10; k++) {};
>>> print(k);
0

Big Integer support was recently introduced into JavaScript. The ’n’ suffix 
denotes a Big Integer, “primitive” numbers are always floats in JavaScript.

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: [OT] Working with Android devices

2018-09-14 Thread Peter W A Wood via use-livecode
Many thanks Jacque, Richard and Bob.

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


[OT] Working with Android devices

2018-09-14 Thread Peter W A Wood via use-livecode
I have recently got an Android tablet and am seeking advice on how best to work 
with it in general, not so much with Livecode yet. My main machine is a Mac. I 
would like to be able to easily swap files with the Android tablet via wifi and 
to remotely login to it from the Mac. I am hoping that I can do so over the 
local wifi rather than having to connect the Android tablet via USB.

I have a couple of Raspberry Pis on which I installed netatalk so that I can 
access their file systems in macOS Finder. It makes swapping data between the 
Mac and the Raspberry Pi a simple matter of drag and drop. Does anybody know if 
it is possible to install netatalk on an Android device?

I usually use SSH to run programs on the Raspberry Pi. I see that there is an 
app called SSHDroid. Has anybody used it or something similar? 

When I want to access the Raspberry Pi desktop, I connect to the VNC server 
running on the Raspberry Pi. Is anybody connecting to their Android "tablet 
top” from a Mac? How do yo do it?

Sorry about going off topic.

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re [OT] Snakey Problem

2018-08-13 Thread Peter W A Wood via use-livecode
Richmond

I am no Python expert having only got over Pythonaphobia, which I contracted 
last century, in the last few months.

The standard Python library, which is included in the distribution, includes 
the TKinter GUI library. When Python starts up, it doesn’t load many of the 
standard libraries automatically. That’s why you need the imports before you 
use them. (It imports them from the standard library).

Here is the smallest hello Richmond program that I could find:

import tkinter as tk

gui = tk.Tk()
w = tk.Label(gui, text="Hello, Richmond!")
w.pack()
w.mainloop()

 
It should run in any standard Python3 distribution.

You might want to think about using the new Mu Editor which is aimed at 
beginners. It includes it’s own version of Python3 (3.6 in the current 
release). It’s website is https://codewith.mu  There’s an 
introduction to it at https://www.raspberrypi.org/blog/mu-python-ide/ 


Hope this helps

Peter

> On 13 Aug 2018, at 16:23, Richmond Mathewson via use-livecode 
> mailto:use-livecode@lists.runrev.com>> wrote:
> 
> Like it or not (and mainly NOT), I have to offer Python to kids this fall . . 
> .
> 
> This is a b*gger for several reasons:
> 
> 1. I love LiveCode.
> 
> 2. To use Python to any effect apart from rather goofy manipulations with 
> numbers and text an install
> requires 'modules' which are usually installed using a daft command-line 
> system using something call
> 'PIP' [ "Permanently Injurious Python" perhaps? ] . . . which I have signally 
> failed to get to work on either
> Macintosh or Linux.
> 
> I wonder of anyone knows of a way to install Python 3 on Linux with the main 
> GUI modules "bound in":
> i.e. a one-stop install.
> 
> Frankly, Python, by using this module system seems to defeat itself to a 
> certain extent: or, maybe I'm just
> spoilt by LiveCode.
> 
> This question is very timely as Wednesday is Nag Panchami: the day of snakes!
> 
> Richmond.
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com 
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Livecode Content Management System

2017-12-04 Thread Peter W A Wood via use-livecode
Andre

> I am talking beyond the current HTML5 deployment (which I don't own a
> license and can't play with)

I thought that you can deploy to HTML5 with the community licence. The GPL 
wouldn’t put you off playing with it, would it?

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Call for Speakers 2018

2017-10-24 Thread Peter W A Wood via use-livecode
On 25 Oct 2017, at 09:34, Mark Wieder via use-livecode 
 wrote:

> That sounds like the last nail in the coffin for the actual conferences.

Sounds like a great opportunity for you to launch Mark Wieder Event Management 
Inc.

;-)

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: CouchDB, DayBed, etc.

2017-08-24 Thread Peter W A Wood via use-livecode
Alex 

> On 23 Aug 2017, at 22:28, Alex Tweedly via use-livecode 
>  wrote:
> 
> With the exception of a couple of things that basically scraped data off some 
> web pages, every app I've done in the last couple of years (all for personal 
> use by myself or friends - I'm a hobbyist) have shared one characteristic : 
> they have local storage, and that data is subsequently synched to "the cloud" 
> to be shared with other devices/users, or at the very least backed-up to the 
> cloud (i.e. my on-rev or HostM server account).
> 
> I haven't yet done anything on mobile - but because of where I live and other 
> circumstances, even for laptops I *need* to have things work without an 
> Internet connection and synch up when available.
> 
> This doesn't seem to fit well with, say, CouchDB; the REST API lets me do 
> great things when I talk to the server - but when working locally I have to 
> forego all those features, and, for instance, revert to an array which I 
> 'manually' search / filter / etc.

You can easily run CouchDB on a laptop or PC. There is a little more admin that 
SQLite but not very much. One of the strengths of CouchDB is it’s database 
synchronisation (one-way or both-ways) - 
http://docs.couchdb.org/en/2.1.0/replication/index.html 
.

There is also a mobile embedded Couchbase that should sync with CouchDB - 
https://developer.couchbase.com/mobile  
- I guess that would need a LiveCode Builder wrapper before it could be 
accessed from LiveCode.

Peter
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: First 1000 characters without loop?

2017-06-22 Thread Peter W A Wood via use-livecode
Richard

> How can we know which is in use for a given string?
> 
> Suppose I wanted to process a lot of text, so performance is critical. Using 
> bytes would be optimal, since any chunk type or even Unicode characters may 
> vary in length.
> 
> So if I wanted to create an index of byte offsets into a large chunk of text, 
> how would I know how long a character is?

Some Unicode characters, such as emojis, have to be represented by two 
codepoints in UTF-16 (known as surrogates) so they take four bytes not two. 
Additionally, the number of bytes for characters with accents will take either 
one codepoint or two depending on whether they have been coded in pre-composed 
or decomposed form. (e.g. ç can be either U+0063 U+0327 (decomposed) or U+00E7 
(precomposed).

So it is isn’t easy to estimate the number of bytes in a UTF-16 string.

I would guess that LiveCode will store the characters of a string in single 
bytes if all the letters of the string conform to ISO-8859-1. So if you can be 
certain that your text is all ISO-8859-1 encoded, you can estimate at 1 byte 
per character. (The guess is base on the fact that the first 256 Unicode code 
points replicate ISO-8859-1).

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Kognition Beta Test - call for volunteers

2017-04-28 Thread Peter W A Wood via use-livecode
Dear Kevin 

First, congratulations on reaching Beta stage of Kognition. Your description on 
if it is very intriguing.

I think I can offer you an interesting beta test environment. At the moment, I 
have three primary projects (and a number of smaller ones), the data for each 
is stored in diverse forms but, in most cases, very common forms. I think this 
would provide a good test of Kognition’s reach.

Here are the main data sources for each project:

Project 1
Atlassian JIRA - Cloud System - issue and task data
Atlassian HipChat - Cloud System with local client - project 
discussions including requests for action
Atlassian Confluence - Cloud System - project documents
Google Calendar  - Cloud System - project meeting schedule
Google Mail - Cloud System - project email and notifications 
(no local copies)
Project Artefacts - Local Files - documents (markup, pdf), 
code, binary data

Project 2
Google Docs - Cloud System - documents, spreadsheets, 
presentations
AltME Messaging System - Local Files - documents (text, markup, 
pdf), to-do lists, contact list, chat
Project Artefacts - Local Files -  documents (markup, pdf), 
code, binary data
Email (Apple Mail.app) - Local Files - messages + attachments

Project 3
Gitter - Cloud System - project discussion with actionable items
Github - Cloud System - project issues, documentation (markup)
GitBook - Cloud System - published documentation
Trello - Cloud System - project tasks
Blogger - Cloud System - website source and management, user 
comment management
Website - Cloud - project website
Google Groups - Cloud System - membership data, messages
Google Mail - Cloud System - project email

I believe that would provide a good test of Kognition’s data acquisition 
capabilities though the relationships between the data will be relatively 
simple.

I have a MacBook Pro(Retina, 15-inch, Mid 2014), it has a 2.5 Ghz Intel Core 
i7. 

Best regards

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Installing LiveCode Server on a Microsoft Azure Bitnami LAMP stack

2016-11-24 Thread Peter W A Wood
Dave

> On 24 Nov 2016, at 19:46, Dave Kilroy  wrote:
> 
> Hi all
> 
> I’ve contracted a smashing guy with great server experience but who is new to 
> LiveCode install LiveCode Server on a Microsoft Azure Bitnami LAMP stack for 
> me - and it’s great working with someone who knows what they’re doing
> 
> However we’re stuck - could you clever people have a look at this thread 
> http://forums.livecode.com/viewtopic.php?f=20=28354=148772#p148772 
>  and 
> pass on your suggestions as to how to get it working?
> 
> Thanks in advance!
> 
> Dave
> 

It might be the Apache is being fussy about the lack of a trailing “/“ in the 
Script Alias or giving the name of an executable when a directory is required.

These are the relevant parts of the config I use happily with Apache 2.4:
 
ScriptAlias /livecode-cgi/ "/Users/peter/Sites/LiveCodeServer/“


AllowOverride None
Options +ExecCGI
Require all granted


AddHandler lcscript .lc
Action lcscript /livecode-cgi/livecode-server

Hope this helps.

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Practical TDD in LiveCode

2016-11-04 Thread Peter W A Wood
Richard

> On 5 Nov 2016, at 01:51, Richard Gaskin  wrote:
> 
> One of many interesting discussions in our local LC User Group meeting last 
> night was from a relative newcomer who asked about TDD support.
> 
> I was able to tell him we have an assert command, and that many developers 
> have a wide range of ad hoc test harnesses in use.
> 
> But what I couldn't point him to is a single harness framework in our 
> community suitable for broad use.
> 
> Is there one?

People’s opinion of what is needed for TDD differs widely. The so called xUnit 
testing frameworks are generally quite basic (test specification, assertions 
and test runners) but suffice for many people. They typically cannot be easily 
used to test GUI code. Other testing frameworks, it seems especially in the 
JavaScript world, extend much farther with test doubles, code coverage, and 
testing user interfaces via the browser.

I have published a simple test framework, Mini-Test. It can be used to test 
both LiveCode handlers and GUI interfaces. (This is latter is a credit to 
LiveCode’s features not me). It is rooted in MiniTest, the testing framework 
included with Ruby. It does not include test doubles, code coverage or 
performance testing.

LiveCode, the company, has a test framework but, personally, I found it too 
complicated for my own use. I felt something written wholly in LiveCode would 
be easier to handle.

If you want to take a look: https://github.com/PeterWAWood/LiveCode-MiniTest


> If not, what would it look like?
> 
> How granularly should we write tests?  How much value is there if the writing 
> of a test takes longer than writing the thing being tested? Should we write a 
> second test for when a handler in our core business logic is integrated into 
> a GUI, where the varieties of things that can happen with input and events is 
> much broader?  Should a good harness simulate GUI events?  If so, how to make 
> sure they attempt sufficient erroneous inputs to ensure the scope of our 
> error handling?  How do we chain tests into a comprehensive automated "Test 
> All"?
> 
> So many questions...
> 
> How do we make one good test harness that answers them all, at least 
> reasonably well?

I feel that the LiveCode engine makes it extremely easy to write a test 
framework that will do all of the above. It just needs a little thought, such 
as designing a set of commands to automate user input simulation, and a little 
work.

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: LC8 - Stumbling into JSON

2016-06-13 Thread Peter W A Wood
Mark 

> On 14 Jun 2016, at 07:19, Mark Wieder  wrote:
> 
> And just FYI, for comparison the xml translation of that would be
> 
> 
>  
>18.75
>kg/m@2
>  
>  
>2
>75
>  
> 
> 

Wouldn’t an XML purist come up with the following, making it much more time 
consuming to process?


 
   18.75
 
 
   2
   75
 


Regards

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Daft "text Editor" question

2016-05-18 Thread Peter W A Wood
Richmond

> On 18 May 2016, at 18:03, RM  wrote:
> 
> Does anyone know of a word-processing type program that can open .rev and 
> .livecode
> files so that one can see ALL the scripts of ALL the objects in one long 
> document?

You can open them and read the scripts in BBEdit under OS X. I would imagine 
that the free version, TextWrangler, would be able to do the same.

I was also able to open them in Gedit on Ubuntu but Gedit complained about some 
of the “binary” data not being correctly encoded UTF-8. Again I could see the 
scripts.

> This may sound a bit daft, but I am considering "refactoring" the code-base 
> for my Devawriter Pro
> from pre version 7 to post version 7, and this will involve very many changes 
> in about 4 million
> lines of code, and, farnkly, I should like to automate that process as much 
> as possible.

That is a lot of code !!!

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Getting text into a Livecode field

2016-05-08 Thread Peter W A Wood
Richmond

> Thanks for that, although a single line 'thing' does
> not "Do for me" what the previous field did.
> 
> R.

Having to type titles of buttons and text of labels and fields of GUI objects 
into a contents property in a separate window is this issue to me. I find it 
counter intuitive. Every time I use the IDE, I have to remember to open the 
property editor to change the title of a button. It seems a little throwback to 
years gone by.

Regards

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Getting text into a Livecode field

2016-05-08 Thread Peter W A Wood
Richmond

The screenshot you displays has the Text Styling tab visible. Did you try 
clicking on the little house icon ?

Reagards

Peter


> On 8 May 2016, at 15:44, RM  wrote:
> 
> More: http://forums.livecode.com/viewtopic.php?f=6=27232
> 
> R.
> 
> On 7.05.2016 21:38, RM wrote:
>> So, I was mucking around trying to reduplicate/solve John Patten's
>> problem with Arrow Keys in Livecode 8 (I reduplicated them: 
>> http://forums.livecode.com/viewtopic.php?f=6=27225),
>> and thought I'd do what I usually do: enter some text in a field and do a 
>> quick "import snapshot"
>> to get a label on the stack.
>> 
>> So, I set up a new textField, and could find NO place in the Properties 
>> palette where I could enter
>> the text; when I tried to enter it via 'browse' in the textField itself that 
>> also failed.
>> 
>> Livecode 64 bit Linux.
>> 
>> Richmond.
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Revenue and the Open Source edition

2016-05-04 Thread Peter W A Wood
Monte

> On 4 May 2016, at 13:20, Monte Goulding <mo...@appisle.net> wrote:
> 
> 
>> On 4 May 2016, at 3:12 PM, Peter W A Wood <peterwaw...@gmail.com> wrote:
>> 
>> I think that you have missed out one way to contribute that would be very 
>> valuable to both the community and LiveCode. That is writing automatically 
>> runnable tests.
> 
> I did miss that!
> 
>> There is an automated test suite but it is kept under lock and key by 
>> LiveCode so that community members cannot contribute by submitting 
>> meaningful tests.
> 
> Actually this is not true. The tests and test runners are on GitHub and 
> therefore contributable (probably not a word???):
> - IDE https://github.com/livecode/livecode-ide/tree/develop/tests (this is 
> - LCB, LCS https://github.com/livecode/livecode/tree/develop/tests

And I missed them! It’s been some time since I last looked though.

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Revenue and the Open Source edition

2016-05-03 Thread Peter W A Wood
Monte

I think that you have missed out one way to contribute that would be very 
valuable to both the community and LiveCode. That is writing automatically 
runnable tests. There is an automated test suite but it is kept under lock and 
key by LiveCode so that community members cannot contribute by submitting 
meaningful tests.

I built my own simple testing framework 
(https://github.com/PeterWAWood/LiveCode-MiniTest 
) and have a handful of tests 
(https://github.com/PeterWAWood/LiveCode-Tests 
). (If you run 
the tests, you will see that some of them fail.).

A set of community developed automated tests would be a great resource that 
could be grown over time.

Regards

Peter

> On 4 May 2016, at 12:47, Monte Goulding  wrote:

> There are many ways we can get involved with the development of the platform. 
> All of these have been done by contributors since going open source although 
> I doubt this is a complete list:
> - C/C++/Objective-C/Java
>   - Contribute to the engine code by fixing bugs or adding features
>   - Contribute to the externals that come with LiveCode
>   - Contribute to or implement your own externals and release under a FOSS 
> license
> - LiveCode Builder
>   - Contribute to widgets and libraries that come with LiveCode
>   - Contribute to or implement your own widgets and libraries and release 
> under a FOSS license
> - LiveCode Script
>   - Contribute to the script only stack portions of the IDE (most of the code 
> in LC8)
>   - Contribute to or implement script libraries, frameworks and custom 
> controls and release under a FOSS license
> - Documentation
>   - Edit the dictionary entries and guides
>   - Create new guides and contribute
>   - Create learning resources and release under a FOSS license
>   - Answer questions on stackoverflow, the lists and forums, facebook etc
> - Testing
>   - Write good quality bug reports
>   - Find old reports, test in the latest version and comment with your results
> 
> Cheers
> 
> Monte
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Nelly the Elephant

2016-04-30 Thread Peter W A Wood
Richmond

> On 30 Apr 2016, at 19:47, RM  wrote:
> 
> soes anyone know of a desktop programs (Win/Lin/Mac) to calculate surrogate 
> pairs?

Dorry I don’t so of a desktop program … but this webpage should work offline as 
long as you don’t refresh the page - 
http://www.russellcottrell.com/greek/utilities/SurrogatePairCalculator.htm 


Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN} LiveCode List Processor - Version 1

2016-03-26 Thread Peter W A Wood
Mark 
> On 26 Mar 2016, at 23:13, Mark Wieder <mwie...@ahsoftware.net> wrote:
> 
> On 03/25/2016 11:21 PM, Peter W A Wood wrote:
>> I have found time to complete version 1 of my LiveCode List Processor. You 
>> can find it at https://github.com/PeterWAWood/LiveCode-ListProcessor
> 
> Nicely done.

Thanks.

> The save and load functions aren't there, though.

In the sense that they are totally missing or you feel they are insufficient? 

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


[ANN} LiveCode List Processor - Version 1

2016-03-26 Thread Peter W A Wood
I have found time to complete version 1 of my LiveCode List Processor. You can 
find it at https://github.com/PeterWAWood/LiveCode-ListProcessor

Many of you may be wondering why I bothered to write it when LiveCode’s 
built-in list processing (of delimited strings) is very good. The main reason 
is that LiveCode’s lists lack a memory. You can’t process a couple of items at 
the top of a list, go and do some thing else and then start processing the 
third item in the list. Well not easily. The List Processor does have a memory 
and you can move forwards and backwards along a list. The current position is 
even remembered when the list is saved.

A simple example of its use would be if you wanted to use some colours in turn. 
First you would make a list:

put LP.makeList(“red:green:blue:pink:purple:brown:black:”, “:”) into 
myColours

When you wanted to get the next colour, you would simply get the next item in 
the list:

put LP.next(myColours) into nextColour  #nextColour would be set to 
“green"

You can get the next colour

put LP.next(myColours) into nextColour  #nextColour would be set to 
“blue"

You can save the list

put LP.save(myColours, myURL) into tTemp 
# tTemp 
would be a binary copy of the list

You can load the list from the URL and get the next colour

put LP.load(myURL) into myColours
put LP.next(myColours) into nextColour  #nextColour would be set to 
“pink”

I suspect the number of uses of these lists with a memory is quite wide. I plan 
to use it to store data that I previously held in a set of cards. You can 
navigate through the list in a similar way to how you would navigate through 
cards. One small difference is that the lists don’t automatically cycle around 
from the last to first items as LiveCode cards do. (It would be easy to add 
that to the List Processor though).

When I was developing the List Processor, I wrote the tests using LiveCode 
MiniTest -https://github.com/PeterWAWood/LiveCode-MiniTest

The is some simple documentation on the Github page.

When writing the List Processor, I concentrated on getting it working correctly 
rather than speed. I’m sure that big improvements could be made and I would 
welcome comments and suggestions.

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Delete the first entry of an array.

2016-03-25 Thread Peter W A Wood
Thanks Kay

> On 25 Mar 2016, at 17:22, Kay C Lan <lan.kc.macm...@gmail.com> wrote:
> 
> On Fri, Mar 25, 2016 at 3:33 PM, Peter W A Wood <peterwaw...@gmail.com> wrote:
> 
>>  delete pList[“numbers”] 1 ## Is this 
>> the correct syntax?
> 
> No. Shouldn't it be:
> 
> delete variable pList["number"][1]
> 
> At least that works for me, although in your case I think, if I
> understand it correctly, I'd tackle the problem by: (suedo-code)
> 
> repeat with x = 2 to the number of keys in firstArray
>  put firstArray[x] into secondArray[x - 1]
> end repeat
> put secondArray into firstArray


I do something like this at the moment. I was trying to see if there was an 
easier/quicker way.

Kind regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Delete the first entry of an array.

2016-03-25 Thread Peter W A Wood
Peter

Thanks for the suggestions.

> On 25 Mar 2016, at 16:03, Peter TB Brett <peter.br...@livecode.com> wrote:
> 
> On 2016-03-25 08:33, Peter W A Wood wrote:
>> I have an array which contains a second array. (myArray[“numbers”][]).
>> ...
>> automatically change the index of the remaining entries?
> 
> Hi Peter,
> 
> LiveCode arrays are actually dictionaries (more like JavaScript objects than 
> JavaScript arrays).  There aren't currently any push/pop syntax for LiveCode 
> arrays.

Thanks for the confirmation as I wasn’t sure that was the case for all arrays 
due to the existence of the extents function.

> I would recommend two things:
> 
> 1) Arrange your algorithm so that you extract things one-by-one from the 
> _end_ of the numbered array, rather than the start.  This is more efficient!  

It is not possible in this case as the order of the elements is significant. I 
use a different function to remove the last element of the array.

> 
> 2) Alternatively, you can shift everything along, which will be slow:
> 
>   function PopStart @xArray
>  local tLength, tItem, tKey
> 
>  put the number of elements in xArray into tLength
>  if tLength is 0 then return empty
> 
>  put xArray[1] into tItem
> 
>  repeat with tKey = 2 to tLength
> put xArray[tKey] into xArray[tKey - 1]
>  end repeat
>  delete xArray[tLength]
> 
>  return tItem
>   end PopStart

This is what I am currently having to do but am not too worried yet as I 
believe in the “Getting it working, getting it working correctly, getting 
working quickly approach”.

> I hope that's helpful.

Thanks for the suggestions.

Kind regards

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Delete the first entry of an array.

2016-03-25 Thread Peter W A Wood
I have an array which contains a second array. (myArray[“numbers”][]). The 
numbers array is a traditional array with elements 1..n. I want to remove the 
first element of the numbers array and shuffle all the others up. Is there a 
simple way of doing this in LiveCode (equivalent to the shift() function in 
JavaScript)?

I looked in the dictionary and found delete  but couldn't get it to 
work, perhaps because I am trying to do this in a function that takes the array 
as an argument.

The essence of the function is:

function shift @pList
  local tItem
  put pList[“numbers”][1] into tItem
  delete pList[“numbers”] 1 ## Is this the 
correct syntax?
  return tItem
end shift

If I can get delete to remove the first element of the array, will it 
automatically change the index of the remaining entries?

Thanks in advance.

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Would love to see this blog with 1,001 Uses stay FRESH

2016-03-22 Thread Peter W A Wood

> On 22 Mar 2016, at 23:39, Richard Gaskin  wrote:
> 
> What is the process for submitting entries there?

Send me an email with a description/story of the app and a few screenshots. I 
use them to write an entry. I chose to always write the entry myself to 
establish and maintain a consistent style.

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Would love to see this blog with 1,001 Uses stay FRESH

2016-03-21 Thread Peter W A Wood
Mark 

There are two problems with keeping the blog fresh. The first is that people 
are not submitting possible entries. The second is that I don’t have the time 
to actively maintain it. I’m not sure which of these is the chicken and which 
is the  egg.

If somebody has the time and motivation to take over the site, I would gladly 
pass it over to them.

Regards

Peter

> On 16 Mar 2016, at 21:20, Mark Rauterkus  wrote:
> 
> Hi,
> 
> http://livecode1001.blogspot.com/
> 
> This is a great resource. I would LOVE to see it stay FRESH. A couple posts
> a month would be fine. I wanted to turn people onto LiveCode -- and seeing
> that with a most recent post from October 2015 is getting dated. Only two
> were posted in 2015.
> 
> Cheering from the distance
> 
> Can new energy be gathered?
> 
> 
> --
> Ta.
> 
> 
> Mark Rauterkus   m...@rauterkus.com
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: LC Server Call Javascript Function?

2016-01-29 Thread Peter W A Wood
Scott

> On 29 Jan 2016, at 18:30, Scott Rossi  wrote:
> 
> Can a LiveCode server script call a Javascript function?
> 
> I want to write some text into a div in an LC server web page without
> refreshing the entire page.  AFAICT, generating any text from a LiveCode
> server script will replace the contents of page, but cannot target a a
> specific DOM element on the page.  Since Javascript can do this, is there
> any way to trigger a Javascript function from an LC server script?

It is easy enough to do, if the JavaScript calls the LC Server Script. I 
believe that pushing content from the server to the browser can be achieved 
using the HTML5 WebSocket API (which will be a lot more complicated).

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: cipherNames

2016-01-17 Thread Peter W A Wood
John 

> On 17 Jan 2016, at 19:30, John Dixon  wrote:
> 
> When asking for the cipher names that are available to liveCode... a long 
> list is produced.. In the case of aes 256 there are many variants as depicted 
> by three letters after 'aes'... What do they mean ?... Is it important to use 
> the correct one ?
> 
> example of different cipher names in the list
> 
> aes-128-cbc,128
> 
….
> 
> aes256,256

They are different mechanisms for handling multiple blocks of data. (A block 
length being determined by the key length.). This may help 
https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: More questions regarding Server oddities

2015-12-25 Thread Peter W A Wood
Lyn

> On 26 Dec 2015, at 05:34, Lyn Teyla  wrote:

> 6.6.2 is not the latest version of LiveCode Server.
> 
> The suggestion that I had put forth regarding the original issue was for Tim 
> to perform both of the following:
> 
> 1. Use the "put header" line provided;

I don’t think the problem is related to the HTTP Header. It is the same for 
both Tim’s rev page and his lc page:



> 
> and
> 
> 2. Utilize any one of the latest versions of LiveCode: 6.7.8, 7.1.1 or 
> 8.0.0dp12.
> 
> That would indeed fix the original issue.

Tim doesn’t really have a choice over which version of the server to use with 
the On-Rev service. The version is chosen by LiveCode.

I suspect Tim will need to wait until LiveCode update the server before porting 
his scripts to .lc

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Livecode Server and script only stacks

2015-12-23 Thread Peter W A Wood
David

> On 23 Dec 2015, at 17:49, David Bovill  wrote:
> 
> I'm looking to produce a better coding experience for revIgniter / Livecode
> server, and I'd like to be able to use script only stacks on the server, so
> I can test code locally as stacks, and easily keep it versioned in Github
> and live on the site.
> 
> Does anyone know if script only stacks work with Livecode Server and if so
> which version of the server I need to be running?

Yes they do. I use them to run my tests under LiveCode Server - 
https://github.com/PeterWAWood/LiveCode-Tests/blob/master/ServerTestRunner.livecode
 
.

I run them under LiveCode 8.

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Death of the Application Browser

2015-11-26 Thread Peter W A Wood

> On 27 Nov 2015, at 04:26, Richmond  wrote:

> For exactly the same reason why the Application Browser is being hived off to 
> the "community",
> because, while Lip-service is being paid to listening to the community . . .

Given Mark Waddingham’s recent view of LiveCode stacks and GPL, if the 
Application Browser is hived off to the community anybody using it would only 
be able to sell it under the GPL. :-)

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Death of the Application Browser

2015-11-26 Thread Peter W A Wood
Monte 

> On 27 Nov 2015, at 06:29, Monte Goulding <mo...@appisle.net> wrote:
> 
> 
>> On 27 Nov 2015, at 9:24 am, Peter W A Wood <peterwaw...@gmail.com> wrote:
>> 
>> Given Mark Waddingham’s recent view of LiveCode stacks and GPL, if the 
>> Application Browser is hived off to the community anybody using it would 
>> only be able to sell it under the GPL. :-)
> 
> Actually that would appear to only be the case if the edits were made using 
> LiveCode Community as the IDE is MIT licensed:
> https://github.com/livecode/livecode-ide/blob/develop/IDE%20License.txt 
> <https://github.com/livecode/livecode-ide/blob/develop/IDE%20License.txt>

Given Mark’s earlier explanation, it is difficult to see how the IDE can be MIT 
licensed. After all, it is just a stack and if other stacks run with the 
Community engine can only be issued under the GPL, surely the IDE can only be 
issued under the GPL if it is run by the Community engine? In fact, surely 
anything distributed within LiveCode Community must be under the GPL? 

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN] LiveCode Blog (mostly)

2015-10-30 Thread Peter W A Wood
Scott

That is breathtaking. Thank you for sharing these wonderful insights.

Regards

Peter


> On 30 Oct 2015, at 18:33, Scott Rossi  wrote:
> 
> Hi All:
> 
> I started taking some past demos, articles, and techniques and put them
> into a blog which you might find interesting. http://tactilemedia.com/blog/
> 
> My hope is to eventually have all my demo stacks transferred to this
> medium, and will post new articles here when available.
> 
> Happy Friday.
> 
> Scott Rossi
> Creative Director
> Tactile Media, UX/UI Design
> 
> 
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Forcing string comparisons, or When is "0" not 0?

2015-10-15 Thread Peter W A Wood
Mark 

> On 16 Oct 2015, at 07:26, Mark Waddingham  wrote:
> 
> I think that is a combination of precedence ('is really a' binds more tightly 
> than '+') and the bug Paul noticed with regards 'constants' which are 
> currently represented as strings internally except in specific cases due to a 
> rather subtle issue with representations of numbers as strings.

I should have shown the code that I ran in the message box (multiline):

put "0" + 0 into tVar1
put tVar1 is really an integer

It returned false.

I added a test to my LiveCode tests. It also fails:

MT.startTest "Is Really 1"
put "0" + 0 into tTemp
MT.assert tTemp is really an integer
 MT.endTest

Should I open a bug report?

Warm regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Forcing string comparisons, or When is "0" not 0?

2015-10-15 Thread Peter W A Wood
Mark 

> On 16 Oct 2015, at 01:07, Mark Waddingham  wrote:
> 
>  put "0" + 0 into tVar1 -- tVar is really a number
>put "0" & 0 into tVar2 -- tVar is really a string
>put tVar1 is really tVar2 -- false

The current implementation appears to differ a little from the above. You need 
to specify integer or real as number is not currently supported.

When I try “0” + 0 in the message box only “is really a string” returns true, 
“is really an integer” returns false.

Warm regards

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN] LiveCode List Processor

2015-10-13 Thread Peter W A Wood
Thanks for the explanation Monte

> On 14 Oct 2015, at 08:33, Monte Goulding  wrote:
> 
> It’s a confusing topic. See the is really operator for more info. Under the 
> hood they are stored in the most efficient way they can be but it often 
> depends on the last operation:
> 
> put “1” into t — is really a string
> put “1”*1 into t — is really a number

I’m guessing that engine keeps a track of the type that each value is currently 
stored.

Cheers

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Is the assert command supported?

2015-10-13 Thread Peter W A Wood
Thanks Mark

> On 13 Oct 2015, at 15:52, Mark Waddingham <m...@livecode.com> wrote:
> 
> On 2015-10-13 08:59, Peter W A Wood wrote:
>> The assert command appears to be included in LiveCode 8 but is not
>> mentioned in either the dictionary or the user guide. All I’ve been
>> able to find about was in an article in RevUp -
>> http://newsletters.livecode.com/february/issue166/newsletter1.html
>> <http://newsletters.livecode.com/february/issue166/newsletter1.html>
>> Is it still supported? It is still experimental?
> 
> Still experimental - the main problem it was put in to solve was to be able 
> to test for error's being thrown from an expression. However, as it turns 
> out, its inflexibility doesn't really warrant its use and I wonder if the 
> 'assert' verb should actually be repurposed away from unit tests and to 
> general (simple) runtime assertions.

I was mis-using it for general (simple) runtime assertions when I wish to call 
a function and don’t use the returned value. I think it would be a good 
addition to the language.

> If you are looking to write unit-tests, then Peter recently put together a 
> super-simple LiveCode Script test runner which runs unit tests in the engine 
> after they are built under CI:
> 
> https://github.com/livecode/livecode/tree/develop/tests/lcs 
> <https://github.com/livecode/livecode/tree/develop/tests/lcs>

I have my own even simpler test framework, based on others I have used with 
other languages. It is very flexible and sufficient for my needs. It can be 
used to test both GUI stacks and Server stacks - 
https://github.com/PeterWAWood/LiveCode-MiniTest 
<https://github.com/PeterWAWood/LiveCode-MiniTest> 

Kind regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Is the assert command supported?

2015-10-13 Thread Peter W A Wood
The assert command appears to be included in LiveCode 8 but is not mentioned in 
either the dictionary or the user guide. All I’ve been able to find about was 
in an article in RevUp - 
http://newsletters.livecode.com/february/issue166/newsletter1.html 


Is it still supported? It is still experimental?

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN] LiveCode List Processor

2015-10-13 Thread Peter W A Wood
I’ve added a few more “easy” functions today - append, copy, empty?, head, 
head?, poke, tail and tail?. 

The List Processor’s API is documented at 
https://github.com/PeterWAWood/LiveCode-ListProcessor 


Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN] LiveCode List Processor

2015-10-13 Thread Peter W A Wood
Richard

> Richard Gaskin  wrote:
> 
> I've not used Rebol, but have read much of its documentation at various 
> points over the years.  Carl Sassenrath is an interesting thinker, and his 
> language reflects some very unusual and intriguing concepts.
> 
> Aside from MetaCard I've seen almost no other scripting language but Rebol 
> that wholeheartedly embraced the concept of delivering applications over the 
> wire.

Sadly it seems that the World was not ready at the time for a way to painlessly 
distribute both apps and data over what would now be considered very thin 
wires. Current App Stores and Web Push Notifications offer little more than the 
Rebol/View desktop and the even more advanced (IOS) Internet Operating System 
did more than ten years ago. The have a better looking interface and they can 
collect money. Probably nothing that couldn’t have been quite easily added to 
IOS. If only Carl had found a partner whose marketing prowess was the equal of 
his technical prowess.

Over the years, Rebol has become a general purpose development tool and its 
network roots have withered. I see a comparison with LiveCode which has grown 
into a general purpose development tool from its multimedia roots.

> Way back in the day I imagined I might have enough time to flesh out some 
> Rebol-like concepts in what was then called "Revolution", but this was as far 
> as I had time to go:
> 
>   go url "http://fourthworld.net/channels/Revel.rev”

A very realistic impersonation.
> 
> Underneath that would be a lightweight syntax for describing objects similar 
> to Rebol's auto-layout capabilities.  I made just enough of it to allow 
> sparse descriptions of objects and have them created on the fly in somewhat 
> reasonable locations, but never had the time to take it as far as Rebol did.  
> And like too many other things on my hard drive, without an immediate need 
> for using it in actual work, I can't say I have any plans to get back to it. 
> :)
> 
> I'd be interested in your opinion on Rebol dialects:
> 
> 
> They seem a key feature of the language, an opportunity to create 
> domain-specific languages from the core Rebol language.
> 
> In this regard it seems a similar set of goals to the proposed Open Language 
> initiative for LiveCode.  Not directly the same, but similar in the way that 
> many of Python's design goals almost perfectly parallel LiveCode's design 
> goals, even though the expression of those goals has taken very different 
> forms.
> 
> Do you have any thoughts on the strengths or weaknesses of Rebol's approach 
> vs LiveCode's for creating domain-specific dialects?

I believe Rebol (and what I see as it’s successor Red) has two significant 
advantages over LiveCode for writing domain-specific dialects., 

The first is that in Rebol values (not variables) are strictly typed. Values 
must be loaded in Rebol, once loaded a value is typed (e.g. integer). An 
integer can only be treated as a integer, there is no typecasting mechanism. As 
I understand, LiveCode has very few types, mainly everything is a string except 
for arrays and (maybe) objects. (I say maybe as my knowledge of LiveCode is 
insufficient in the area of how Objects are stored.)

The second is Rebol’s parse function which operates on loaded data and can 
match on both data and datatype. This is a huge advantage in writing domain 
specific dialects. (Parse also operates on strings and can do 99% of what can 
be done with regex, and a lot more, legibly and comprehensively).

> >> To be fair '?' poses less of a problem in this regard than '.' - in
> >> terms of limiting future options that have been discussed at length
> >> in the past ;)
> >
> > I was surprised to read this as I started using this convention when
> > one of the LiveCode team commented on somebody’s code that used the
> > same convention and said “some people in the office have started
> > using it”. Of course, I can no longer find the comment.  If you think
> > it is an unwise convention to use to avoid name clashes, I will adopt
> > another one. Any suggestions as to a good approach/
> 
> A lot of xTalkers express Boolean functions with something list "Is*", e.g.  
> "if IsList() then…".

Thanks for that suggestion. I might switch to IsList rather than List? etc. It 
would seem better to use an xTalk convention than a “foreign” one.

Kind regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Fwd: [ANN] LiveCode List Processor

2015-10-12 Thread Peter W A Wood
Bob

> On 12 Oct 2015, at 23:29, Bob Sneidar  > wrote:
> 
> What I do is load all (or blocks) of the data all at once, put it into a data 
> grid, then navigate through the records in the data grid. I trap 
> selectionChanged in the datagrid to populate the detail fields on the form. I 
> have an edit bar for creating new, editing existing and deleting existing 
> records. I also have a search object for finding records in a table and 
> displaying them in a datagrid. By setting some constants in the search 
> object's input field it can be used with any table and data grid. Navigation 
> is now accomplished by the user simply arrowing down or up in the data grid, 
> or scrolling down, sorting columns etc., or usign the search bar. 
> 
> Trouble is, I develop almost exclusively for sqlYoga but it would not be 
> difficult to refactor it for use with any database. 
> 
> Bob S

Thanks for this tip. Displaying one record in my stack fills a card. I don’t 
think that I could adapt a data grid in this case.

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN] LiveCode List Processor

2015-10-12 Thread Peter W A Wood
Mark

> On 13 Oct 2015, at 01:32, Mark Waddingham  wrote:
> 
> On 2015-10-12 18:41, Richard Gaskin wrote:
>> That looks like Builder rather than Script, no?
> 
> No - this is definitely a LiveCode Script library... It implements a 
> data-type on top of an LCS array very much like the LCB 'List' type. (Such 
> 'proper lists' - aka dense integer numerically-keyed arrays with index 
> starting at 1 - are something we want to add to LCS at some point).

I believe that it would be a very worthwhile addition. An implementation in the 
engine would be far, far superior and orders of magnitude faster than anything 
I can come up with in LiveCode Script.

> Interestingly (although I've not read it in depth) it looks like the type is 
> designed with the idea that you can easily change what is considered to be 
> the 'first' index - i.e. move backward and forward through it.

That is correct

> This reminds me of a circular linked list in functionality.

The list is not circular. I am used to such functionality from Rebol (and now 
Red) whose list processing is ,I believe, highly influenced by Lisp.

Kind regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: [ANN] LiveCode List Processor

2015-10-12 Thread Peter W A Wood
Kay

> On 13 Oct 2015, at 11:36, Kay C Lan  wrote:
> 
> On Tue, Oct 13, 2015 at 7:49 AM, Richard Gaskin 
> wrote:
> 
>> 
>> Peter's original problem statement was:
>> 
>>   LiveCode chunking is great for handling lists but, as far
>>   as I can tell, is missing forward and backward navigation
>>   through lists.
> 
> 
> Actually the problem as I read it was:
> 
> I decided to convert a small card-based database stack to a “proper”
>> database using SQLite. I immediately missed the next/previous card
>> navigation features which were ideal for browsing the small database.
> 
> 
> So, although all the posts about LC lists might be valid and worth pursuing
> I have to wonder, if you've gone to the trouble of converting a multi-card
> stack to a db why wouldn't you just use the inbuilt db forte of being able
> to maintain a cursor and move next record and previous record for you.
> 
> See in the dictionary:
> 
> revMoveToPreviousRecord
> revMoveToNextRecord

Thanks that it what I was missing.

> Fast and efficient. The db (be it SQLite or whatever other flavour) opens
> up so many other super quick and efficient ways of manipulating your 'list'
> of data that I'm sure you'll quickly appreciate that the single card + db
> approach offers much more, more easily and quickly compared to the old 1
> record per card approach.

I look forward to finding out.

> Using LCs inbuilt db handling and navigating features is a lot quicker and
> easier than writing your own List handling script.

I will try the navigation features for this stack but will continue to work on 
my “List Processor”.

Kind regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN] LiveCode List Processor

2015-10-12 Thread Peter W A Wood
Mark

> On 13 Oct 2015, at 04:01, Mark Wieder <mwie...@ahsoftware.net> wrote:
> 
> Peter W A Wood <peterwawood@...> writes:
> 
>> Perhaps you would be kind enough to let me know of existing ways to
>> achieve what this small library does before I spent more time developing it?
> 
> Nicely done. I submitted a PR to keep things moving along.
> Aside from folks having to reinvent list processing all the time,
> I don't know of any built-in support for lists.

Many thanks for the help and encouragement.

> The hard part, of course, is inserting into and deleting from the middle
> of doubly-linked lists.

It will be very hard. Anyway I’ll see how far I can get.

Kind regards

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [ANN] LiveCode List Processor

2015-10-12 Thread Peter W A Wood
Mark

> On 13 Oct 2015, at 01:58, Mark Waddingham  wrote:
> 
> On 2015-10-12 19:46, Richard Gaskin wrote:
>> I've never seen question marks in handler names in any xTalk I've ever
>> used, so I figured perhaps it might be something specific to Builder.
> 
> It's a standard convention in some languages (Scheme springs to mind) to 
> indicate a 'predicate' - a function which returns true or false.
> 
> I've seem some LiveCode Script libraries in the past use it - although not 
> very many.

Again, I am influenced by Rebol. Most of its functions which return true or 
false end with a ?. Some which return data such as length? also end in a ?. 
These latter are the cause of regular discussion in the community as to being 
renamed with -of at the end. Personally, I prefer length? over length-of (or 
lengthOf in LiveCode’s case). 
> 
>> If allowable, is it desirable?  I suppose it's a matter of taste if it
>> doesn't break anything, but given how uncommon it is I'd wager an API
>> for others to use could benefit from conventions developers might
>> anticipate.
> 
> Well the identifier token in LiveCode Script has always been very forgiving. 
> However, in that does lie a problem - it restricts what operators could be 
> added in the future (which is fine as long as the goal of the language is to 
> avoid as many 'symbols' as possible).
> 
> To be fair '?' poses less of a problem in this regard than '.' - in terms of 
> limiting future options that have been discussed at length in the past ;)

I was surprised to read this as I started using this convention when one of the 
LiveCode team commented on somebody’s code that used the same convention and 
said “some people in the office have started using it”. Of course, I can no 
longer find the comment.  If you think it is an unwise convention to use to 
avoid name clashes, I will adopt another one. Any suggestions as to a good 
approach/

> Certainly, we (at LiveCode) only use handler names using alphanumeric 
> characters and '_’.

See above.

Kind regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

[ANN] LiveCode List Processor

2015-10-11 Thread Peter W A Wood
I decided to convert a small card-based database stack to a “proper” database 
using SQLite. I immediately missed the next/previous card navigation features 
which were ideal for browsing the small database.

LiveCode chunking is great for handling lists but, as far as I can tell, is 
missing forward and backward navigation through lists. I decided to write a few 
simple functions to come up with such a mechanism. 

I suspect that there may be an existing way to navigate forwards and backwards 
through a list but I just can’t find it. I’ve put together a very simple, 
completely unoptimised start of a LiveCode list processing library. It contains 
only a handful of functions. You can find it at 
https://github.com/PeterWAWood/LiveCode-ListProcessor 
.

Perhaps you would be kind enough to let me know of existing ways to achieve 
what this small library does before I spent more time developing it?

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

The 1001 Things To Do With LiveCode All Time Top Ten

2015-10-11 Thread Peter W A Wood
Even though I haven’t been able to spend much time on 1001 Things To Do With 
LiveCode recently, the blog is still getting an average of 80 visitors per day. 
I thought you might like to see the all-time top 10 pages visited.

3579Create a URL shortening service by John Craig
1004Code an App store accepted game in a week by Dave Probert
864 Administer SQLite databases by Peter Haworth
587 Exercise your right brain by Andrew Walters
542 Program your watch by Roger Eller
336 Manage a database of images by Roger Eller
312 Create you own virtual instrument by René Micout
279 Build mobile games by Andre Garcia
277 Team organisation and time tracking by Roberto Trevisan
242 Build an assembly language interpreter by Andre Garcia

The more recent entries in the blog have a high percentage of commercially 
available apps written in LiveCode and few very own-use or hobby apps. The 
original purpose of the blog was to show people who had never programmed before 
what could be achieved with LiveCode and to stimulate their imagination as to 
what they could do with LiveCode.

If you have used LiveCode to write an app for your own use or for your hobby 
perhaps you would be kind enough to send me a screenshot and a short 
description. I will try to find the time to add it to 1001 Things You Can Do 
With LiveCode.

Regards

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Script Local Functions?

2015-09-27 Thread Peter W A Wood
Is there any way to define a function within a script that can only be called 
within that script?

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Script Local Functions?

2015-09-27 Thread Peter W A Wood
Many thanks Charle and Klaus.

Regards

Peter

> On 27 Sep 2015, at 19:55, Charles Warwick <char...@techstrategies.com.au> 
> wrote:
> 
> 
> Put the word private at the start of the function definition.  i.e.
> 
> private function myFunc
>   ...
> end myFunc
> 
> On 27 Sep 2015 at 21:51:13 AEST, Peter W A Wood <peterwaw...@gmail.com> wrote:
> 
>> Is there any way to define a function within a script that can only be 
>> called within that script?
>> 
>> Peter
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Is it safe to return an array from a function?

2015-09-21 Thread Peter W A Wood
Thanks very much for the explanation Mark.

Regards

Peter

> On 21 Sep 2015, at 16:52, Mark Waddingham <m...@livecode.com> wrote:
> 
> Like numbers and strings, arrays are values so they are always (notionally) 
> copied whenever they move between locations.
> 
> In 7+ this copying is deferred until needed (copy-on-write), prior to 7 they 
> are copied immediately.
> 
> So, yes, you can pass arrays around without worry.
> 
> Mark.
> 
> Sent from my iPhone
> 
>> On 21 Sep 2015, at 03:28, Peter W A Wood <peterwaw...@gmail.com> wrote:
>> 
>> I understand that arrays are passed by reference in LiveCode not by value. I 
>> assume that is also that case if you return an array from a function (i.e. 
>> the reference to the array is returned not its content). When I tried to 
>> return an array from a function, I found that not only you can do so but 
>> multiple calls of the function provide different arrays. As the array being 
>> returned from the function is local to the function, I’m guessing that 
>> LiveCode is creating a new local array for each function call and returning 
>> a reference to the local variable.
>> 
>> Here is the code that I ran under LiveCode Server:
>> 
>> function returnArray
>> local a
>> put 1 into a[1]
>> return a
>> end returnArray
>> 
>> put returnArray() into b
>> put b[1] & return—> prints 1
>> 
>> put returnArray() into c
>> put c[1] & return—> prints 1   
>> 
>> put 3 into c[1]
>> 
>> put b[1] & return—> prints 1
>> put c[1] & return—> prints 2
>> 
>> Is it safe to use such a technique or will the reference to the array become 
>> invalid at some stage?
>> 
>> Peter
>> 
>> 
>> 
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Is it safe to return an array from a function?

2015-09-21 Thread Peter W A Wood
Dave

> On 21 Sep 2015, at 16:15, Dave Kilroy  wrote:
> 
> Hi Peter
> 
> Your scary posting made me test on LC8.0(db4), LC7.0.1(rc2) and LC 6.7.6 -
> and I'm relieved to say that the arrays performed impeccably (returning '3'
> in the final line)
> 
> Can you give us some more info on your setup and anything else that could be
> conspiring to give you '2' instead of 3?

The main difference between my set up and yours is the keyboard operator 
driver. I typed 2 when I should have typed 3. Sorry if I got you worried.

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Is it safe to return an array from a function?

2015-09-20 Thread Peter W A Wood
I understand that arrays are passed by reference in LiveCode not by value. I 
assume that is also that case if you return an array from a function (i.e. the 
reference to the array is returned not its content). When I tried to return an 
array from a function, I found that not only you can do so but multiple calls 
of the function provide different arrays. As the array being returned from the 
function is local to the function, I’m guessing that LiveCode is creating a new 
local array for each function call and returning a reference to the local 
variable.

Here is the code that I ran under LiveCode Server:

function returnArray
  local a
  put 1 into a[1]
  return a
end returnArray

put returnArray() into b
put b[1] & return   —> prints 1

put returnArray() into c
put c[1] & return   —> prints 1   

put 3 into c[1]

put b[1] & return   —> prints 1
put c[1] & return   —> prints 2

Is it safe to use such a technique or will the reference to the array become 
invalid at some stage?

Peter




___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

LiveCode 8 Global Jam

2015-09-19 Thread Peter W A Wood
After reading the announcements, I am looking forward to the LiveCode 8 Global 
Jam and helping to prepare LiveCode 8 for release through reporting bugs.

As I’ve already reported a handful of bugs relating to LiveCode 8, I thought 
I’d take a look and see how many LiveCode 8 bugs there are in total. As I 
understand, LiveCode 8.0 is based on LiveCode 7 so I performed a search of the 
LiveCode Quality Centre for all bug reports against version 7.0.0 DP 1 and 
above which are not yet resolved.

I was surprised when the search returned 674 bug reports that met the criteria. 
Perhaps the search criteria I used could be improved. I can see that some of 
the 674 are enhancement requests but I can’t work out how to exclude them from 
the search. From a quick glance, I don’t think that there can be much more than 
50 enhancement requests so there still seems to be at least over 500 unresolved 
bugs.

Hopefully, many will get fixed during the Global Jam (and shortly afterwards) 
as the engineering team focusses on bug fixing rather than adding new 
functionality.

I’m still looking forward to the Global Jam but I’m a little worried that the 
LiveCode 8 release isn’t as close as the Global Jam announcements suggested.

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Silly conference survey

2015-09-08 Thread Peter W A Wood

> On 9 Sep 2015, at 04:01, Richmond  wrote:
> 
> To make my point I suggested the idea of a "where people stay" survey.
> 
> Richmond.

As the conference is unlikely to be conducted in any language other then 
English, the statistics of visitors to 1001 Things To Do With LiveCode could 
provide one insight into location of LiveCode users:

United States   36833
United Kingdom   8491
Germany  7278
France   4834
Canada   4667
Australia2965
Italy2032
Russia   1291
Malaysia  557
Ukraine   535

Regards

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Rectangle detection

2015-09-04 Thread Peter W A Wood

> On 5 Sep 2015, at 07:42, Scott Rossi  wrote:
> 
> Does the rectangle always appear in the same location in the image and is
> it always the same dimensions?

If the rectangle doesn’t always appear in the same location or is not always 
the same size, is the image always the same width?

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: LCB API's

2015-09-02 Thread Peter W A Wood

> On 2 Sep 2015, at 00:15, Klaus major-k <kl...@major-k.de> wrote:
> 
> Hi Peter,
> 
>> Am 01.09.2015 um 15:23 schrieb Peter W A Wood <peterwaw...@gmail.com>:
>> 
>> Peter
>> 
>>> On 31 Aug 2015, at 23:40, Peter TB Brett <peter.br...@livecode.com> wrote:
>>> If you go into the dictionary in the IDE, there's a drop down menu at the 
>>> top left.  
>> Not in LiveCode 8 DP 4 it seems.
> 
> resize the dictionary window a couple of times generously, that worked for me,
> suddenly the mentioned drop-down and much more appeared in the stack :-D
> 
>> Regards
>> 
>> Peter
> 

Thanks Klaus. Co-incidentally, Bernd also pointed this out to me. It seems the 
LiveCode community in Germany may be small but you’re all very smart (and 
helpful).

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: LCB API's

2015-09-01 Thread Peter W A Wood
Peter

> On 31 Aug 2015, at 23:40, Peter TB Brett  wrote:
> 
> If you go into the dictionary in the IDE, there's a drop down menu at the top 
> left.  

Not in LiveCode 8 DP 4 it seems.

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Documentation [was: Re: v8 DP3]

2015-08-28 Thread Peter W A Wood

 On 28 Aug 2015, at 15:15, Richmond richmondmathew...@gmail.com wrote:
 
 Well: as an almost complete newcomer to Github, I would be grateful if you 
 could outline a way to edit
 the documents at 
 https://github.com/runrev/livecode-ide/tree/develop/Documentation/guides 
 https://github.com/runrev/livecode-ide/tree/develop/Documentation/guides 
 and submit them after
 the editing . . . does this involve setting up my own github branch

Yes. You will need a Github account and then fork the Github repository. You 
can then edit the documents on-line. Once you have finished editing the 
documents, you will need to create a Pull Request. The LiveCode team will then 
decide whether to accept or decline your changes.

One thing that is needed for your changes to be accepted is to for you to enter 
into a contributor’s agreement http://livecode.com/account/developer/contribute 
http://livecode.com/account/developer/contribute

You can make better use of Git by downloading the repository onto your own 
machine. I was able to do that quite easily by following this 
https://help.github.com/categories/bootcamp/ 
https://help.github.com/categories/bootcamp/

I have no doubt that you will breeze though the process.

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: JSON, URL-encode, and UTF-8

2015-08-21 Thread Peter W A Wood

 On 21 Aug 2015, at 10:59, Peter W A Wood peterwaw...@gmail.com wrote:
 
 Jacque
 
 On 21 Aug 2015, at 10:13, J. Landman Gay jac...@hyperactivesw.com 
 mailto:jac...@hyperactivesw.com wrote:
 
 Here's a test. This posts just fine in LC 6.x but fails in 7.0.6 and 7.1rc1.
 
 Make a field with this in it:
 
   [{Meals:Yes,Purpose:Business}]
 
 Now put this into a button or card script:
 
 constant kServerURL = https://www.domain.com/results.php 
 https://www.domain.com/results.php  --### use a valid URL here
 
 
 command sendToServer
  if the version  7 then
put fld 1 into tData
put json= before tData
  else
put textEncode(fld 1,UTF8) into tData
put textEncode(json=,UTF8) before tData
  end if
  post tData to kServerURL
  put it into tResponse
  put the result into tErr
  breakpoint -- so you can see it
 end sendToServer
 
 If someone can test this against a simple echo PHP maybe it will tell us 
 something. The real server returns empty in LC 7 and OK in LC 6.
 
 This works fine in LiveCode 7.0.3. I’ll download 7.1RC1 and see if it works 
 there too.
 
 Peter
 

It also works on LiveCode 7.1 RC1 … which took me hours to download :-(

Regards

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: JSON, URL-encode, and UTF-8

2015-08-21 Thread Peter W A Wood
Hi Charles

 On 21 Aug 2015, at 16:07, Charles Warwick char...@techstrategies.com.au 
 wrote:
 
 HI Peter,
 
 I did some testing with Jacque and found that her LC7 was sending the wrong 
 content-type when posting to the PHP script.
 
 In case anyone is interested:
 
 It was using a content type of 'application/json’ which would have made sense 
 if the PHP script was written to accept the json data directly.
 
 However, it was expecting the POST data to be encoded in name/value format: 
 variableA=valueAvariableB=valueB.
 
 In this case, it required the json data stored in a variable called json:  
 i.e.  json=json data
 
 Changing the headers as follows before the POST resolved the issue:
 
  set the httpHeaders to “content-type: application/x-www-form-urlencoded
 
 As I mentioned to Jacque, the json data itself needs to be urlEncoded.
 
 Cheers,
 
 Charles

Thanks for closing the loop. 

Cheers

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: JSON, URL-encode, and UTF-8

2015-08-20 Thread Peter W A Wood
Jacque

 On 21 Aug 2015, at 11:32, J. Landman Gay jac...@hyperactivesw.com wrote:
 
 I'd thought of that too. I'll ask the PHP guy to set up an http URL.

I don’t think it is a problem with HTTPS. With Google and Stack overflow’s 
help, I found this website - http://httpbin.org - you can send a POST request 
to https://httpbin.org/post and it will return the POST data to you (in JSON). 
I ran your test against both the http:// and https:// URLs and both worked.

 The other difference is the UTF8 encoding, but it's my understanding that 
 servers always expect to receive that.

I don’t think that all servers expect to receive UTF-8. The character encoding 
can be specified in configuration files.

 Thanks very much to you and Charles for your tests. I agree with Charles that 
 it may indicate there is something wrong with the PHP script. If I give him 
 the simple echo script that you posted here, is that a good test?

It is possible but this may be more useful:

PHP:
?php 
  var_dump($_POST);
?

It will return the POST data received by PHP. For example:

LiveCode Message Box:

put textEncode({   quote  é  quote  : 1}, UTF-8) into tJSON
put json= before tJSON
post tJSON to URL http://localhost/jacque.php;
put textDecode(it, UTF-8)

This is what it returns:
array(1) {
  [json]=
  string(10) { é: 1}
}

Hope this helps.

Peter

PS I’m no PHP programmer.

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: JSON, URL-encode, and UTF-8

2015-08-20 Thread Peter W A Wood
Jacque

 
 This works fine in LiveCode 7.0.3. I’ll download 7.1RC1 and see if it works 
 there too.

Apart from the difference in LiveCode versions, there is one other difference 
that may be significant. I am using HTTP on my machine not HTTPS. There have 
been some bugs in LiveCode 7 HTTPS support. Is it possible for you to run your 
test using HTTP to access your client’s server?

Regards

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: JSON, URL-encode, and UTF-8

2015-08-20 Thread Peter W A Wood
Jacque

 On 21 Aug 2015, at 10:13, J. Landman Gay jac...@hyperactivesw.com wrote:
 
 Here's a test. This posts just fine in LC 6.x but fails in 7.0.6 and 7.1rc1.
 
 Make a field with this in it:
 
   [{Meals:Yes,Purpose:Business}]
 
 Now put this into a button or card script:
 
 constant kServerURL = https://www.domain.com/results.php 
 https://www.domain.com/results.php  --### use a valid URL here
 
 
 command sendToServer
  if the version  7 then
put fld 1 into tData
put json= before tData
  else
put textEncode(fld 1,UTF8) into tData
put textEncode(json=,UTF8) before tData
  end if
  post tData to kServerURL
  put it into tResponse
  put the result into tErr
  breakpoint -- so you can see it
 end sendToServer
 
 If someone can test this against a simple echo PHP maybe it will tell us 
 something. The real server returns empty in LC 7 and OK in LC 6.

This works fine in LiveCode 7.0.3. I’ll download 7.1RC1 and see if it works 
there too.

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: JSON, URL-encode, and UTF-8

2015-08-20 Thread Peter W A Wood
Jacque

 On 21 Aug 2015, at 05:53, J. Landman Gay jac...@hyperactivesw.com wrote:
 
 Here's what I do:
 
  set the httpHeaders to content-type: application/json
  put convertToJSON() into tData -- produces valid JSON
  put json= before tData
  post tData to kServerURL

You’re content is no longer valid JSON once you have inserted the “json=“ (at 
the PHP developer’s request). There may be a conflict between the header and 
the actual content. What happens if you remove the line setting the httpHeaders?

Regards

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: JSON, URL-encode, and UTF-8

2015-08-20 Thread Peter W A Wood
Jacque

 On 21 Aug 2015, at 07:35, J. Landman Gay jac...@hyperactivesw.com wrote:
 
 Right. Works without header in 6, fails in 7. Thanks for looking at my file. 
 I wonder what would happen if I use the LC 6 libURL script in LC 7. Will my 
 unicode go all wonky? The file I sent you is in English but most of the time 
 it won't be.

I ran a very simple test using the message box and a very simple PHP script. I 
was able to post json={JSON} to PHP and get it back.

In the message box (using LC 7..0.3)

post textEncode(json={  quote  é  quote  : 1}, UTF-8) to  URL 
http://Localhost/jacque.php;
put textDecode(it, UTF-8”)

The PHP script:

?php 
  echo($_POST[json]);
?

The result in the message box:

{é: 1}

This would indicate your issue is not caused by a bug.

I’m not sure if you are URLEncoding the data … that certainly seems to cause a 
problem

Revised LiveCode
put textEncode({   quote  é  quote  : 1}, UTF-8) into tJSON
put json= before tJSON
post URLEncode(tJSON) to URL http://Localhost/jacque.php;
put textDecode(it, UTF-8”)

Result 
PHP sends back an empty response.

Hope this is of some help.

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card (Updated)

2015-08-18 Thread Peter W A Wood

LIVECODE KICKSTARTER REPORT CARD -Version 4

The first thing to note is that LiveCode Ltd has open-sourced LiveCode under 
the GPL licence. It is freely accessible on Github.

The second thing to note is that the majority of the Kickstarter rewards have 
been delivered. Only delivery of printed copies of a new updated dictionary 
after final Kickstarter project delivery remains to be completed.

There seems to have been three other major deliverables promised in the main 
campaign:

Deliverable Status
Re-engineer the whole platform  Completed
A new technology: “Open Language”   Early alpha of the 
pre-requisite LiveCode Builder released (LiveCode 8.0)
Open Language 
will be in a release after LiveCode 8.0
A new visual editor Early alpha released 
(LiveCode 8.0)

There were a number of deliverables promised through stretch goals which were 
met:

Deliverable Status
Resolution Independence Completed
Pluggable ThemesPluggable Themes will 
be in a release after LiveCode 8.0
Cocoa   Completed
Physics Engine  Physics Engine will be 
in a release after LiveCode 8.0
Windows/Phone 8 Theme   Windows/Phone 8 Theme will be 
in a release after LiveCode 8.0
Vector Shape Object Vector Shape Object 
will be in a release after LiveCode 8.0
Reworked Multimedia Support 
New Player  Completed on OS X. 
Windows in release LiveCode 8.0. Linux ???
Multi Channel Sound OS X : Linux : Windows 
???
Sound Recording ???
New Browser Control OS X, Windows 
completed. Linux with LiveCode 8.0

I’d appreciate if somebody could let me know the status of the items about 
which I’m unclear and any mistakes I have made.

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card (Updated)

2015-08-18 Thread Peter W A Wood
Matthias

 On 18 Aug 2015, at 14:32, Matthias Rebbe | M-R-D 
 matthias_livecode_150...@m-r-d.de wrote:
 
 
 
 
 Am 18.08.2015 um 04:45 schrieb Peter W A Wood peterwaw...@gmail.com:
 
 There have been quite a few comments and clearly a number of different views 
 amongst members of the community. I would like to add my perspective.
 
 The LiveCode Kickstarter campaign was very unusual in that the LiveCode 
 could fulfil all of the rewards without actually having to complete the 
 project. The rewards consisted of gifts and existing LiveCode products.
 
 In one sense, LiveCode completed the Kickstarter campaign when all the 
 rewards had been delivered. I’m sure that Kickstarter would take this view.
 
 But then the Kickstarter campaign is not yet completed. ;) The printed 
 dictionary reward was not yet sent.

Thanks. I missed the printed dictionary reward. New  Revised PRINTED LIVECODE 
SYNTAX DICTIONARIES with hundreds of updated language terms after final 
Kickstarter project delivery”

So I was wrong and the rewards were connected to the project after all.

I wonder what “the final Kickstarter project delivery” means in practical 
terms. All stretch goals completed?

I will update my report card.

Regards

Peter

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card (Updated)

2015-08-18 Thread Peter W A Wood
Richmond

 Does after LiveCode 8 mean 8.1 or does it mean 9 or maybe 10? Because 
 that could make quite a difference.

It means that I don’t think it is going to be in any of the LiveCode 8.xx 
releases based on my memory of snippets of information on this list and in the 
forums. (Which could well be wrong).

I didn’t know whether to use LiveCode 9 or LiveCode 10 for the major release 
after LiveCode 8. I remember it being mentioned by one of the LiveCode team 
that “Open Language” was going to be such an improvement that the release of 
LiveCode that included would be called LiveCode 10. (To be fair to the LiveCode 
team, this was said before Windows 10 was announced as the name for Windows 8 + 
1).

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Open Source Kickstarter Report Card (Updated)

2015-08-17 Thread Peter W A Wood
I have updated my KickStarter report card thanks to the information about the 
new player for Windows being planned for LiveCode 8.0 that Tom Bodine kindly 
provided.

As I understand, the phrase “new visual editor” refers to the new IDE.

LIVECODE KICKSTARTER REPORT CARD

The first thing to note is that all the Kickstarter rewards have been delivered.

There seems to have been three major deliverables promised in the main campaign:

Deliverable Status
Re-engineer the whole platform  Completed
A new technology: “Open Language”   Early alpha of the 
pre-requisite LiveCode Builder released (LiveCode 8.0)
Open Language 
will be in a release after LiveCode 8.0
A new visual editor Early alpha released 
(LiveCode 8.0)

There were a number of deliverables promised through stretch goals which were 
met:

Deliverable Status
Resolution Independence Completed
Pluggable ThemesPluggable Themes will 
be in a release after LiveCode 8.0
Cocoa   Completed
Physics Engine  Physics Engine will be 
in a release after LiveCode 8.0
Windows/Phone 8 Theme   Windows/Phone 8 Theme will be 
in a release after LiveCode 8.0
Vector Shape Object Vector Shape Object 
will be in a release after LiveCode 8.0
Reworked Multimedia Support 
New Player  Completed on OS X. 
Windows in release LiveCode 8.0. Linux ???
Multi Channel Sound OS X : Linux : Windows 
???
Sound Recording ???
New Browser Control OS X, Windows 
completed. Linux with LiveCode 8.0

I’d appreciate if somebody could let me know the status of the items about 
which I’m unclear and any mistakes I have made.

Regards

Peter





___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card

2015-08-17 Thread Peter W A Wood
Richard

 On 18 Aug 2015, at 08:13, Richard Gaskin ambassa...@fourthworld.com wrote:
 
 What usability standards do you feel are not well reflected in the current 
 IDE, and if Kevin made you IDE Czar tomorrow what are the first three things 
 you'd do to fix that?

1. Intelligent Code Completion (like intelliSense)
2. Integrated Version Control
3. Support of Multiple targets (like Xcode)

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Open Source Kickstarter Report Card (Updated)

2015-08-17 Thread Peter W A Wood
Monte

 On 18 Aug 2015, at 10:52, Monte Goulding mo...@sweattechnologies.com wrote:
 
 
 On 18 Aug 2015, at 12:45 pm, Peter W A Wood peterwaw...@gmail.com wrote:
 
 PS Does anybody still think it is worth LiveCode supporting Windows 8 Phone?
 
 Nope… I presume the goal will be bumped to Windows 10???

Perhaps there is no need for a replacement. After all, it looks to me that you 
cannot sell GPL licensed software through the Windows App Store so LiveCode 
will be motivated to include Windows 10 support as it could help them sell more 
indy licences. (Assuming that Windows 10 and its appstore takes off).

Cheers

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card (Updated)

2015-08-17 Thread Peter W A Wood
There have been quite a few comments and clearly a number of different views 
amongst members of the community. I would like to add my perspective.

The LiveCode Kickstarter campaign was very unusual in that the LiveCode could 
fulfil all of the rewards without actually having to complete the project. The 
rewards consisted of gifts and existing LiveCode products.

In one sense, LiveCode completed the Kickstarter campaign when all the rewards 
had been delivered. I’m sure that Kickstarter would take this view.

LiveCode kept to the biggest promise it made, LiveCode has been open-sourced 
under the GPL and is freely accessible on Github.

That leaves the other promises made during the Kickstarter campaign. Some made 
initially, some made as stretch goals. I have no doubt that these promises were 
very genuine. Clearly, LiveCode hasn’t been able to deliver them in the time 
they expected. This could be to any number of causes; under estimating and 
resources not being available being the most likely.

To their great credit, the LiveCode team still appears to be committed to 
meeting its Kickstarter promises even though the funds raised to do so must 
have run out a long time ago.

My concern is that it is human nature to push promises made a long time ago to 
the back of our minds. If my report card serves any purpose, it is simply to 
keep the promises in view. 

I would like the promises to be kept. However, if LiveCode were to give a 
reasonable explanation (with an apology) why a promise could no longer be met, 
I would accept it given that I got my rewards, LiveCode has been open-sourced, 
and many of the “feature” promises have been met. 

Peter

PS Does anybody still think it is worth LiveCode supporting Windows 8 Phone?




___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card (Updated)

2015-08-17 Thread Peter W A Wood
I forgot to add the most important promise … LiveCode being open-sourced … as 
kindly pointed out by Jacque Landman Gay.

LIVECODE KICKSTARTER REPORT CARD

The first thing to note is that all the Kickstarter rewards have been delivered.

The second thing to note is that LiveCode has open-sourced LiveCode. It is 
available on Github.

There seems to have been three other major deliverables promised in the main 
campaign:

Deliverable Status
Re-engineer the whole platform  Completed
A new technology: “Open Language”   Early alpha of the 
pre-requisite LiveCode Builder released (LiveCode 8.0)
Open Language 
will be in a release after LiveCode 8.0
A new visual editor Early alpha released 
(LiveCode 8.0)

There were a number of deliverables promised through stretch goals which were 
met:

Deliverable Status
Resolution Independence Completed
Pluggable ThemesPluggable Themes will 
be in a release after LiveCode 8.0
Cocoa   Completed
Physics Engine  Physics Engine will be 
in a release after LiveCode 8.0
Windows/Phone 8 Theme   Windows/Phone 8 Theme will be 
in a release after LiveCode 8.0
Vector Shape Object Vector Shape Object 
will be in a release after LiveCode 8.0
Reworked Multimedia Support 
New Player  Completed on OS X. 
Windows in release LiveCode 8.0. Linux ???
Multi Channel Sound OS X : Linux : Windows 
???
Sound Recording ???
New Browser Control OS X, Windows 
completed. Linux with LiveCode 8.0

I’d appreciate if somebody could let me know the status of the items about 
which I’m unclear and any mistakes I have made.

Regards

Peter






___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card (Updated)

2015-08-17 Thread Peter W A Wood

 On 18 Aug 2015, at 11:29, Richard Gaskin ambassa...@fourthworld.com wrote:
 
 Peter W A Wood wrote:
 
  After all, it looks to me that you cannot sell GPL licensed software
  through the Windows App Store
 
 I couldn't find anything definitive on that.  I did find some older articles 
 about Win8 licensing suggesting FOSS was prohibited, but I also found this 
 one from 2011 that says the opposite:
 
   Windows 8 Store will allow open source apps,
   unlike iOS and Mac App Stores
   ...
The section in question states that apps released under a license
from the Open Source Initiative (GPL, Apache, etc.) can be
distributed in the Windows Store. Further, it says that the OSI
license will trump the Microsoft Standard Application License
Terms, namely the the restriction on sharing applications.
 http://www.extremetech.com/computing/108551-windows-8-store-will-allow-open-source-apps-unlike-ios-and-mac
 
 And that was back when Ballmer was still there.  Since Nadella took the helm 
 Microsoft has fallen in love with Linux, started moving their dev tools to 
 open source, and is partnering with Ubuntu as a key component of their Azure 
 cloud platform.  (No, really, it's like hell froze over in a flock of flying 
 pigs - the photo here is priceless, something no one ever expected for 
 decades: 
 http://news.softpedia.com/news/CEO-Satya-Nadella-Microsoft-Loves-Linux-462754.shtml
  )
 
 Anyone have a definitive notice on this, preferably one from Microsoft 
 themselves?

I interpreted this clause from the latest Windows Store App Developer 
Agreement, to mean that GPL software cannot be sold via the App Store:

d.  FOSS Software. If your App includes FOSS, (i) you are responsible for 
compliance with all applicable FOSS license terms, including any source code 
availability requirements, and (ii) it must not cause any non-FOSS Microsoft 
software to become subject to the terms of any FOSS license.
I could well be wrong though.

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Open Source Kickstarter Report Card

2015-08-17 Thread Peter W A Wood
Richard

 On 18 Aug 2015, at 11:36, Richard Gaskin ambassa...@fourthworld.com wrote:
 
 Peter W A Wood wrote:
 
  On 18 Aug 2015, at 08:13, Richard Gaskin wrote:
 
  What usability standards do you feel are not well reflected in the
  current IDE, and if Kevin made you IDE Czar tomorrow what are the
  first three things you'd do to fix that?
 
  1. Intelligent Code Completion (like intelliSense)
 
 I keep hearing talk about that, but it's not on the Road Map and given the 
 number of tasks in the queue it may be a long time before it shows up.

Any new visual editor designed around today’s usability standards would 
include this, even older ones like Delphi do. 

  2. Integrated Version Control
 
 Looks like lcVCS is a more generalized solution than what LiveCode Ltd. is 
 including with their Biz package, so we're on our way on that one.

Again today’s usability standards for visual editors would include git 
integration as a minimum, even for visually designed elements. Sure this would 
require LiveCode to add object state serialisation Of the IDE’s I know both 
Delphi and Xcode include object state serialisation. Vector graphics drawing 
tools do. Again it is something you would expect in a modern visual editor.

  3. Support of Multiple targets (like Xcode)
 
 What are multiple targets in an IDE?

Very much as Monte said. Specifically would be the ability to define both test, 
debug and distribution targets. The test target would cause an automated test 
suite to run, the debug target would build and run a version including 
additional debugging code etc.

With LiveCode’s cross-platform credentials, it should be possible to select the 
iOS test target (one for each device), click-on run and your stack should be 
run in an iOS simulator. Similar for Android.

Again, I see these as features to be part of today’s usability standards.

The issue here is that the promise of a “new visual editor designed around 
today’s usability standards” is extremely broad. It means different things to 
different people depending on their context. I think it’s great from a 
marketing perspective, it has something to attract a lot of people, and it's 
horrible from a customer satisfaction perspective as most people will be 
disappointed when it doesn’t meet their expectation.

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Open Source Kickstarter Report Card (Updated)

2015-08-17 Thread Peter W A Wood
Richard 

 On 18 Aug 2015, at 12:51, Richard Gaskin ambassa...@fourthworld.com wrote:
 
 Peter W A Wood wrote:
 
  I interpreted this clause from the latest Windows Store App Developer
  Agreement, to mean that GPL software cannot be sold via the App Store:
 
  d.  FOSS Software. If your App includes FOSS, (i) you are
  responsible for compliance with all applicable FOSS license terms,
  including any source code availability requirements, and (ii) it must
  not cause any non-FOSS Microsoft software to become subject to the
  terms of any FOSS license.
  I could well be wrong though.
 
 Seems very accepting of FOSS.  I can't imagine anyone would try to distribute 
 something that places restrictions on the OS vendor.
 
 I haven't spent much time looking, but I haven't heard any objections from 
 the Free Software Foundation, and they're usually quite vocal about such 
 things.

I believe that the statement “ it must not cause any non-FOSS Microsoft 
software to become subject to the terms of any FOSS license.” would 
specifically exclude the use of GPL licensed software - 
http://www.theregister.co.uk/2011/12/08/open_source_windows_8_windows_store/

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Open Source Kickstarter Report Card

2015-08-14 Thread Peter W A Wood
Following LiveCode’s announcement of its Business Application Framework, there 
has been quite a few comments regarding the fulfilment of promises made during 
the Kickstarter open source campaign. It’s a long time since the campaign and 
it is easy to get an incorrect perception. So I thought that it would be worth 
going back, seeing what was promised and what had been delivered. 

I’ve come up with a report card based on the Kickstarter web pages, LiveCode’s 
road map and from comments made on the mailing lists and forums by LiveCode 
staff. I relied on my memory for the latter so the status that I’ve noted may 
not be quite correct. By posting it to the mailing list, I’m sure that any 
misperceptions I might have will get corrected. I hope so as I much prefer to 
have a clear picture of where things stand.

The first thing to note is that all the Kickstarter rewards have been delivered.

There seems to have been three major deliverables promised in the main campaign:

Deliverable Status
Re-engineer the whole platform  Completed
A new technology: “Open Language”   Early alpha of the 
pre-requisite LiveCode Builder released (LiveCode 8.0)
Open Language 
will be in a release after LiveCode 8.0
A new visual editor Early alpha released 
(LiveCode 8.0)

There were a number of deliverables promised through stretch goals which were 
met:

Deliverable Status
Resolution Independence Completed
Pluggable ThemesPluggable Themes will 
be in a release after LiveCode 8.0
Cocoa   Completed
Physics Engine  Physics Engine will be 
in a release after LiveCode 8.0
Windows/Phone 8 Theme   Windows/Phone 8 Theme will be 
in a release after LiveCode 8.0
Vector Shape Object Vector Shape Object 
will be in a release after LiveCode 8.0
Reworked Multimedia Support 
New Player  Completed on OS X. 
Windows/Linux ???
Multi Channel Sound OS X : Linux : Windows 
???
Sound Recording ???
New Browser Control OS X, Windows 
completed. Linux with LiveCode 8.0

I’d appreciate if somebody could let me know the status of the items about 
which I’m unclear and any mistakes I have made.

Regards

Peter




___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: URL works in IDE, browser but not on Livecode Server

2015-08-05 Thread Peter W A Wood
It may be this bug - http://quality.runrev.com/show_bug.cgi?id=15162 
http://quality.runrev.com/show_bug.cgi?id=15162 - depending on which version 
of LiveCode server you are running.


 On 5 Aug 2015, at 13:43, David Bovill david@viral.academy wrote:
 
 The following url works in the browser, in script and in the message box:
 
   -
   
 https://commons.wikimedia.org/w/api.php?action=querytitles=Image:Andalusian_horse_moscow.jpgprop=imageinfoformat=jsoniiprop=extmetadata|url
 
 It does not however work when called from a script in Livecode server. It
 does work when called by curl on the same server.
 
 This script if run on your Livecode server should demonstrate the
 difference:
 
 ?rev
put 
 https://commons.wikimedia.org/w/api.php?action=querytitles=File%3AAndalusian_horse_moscow.jpgprop=imageinfoformat=jsoniiprop=extmetadata|url
 into someUrl
put shell (curl  quote  someURL  quote) into someResult
delete line 1 to 4 of someResult
put url someURl  CR  someURL  CR  someResult
 ?
 
 
 Anyone have an idea why the server may not been doing the same thing as the
 IDE or curl with this url?
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Livecode and UTF8

2015-07-29 Thread Peter W A Wood
Simon

I did not reply sooner as I’m not such an experienced LiveCoder. Also, I am 
concentrating on learning LiveCode versions from 7 onwards. Handling Unicode is 
much, much easier in those versions. 

In the code you posted here, you appear to have used uniDecode where you needed 
to use uniEncode.

I ran this in the message box in LiveCode 8:

put numToChar(226) into tString -- E2 hex
put numToChar(128) after tString -- 80 hex
put numToChar(156) after tString -- 9C hex
put  unicode uniEncode(tString, UTF8”)

It successfully displayed this:

“

I am not familiar with using Unicode in the older versions but noticed that you 
typed “useUniCode” instead of “useUnicode” in the code example in your message.

I hope this helps to get you started.

Peter


 On 29 Jul 2015, at 02:29, Simon Knight si...@smknight.co.uk wrote:
 
 Hi,
 
 I have an app that works with old fashioned text i.e. characters with a code 
 value of less than 128.  Recently I enabled cut and paste and the app gets 
 confused it text is pasted in with character values  127.  I have done the 
 obvious and an filtering out all characters with an Ascii value of 127 but 
 in the longer term I want to convert a few high bit characters to a low bit 
 versions e.g. smart quotes to dumb quotes.
 
 Some of the text that gets pasted from my email client is in UTF8. I have 
 done some web research and now know a little about UTF8.  I have written a 
 routine that captures any UTF8 code patterns and passes the UTF string to a 
 routine for conversion.
 
 A UTF8 string may be between one and four bytes long and every byte has a 
 value greater than 127.  I wish to extract the UTF character value and use 
 the value to do the conversion.  My question is: does livecode have any 
 method of converting  a UTF8 character string to either a UTF16 string or to 
 the numeric value of the character which I believe is the same if leading 
 zeros are ignored?  For instance a smart open quote appears in my data as a 
 series of three bytes : [E2-hex,80-hex,9C-hex] the numeric value of the 
 character is encoded within the bits of the three bytes and will take some 
 bit shifting to extract : the UTF8 string decodes to 201C-hex or 8220 base 10.
 
 At present I am working with Livecode 6.7 and have read about and tried the 
 uniEncode and uniDecode functions.  The description of these functions does 
 not make any sense to me as they seem to be about adding or removing every 
 other byte which can't work with UTF8.
 
 I have tried various versions of the following button code attempting to get 
 a result of 8220 base 10:
 
 on mouseUp
 put numToChar(226) into tString -- E2 hex
 put numToChar(128) after tString -- 80 hex
 put numToChar(156) after tString -- 9C hex
 
 Set the UseUniCode to true
 
 put source string :   tstring
 
 put uniDecode(tString,UTF8) into tResult
 
 put CharToNum(tResult) into tNumberResult  -- seeking value 8220 in base 
 10
 
 end mouseUp
 
 So do I have to knuckle down and start bit shifting?
 
 thanks for reading
 Simon
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode 
 http://lists.runrev.com/mailman/listinfo/use-livecode

“
LEFT DOUBLE QUOTATION MARK
Unicode: U+201C, UTF-8: E2 80 9C

ƒ
LATIN SMALL LETTER F WITH HOOK
Unicode: U+0192, UTF-8: C6 92

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Thousands Separators

2015-07-27 Thread Peter W A Wood
Thanks Mike.

 On 27 Jul 2015, at 19:14, Michael Doub miked...@gmail.com wrote:
 
 Peter, there is a function in the MasterLibrary that does this for you.  Look 
 in the Text section.
 
 https://www.dropbox.com/s/3wpwn3hfbmpl7sk/MasterLibrary.livecode?dl=0
 
 Regards,
   Mike
 
 
 On 7/27/15 7:12 AM, Peter W A Wood wrote:
 I would like to display numbers with a thousand separator. I searched the 
 dictionary and the user guide but couldn’t find any mention of inserting a 
 thousand separator into a number. Is it a case of do it yourself?
 
 Regards
 
 Peter
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Thousands Separators

2015-07-27 Thread Peter W A Wood
I would like to display numbers with a thousand separator. I searched the 
dictionary and the user guide but couldn’t find any mention of inserting a 
thousand separator into a number. Is it a case of do it yourself?

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Thousands Separators

2015-07-27 Thread Peter W A Wood
Mike

 On 27 Jul 2015, at 19:14, Michael Doub miked...@gmail.com wrote:
 
 Peter, there is a function in the MasterLibrary that does this for you.  Look 
 in the Text section.
 
 https://www.dropbox.com/s/3wpwn3hfbmpl7sk/MasterLibrary.livecode?dl=0
 
 Regards,
   Mike

The MasterLibrary is impressive, I should have looked at it before.

The function didn’t seem to have the exact format that I needed but it was a 
good stimulus to write one that meets my needs. I wanted to format the numbers 
in what I call accounting format - thousands separators with negative numbers 
in brackets (or parentheses depending from where one hails). 

Thanks to LiveCode’s chunking the function is very short, dealing with the 
arguments takes almost as much code as the function. I include it here in case 
it is of use to others. I’m sure it could be improved and would welcome any 
suggestions.

function numToAccounting pNum, pDecimalSeparator, pThousandSeparator 
# Purpose:Converts a number to accounting format
# Inputs:
# pNum  The number to be converted
# pDecimalSeparator The character to be used, default .
# pThousandSeparatorThe character to be used, default ,
# Returns:  The number in accounting format rounded 
toplevel
#   decimal places
  local tCount
  local tDecimalSeparator
  local tNum
  local tStart
  local tThousandSeparator
  
  # set the separators
  if pThousandSeparator is empty then
put , into tThousandSeparator
  else
put pThousandSeparator into tThousandSeparator
  end if
  if pDecimalSeparator is empty then
  put . into tDecimalSeparator
else
  put pDecimalSeparator into tDecimalSeparator
  end if
  
  #format the numbers
  put format(%.2f, pNum) into tNum
  put tDecimalSeparator into char -3 of tNum
  put 0 into tCount
  put the length of tNum - 3 into tStart
  repeat with i = tStart down to 1
add 1 to tCount
if tCount = 4 then 
  if char i of tNum  = - then exit repeat
  put tThousandSeparator after char i of tNum
  put 1 into tCount
end if
  end repeat
  if pNum  0 then
put ( into character 1 of tNum
put ) after tNum
  end if
  
  return tNum 
  
end numToAccounting
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Programatically complete an answer dialog ?

2015-07-21 Thread Peter W A Wood
Bob

 On 21 Jul 2015, at 22:33, Bob Sneidar bobsnei...@iotecdigital.com wrote:
 
 Unless you get into the answer dialog stack and play around or craft your 
 own, I don’t think so. The problem is, the answer dialog is a modal stack 
 itself and no processing happens until you dismiss it. 
 
 Bob S

I found it easy to dismiss a modal stack once I can identify the stack (or even 
better the button) by sending a message to it in a suitable timeframe before 
the modal stack will be opened. I can’t manage that yet with an answer stack as 
I can’t identify the name of the stack that the engine displays.

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Programatically complete an answer dialog ?

2015-07-21 Thread Peter W A Wood
Thanks Mike

 On 22 Jul 2015, at 06:49, Mike Bonner bonnm...@gmail.com wrote:
 
 You can put this into a button to find out the name of the stack. (Which
 turns out to be named Answer Dialog)
 
 on mouseUp
   send set the mystacks of this stack to the openstacks to me  in 1
 second
   answer information HI!
   put the mystacks of this stack
 end mouseUp
 
 On Tue, Jul 21, 2015 at 4:36 PM, Peter W A Wood peterwaw...@gmail.com
 wrote:
 
 Bob
 
 On 21 Jul 2015, at 22:33, Bob Sneidar bobsnei...@iotecdigital.com
 wrote:
 
 Unless you get into the answer dialog stack and play around or craft
 your own, I don’t think so. The problem is, the answer dialog is a modal
 stack itself and no processing happens until you dismiss it.
 
 Bob S
 
 I found it easy to dismiss a modal stack once I can identify the stack (or
 even better the button) by sending a message to it in a suitable timeframe
 before the modal stack will be opened. I can’t manage that yet with an
 answer stack as I can’t identify the name of the stack that the engine
 displays.
 
 Regards
 
 Peter
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your
 subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: [Ben] HTML5 preloading suggestion...

2015-07-15 Thread Peter W A Wood
By checking with Firebug, it seems the calculator “page” initially makes 67 
HTTP GET requests and then another 3 HTTP requests before the calculator is 
displayed.

One of these subsequent requests is 
http://livecode.com/demo/html5/calculator/standalone-community.html.mem 
http://livecode.com/demo/html5/calculator/standalone-community.html.mem which 
weighs in at 4.7 MB.

Regards

Peter


 On 16 Jul 2015, at 09:08, Monte Goulding mo...@sweattechnologies.com wrote:
 
 
 On 16 Jul 2015, at 10:50 am, Colin Holgate colinholg...@gmail.com wrote:
 
 Those will get cached by HTML5 anyway, but for the first time user if you 
 can download 6 items at the same time, it’s dramatically faster than 
 downloading one at a time.
 
 I think it’s just the one file though. There does appear to be a reference to 
 a standalone-community.data file that might also get downloaded by 
 standalone-community.js but it’s not all that readable…
 
 --
 M E R Goulding http://goulding.ws/ 
 Software development services
 Bespoke application development for vertical markets
 
 mergExt http://mergext.com/ - There's an external for that!
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Memory Management in LiveCode

2015-07-14 Thread Peter W A Wood
Many thanks Peter. That's a big plus for LiveCode in the mobile market. I 
wonder why it isn't stressed on the website?

Regards

Peter

Peter TB Brett peter.br...@livecode.com wrote:

On 2015-07-14 01:35, Peter W A Wood wrote:
 The User Guide states the Memory Management is automatic but doesn’t
 explain how the engine actually manages memory. Does anybody know if
 it uses a type of reference counting or a garbage collector?

Hi Peter,

The engine uses automatic reference counting to manage memory.  There's 
no garbage collection.

  Peter

-- 
Dr Peter Brett peter.br...@livecode.com
LiveCode Engine Development Team


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Programatically complete an answer dialog ?

2015-07-14 Thread Peter W A Wood
I have a stack which requests the user to enter some text into an answer 
dialog. I am trying to test that stack from another stack. Is there a way to 
programatically enter text into an answer dialog?

Another way of asking this question is: Is an answer dialog simply a stack? If 
so, does anybody know the name of the stack and the name of the text field? (I 
can guess the name of the button would be the label displayed on them).

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Memory Management in LiveCode

2015-07-13 Thread Peter W A Wood
The User Guide states the Memory Management is automatic but doesn’t explain 
how the engine actually manages memory. Does anybody know if it uses a type of 
reference counting or a garbage collector?

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Best way to check if a Field is a label?

2015-07-08 Thread Peter W A Wood
At the moment I’m checking the lockText property to distinguish a Label Field. 
Is there a better or more reliable way?

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Best way to check if a Field is a label?

2015-07-08 Thread Peter W A Wood
Thanks, Hugh

I’m trying to find the best way to clear all the fields in which data can be 
entered on a card. At the moment I use this code:

repeat with y = 1 to the number of fields of this card
if not the lockText of Field y then
  put empty into Field y
end if
  end repeat

It works for my simple program but using a customProperty would be safer.

Regards

Peter


 On 8 Jul 2015, at 18:09, FlexibleLearning.com ad...@flexiblelearning.com 
 wrote:
 
 Hi Peter
 
 As you will have gathered, there is no label property as such, simply a
 field with pre-defined attributes including lockText. It depends what you
 are trying to do and why you need to identify them, but if you need to
 regularly test the easiest way may be to manually specify a customProperty
 for each label field so that...
 
 If the cLabelStyle of the target = true then [etc]
 
 Best regards
 
 Hugh Senior
 FLCo
 
 
 
 -Original Message-
 At the moment I?m checking the lockText property to distinguish a Label
 Field. Is there a better or more reliable way?
 
 Regards
 
 Peter
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Best way to check if a Field is a label?

2015-07-08 Thread Peter W A Wood
That’s a good tip. Thanks Mike

 On 8 Jul 2015, at 21:11, Mike Bonner bonnm...@gmail.com wrote:
 
 I name my fields with a trailing L or F which lets you do the same thing as
 using a custom prop.
 
   repeat with i = 1 to the number of fields of this card
  if (the last char of the short name of field i is F) then put
 random(1525434) into field i
   end repeat

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Problem with arrayDecode

2015-07-05 Thread Peter W A Wood
I am having problems with encoding and decoding an array when I save the 
encoded data to a file and read it back. Here is a simple LiveCode Server 
script that shows the issue:

#coding:utf-8

set the outputLineEndings to “lf”   
# OS X
set the outputTextEncoding to “utf8”# OS X

put data.db into preferences[database”]
put arrayEncode(preferences) into URL “file:temp.txt
put URL file:temp.txt into encodedPrefs 
if encodedPrefs is not empty then 
put arrayDecode(encodedPrefs) into prefs
put The decoded data contains:  prefs[database]  return
end if

put data2.db into preferences[database”]
put arrayEncode(preferences) into encodedPrefs
put arrayDecode(encodedPrefs) into prefs
put The decoded data contains:  prefs[database]  return

This is what the script outputs:

peter$ test/test.lc
The decoded data contains: 
The decoded data contains: data2.db
peter$ 

Any suggestions to what I’m getting wrong or is it a bug?

Regards

Peter
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Problem with arrayDecode

2015-07-05 Thread Peter W A Wood
Thanks Alex. That fixed it.

Regards

Peter

 On 5 Jul 2015, at 19:09, Alex Tweedly a...@tweedly.net wrote:
 
 You would need to use  a binary file (e.g. binfile:temp.txt)  for the 
 result of arrayencode
 (so I might therefore chose  different extension :-)
 
 Alex.
 
 
 On 05/07/2015 09:46, Peter W A Wood wrote:
 I am having problems with encoding and decoding an array when I save the 
 encoded data to a file and read it back. Here is a simple LiveCode Server 
 script that shows the issue:
 
  #coding:utf-8
 
  set the outputLineEndings to “lf”   
 # OS X
  set the outputTextEncoding to “utf8”# OS X
 
  put data.db into preferences[database”]
  put arrayEncode(preferences) into URL “file:temp.txt
  put URL file:temp.txt into encodedPrefs
  if encodedPrefs is not empty then
  put arrayDecode(encodedPrefs) into prefs
  put The decoded data contains:  prefs[database]  return
  end if
 
  put data2.db into preferences[database”]
  put arrayEncode(preferences) into encodedPrefs
  put arrayDecode(encodedPrefs) into prefs
  put The decoded data contains:  prefs[database]  return
 
 This is what the script outputs:
 
 peter$ test/test.lc
 The decoded data contains:
 The decoded data contains: data2.db
 peter$
 
 Any suggestions to what I’m getting wrong or is it a bug?
 
 Regards
 
 Peter
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Is there a shorter way?

2015-07-02 Thread Peter W A Wood

 On 2 Jul 2015, at 15:12, Mark Schonewille m.schonewi...@economy-x-talk.com 
 wrote:
 
 Hi Peter,
 
 // put the long id into a variable
 put First Group into Field Company of card CompanyData of stack 
 ShareAnalysis into myLongID
 put the text of myLongID into mySomeText
 send textChanged to myLongID
 set the text of myLongID to mySomeText
 
 --
 Best regards,
 
 Mark Schonewille

Many thanks Mark.
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Is there a shorter way?

2015-07-02 Thread Peter W A Wood

 On 2 Jul 2015, at 12:57, Scott Rossi sc...@tactilemedia.com wrote:
 
 Is there a reason you can't use the long id of the field?
 
 Regards,
 
 Scott Rossi
 Creative Director
 Tactile Media, UX/UI Design
 

Thanks for the hint Scott.

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Is there a shorter way?

2015-07-02 Thread Peter W A Wood
Kay

Thanks for the input. I perhaps should have explained more. I am writing a 
stack to test a stack. The code that I posted was setting a field in the UI of 
the stack being tested and then activating its on changeText handler.

Regards

Peter


 On 2 Jul 2015, at 14:52, Kay C Lan lan.kc.macm...@gmail.com wrote:
 
 On Thu, Jul 2, 2015 at 12:52 PM, Peter W A Wood peterwaw...@gmail.com
 wrote:
 
 
 Is there a shorter way of achieving this?
 
 
 The smart-alec answer would be text file or as you seem to be referring to
 a large amount of data, a database ;-)
 
 In the Model View Controller way of doing things the data (model) is all in
 one location so as to avoid the problems you are facing. It wouldn't matter
 which field (view) was in which group (view) of whatever stack (view), the
 call (controller) to get the data would be exactly the same. It's why I
 moved to dbs a long time ago, even simple stacks I use a sqLite db; avoids
 all these hassles plus you get a host of db bonus features thrown if for
 free.
 
 Probably not what you wanted to hear ;-(
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Is there a shorter way?

2015-07-01 Thread Peter W A Wood
I’m accessing objects in another stack with code like this:

put First Group into Field Company of card CompanyData of stack 
ShareAnalysis 
send textChanged to Field Company of card CompanyData of stack 
“ShareAnalysis

Is there a shorter way of achieving this? 

Even better, is there a way I can store a reference to the Field in a variable 
and use that instead of Field of Card of Stack?

Regards

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: Card colo(u)rs

2015-06-28 Thread Peter W A Wood
Richmond 

 On 28 Jun 2015, at 18:05, Richmond richmondmathew...@gmail.com wrote:
 
 On 28/06/15 12:41, Peter W A Wood wrote:
 Richmond
 
 On 28 Jun 2015, at 17:26, Richmond richmondmathew...@gmail.com wrote:
 
 So, there I am, merrily making a stack using LiveCode 7.0.5 with 3 cards 
 (sophisticated stuff),
 and I wish to have each of the cards with a different backgroundColor.
 
 Setting the colour of card 1 via the prefs palette was easy, as was
 
 setting the colour of card 2 via the prefs palette, HOWEVER
 
 setting the colour of card 3 via the prefs palette resulted in card 2 ALSO 
 ending up that colour
 
 (i.e. cards 2 and 3 have the same backgroundColor)
 Is it the same in earlier versions?
 
 Peter
 
 
 Yes: I have just tried it in Revolution Studio 3.5
 
 Richmond

Then, unless somebody pipes up that it was specifically changed in release X.X 
in the next few hours, I would report it as a bug. 

In fact, if you are adverse to reporting bugs, I will do so.

Regards

Peter



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Card colo(u)rs

2015-06-28 Thread Peter W A Wood
Richmond

 On 28 Jun 2015, at 17:26, Richmond richmondmathew...@gmail.com wrote:
 
 So, there I am, merrily making a stack using LiveCode 7.0.5 with 3 cards 
 (sophisticated stuff),
 and I wish to have each of the cards with a different backgroundColor.
 
 Setting the colour of card 1 via the prefs palette was easy, as was
 
 setting the colour of card 2 via the prefs palette, HOWEVER
 
 setting the colour of card 3 via the prefs palette resulted in card 2 ALSO 
 ending up that colour
 
 (i.e. cards 2 and 3 have the same backgroundColor)

Is it the same in earlier versions? 

Peter


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


  1   2   3   4   >