Recreating a binary stack from xml text
gcanyon+rev
gcanyon+rev at gmail.com
Sat Feb 18 15:35:13 EST 2012
http://www.inspiredlogic.com/mc/ripper.html
I created mcRipper oh so many years ago. MC = MetaCard gives you some idea how long ago. As I recall it handled just about everything, but I haven't touched it in over ten years. Anyone is free to take a look and laugh at my code.
Sent from my iPad
On Feb 18, 2012, at 2:07 PM, Mark Wieder <mwieder at ahsoftware.net> wrote:
> Pete-
>
> Saturday, February 18, 2012, 11:33:51 AM, you wrote:
>
>> I saw a post earlier in this thread that perhaps Mark Wieder might be
>> working on something along these lines. Mark, can you comment?
>
> If revOnline ever comes back (hello rev team?) I'll post a stack that
> does the translations.
>
> Getting to an from xml format isn't that much of a problem technically
> now that ids are no longer immutable. What's a bit more of a brain
> teaser is preserving the object hierarchy at the same time. I opted
> for individual xml files for each control, card, and stack, as well as
> a project xml file that describes how the objects are organized. That
> way you can create the entire stack from the xml descriptions or just
> pick out individual controls and recreate them.
>
> Creating an object from the xml description is a matter of looping
> through the properties, as in
>
> -- in a try construct to handle read-only properties
> try
> set the <property> of <object> to <attribute>
> catch e
> end try
>
> <stack>
> <card>
> <group>
> <control>
> <property>
> </property>
> </control>
> </group>
> <control>
> </control>
> </card>
> <substack>
> ... etc
> </substack>
> </stack>
>
> --
> -Mark Wieder
> mwieder at ahsoftware.net
>
>
> _______________________________________________
> 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