7.0 Issues

Mats Wilstrand mats.wilstrand at tapirsoft.com
Mon Mar 24 08:13:15 EDT 2014


Mark,

Thanks for sharing your thoughts on this. It is much appreciated.
For my plugins I'm leaning towards your use of a plain txt, written 
in a format that could easily be read and edited. I think pref files 
should be "plain English LiveCode" wherever possible. 

I also think there is need to save multi-level array data to pref files. 
Not sure what would be best approach for that though. I've done 
some very basic testing and there seems to be very little difference 
in size between using arrayEncode to save as a bin string and 
parsing the array to save as a plain text that could be read and edited. 
Any thoughts here?

For rIDE the situation is a little different as it started out as a plugin
but is now evolving towards an independent IDE of itself. If there is an 
interest, rIDE could now be used to test new community driven features
like the ones you, Jaque and Richard are discussing for having the IDE
handling the preferences of plugins.

Best,
Mats


> -----Original Message-----
> From: use-livecode [mailto:use-livecode-bounces at lists.runrev.com] On
> Behalf Of Mark Wieder
> Sent: den 23 mars 2014 17:20
> To: How to use LiveCode
> Subject: Re: 7.0 Issues
> 
> Mats-
> 
> Sunday, March 23, 2014, 4:10:28 AM, you wrote:
> 
> > As rIDE has saved itself upon closing, I too now only have two feet.
> > I will change this for rIDE 4.0. I ask for guidance and opinions here
> > on what would be best practice and the pros and cons of different
> approaches?
> 
> I don't know about "best", but here are some techniques I've adopted (and
> the changes in my behavior are a direct result of the changing file format
and
> the need to maintain compatibility with earlier
> versions):
> 
> When I work on a plugin stack I use LC 4.6.4, as this is the last version
to use
> the 2.4 format natively. That way when I save a plugin stack's changes I
can
> be sure that the format hasn't changed. If I didn't need to maintain
> compatibility back to earlier versions I could use a later LC version, but
in any
> event the native format of the selected version of LiveCode is what's
> important.
> 
> I save a preferences file in the plugin directory and write any values I
want to
> remain persistent into that file. This replaces my previous behavior of
setting
> custom properties and saving the stack. In general I save information into
this
> text file in the format
> 
> property value
> 
> so that it can also be edited by any text processor if necessary.
> Property names are single words, no spaces or punctuation.
> 
> I have somewhat standardized boilerplate routines that read the
> preferences file on opening the stack and set plugin stack properties
> accordingly. Preference file contents are written when necessary (when one
> of them changes; or in the case of a preferences panel, when the Save
> button is clicked rather than the Cancel button). I think GLX2 still saves
all its
> settings on quitting, but I'm too lazy to check right at the moment.
> 
> I no longer use the save-stack-and-revert trick to update a running plugin
> stack because of the problem with maintaining version and format
> compatibility.
> 
> --
> -Mark Wieder
>  ahsoftware at gmail.com
> 
> This communication may be unlawfully collected and stored by the National
> Security Agency (NSA) in secret. The parties to this email do not consent
to
> the retrieving or storing of this communication and any related metadata,
as
> well as printing, copying, re-transmitting, disseminating, or otherwise
using it.
> If you believe you have received this communication in error, please
delete it
> immediately.
> 
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
subscription
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list