// This is the main entry point of the application. static void Main(string[] args) { // if you want to use a different Application Delegate class from "AppDelegate" // you can specify it here. GTXAMInfo.SetPlatform("IOS_Xamarin"); UIApplication.Main(args, null, "AppDelegate"); }
public MainWindow() { InitializeComponent(); XmlDocument xmlDocument = new XmlDocument(); xmlDocument.Load("d:\\projects\\freestudio\\FreeStudio\\FreeStudio\\source\\code.xml"); GTXAMInfo.Codes.Add(xmlDocument); GTXAMInfo.SetPlatform("WPF_Xamarin"); Xamarin.Forms.Forms.Init(); LoadApplication(new GTXAM.App()); }
public static void Main(string[] args) { XmlDocument xmlDocument = new XmlDocument(); xmlDocument.LoadXml(@"<?xml version=""1.0"" encoding=""utf-8""?> <code minversion=""1902""> <get value=""Page"" /> <get value=""IO"" /> <get value=""Math"" /> <get value=""Control"" /> <get value=""System"" /> <get value=""String"" /> <get value=""List"" /> <deffun funname=""Main"" params=""args"" isref=""False""> <var_s varname=""page"" str=""var page = Page.Creat("page1");"" /> <getres_s str=""var page = Page.Creat("page1");""> <arg value=""page"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Page.Creat"" con=""var"" /> </fun> <params> <arg value=""page1"" con=""str"" /> </params> </arg> </getres_s> <var_s varname=""bubble"" str=""var bubble = Control.Bubble.Creat("b");"" /> <getres_s str=""var bubble = Control.Bubble.Creat("b");""> <arg value=""bubble"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Control.Bubble.Creat"" con=""var"" /> </fun> <params> <arg value=""b"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""bubble("text","clickme!");""> <arg con=""fun""> <fun> <arg value=""bubble"" con=""var"" /> </fun> <params> <arg value=""text"" con=""str"" /> <arg value=""clickme!"" con=""str"" /> </params> </arg> </usefun_s> <var_s varname=""gd"" str=""var gd = Control.GridFlat.Creat("gf");"" /> <getres_s str=""var gd = Control.GridFlat.Creat("gf");""> <arg value=""gd"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Control.GridFlat.Creat"" con=""var"" /> </fun> <params> <arg value=""gf"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""bubble("clickevent",Click);""> <arg con=""fun""> <fun> <arg value=""bubble"" con=""var"" /> </fun> <params> <arg value=""clickevent"" con=""str"" /> <arg value=""Click"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""gd()(bubble,0,0);""> <arg con=""fun""> <fun> <arg con=""fun""> <fun> <arg value=""gd"" con=""var"" /> </fun> <params /> </arg> </fun> <params> <arg value=""bubble"" con=""var"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </usefun_s> <usefun_s str=""page()(gd);""> <arg con=""fun""> <fun> <arg con=""fun""> <fun> <arg value=""page"" con=""var"" /> </fun> <params /> </arg> </fun> <params> <arg value=""gd"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""Page.Load(page);""> <arg con=""fun""> <fun> <arg value=""Page.Load"" con=""var"" /> </fun> <params> <arg value=""page"" con=""var"" /> </params> </arg> </usefun_s> </deffun> <deffun funname=""Click"" params=""page,e"" isref=""False""> <usefun_s str=""IO.Input();""> <arg con=""fun""> <fun> <arg value=""IO.Input"" con=""var"" /> </fun> <params /> </arg> </usefun_s> </deffun> </code>"); GTXAMInfo.Codes.Add(xmlDocument); GTXAMInfo.SetPlatform("WPF_Xamarin"); Gtk.Application.Init(); Forms.Init(); var app = new App(); var window = new FormsWindow(); window.LoadApplication(app); window.SetApplicationTitle("Game of Life"); window.Show(); Gtk.Application.Run(); }
public override void DidFinishLaunching(NSNotification notification) { XmlDocument xmlDocument = new XmlDocument(); xmlDocument.LoadXml(@"<code minversion=""2007""> <lib name=""FreeStudio""> <get value=""IO"" /> <get value=""Control"" /> <get value=""Page"" /> <get value=""List"" /> <get value=""File"" /> <get value=""String"" /> <deffun funname=""Main"" params=""args"" isref=""False""> <usefun_s str=""WriteLine("hello,world");""> <arg con=""fun""> <fun> <arg value=""WriteLine"" con=""var"" /> </fun> <params> <arg value=""hello,world"" con=""str"" /> </params> </arg> </usefun_s> <var_s varname=""mp"" str=""var mp = MainPage("FreeStudio");"" /> <getres_s str=""var mp = MainPage("FreeStudio");""> <arg value=""mp"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""MainPage"" con=""var"" /> </fun> <params> <arg value=""FreeStudio"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""PageLoad(mp);""> <arg con=""fun""> <fun> <arg value=""PageLoad"" con=""var"" /> </fun> <params> <arg value=""mp"" con=""var"" /> </params> </arg> </usefun_s> </deffun> <cls name=""MainPage"" parent=""Page""> <member value=""gf1"" /> <memfun funname=""init"" params=""title"" isref=""False"" isstatic=""False""> <var_s varname=""tip_title"" str=""var tip_title = Tip("title");"" /> <getres_s str=""var tip_title = Tip("title");""> <arg value=""tip_title"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Tip"" con=""var"" /> </fun> <params> <arg value=""title"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""tip_title:Text = "FreeStudio";""> <arg value=""Text"" con=""mem""> <arg value=""tip_title"" con=""var"" /> </arg> <arg value=""FreeStudio"" con=""str"" /> </getres_s> <getres_s str=""tip_title:FontSize = 60;""> <arg value=""FontSize"" con=""mem""> <arg value=""tip_title"" con=""var"" /> </arg> <arg value=""60"" con=""num"" /> </getres_s> <getres_s str=""tip_title:Horizontal = "center";""> <arg value=""Horizontal"" con=""mem""> <arg value=""tip_title"" con=""var"" /> </arg> <arg value=""center"" con=""str"" /> </getres_s> <getres_s str=""tip_title:Vertical = "center";""> <arg value=""Vertical"" con=""mem""> <arg value=""tip_title"" con=""var"" /> </arg> <arg value=""center"" con=""str"" /> </getres_s> <getres_s str=""tip_title:Margin = List(0,0,0,450);""> <arg value=""Margin"" con=""mem""> <arg value=""tip_title"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""List"" con=""var"" /> </fun> <params> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""450"" con=""num"" /> </params> </arg> </getres_s> <getres_s str=""tip_title:Foreground = "white";""> <arg value=""Foreground"" con=""mem""> <arg value=""tip_title"" con=""var"" /> </arg> <arg value=""white"" con=""str"" /> </getres_s> <var_s varname=""bu_1"" str=""var bu_1 = Bubble("bu_1");"" /> <getres_s str=""var bu_1 = Bubble("bu_1");""> <arg value=""bu_1"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Bubble"" con=""var"" /> </fun> <params> <arg value=""bu_1"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""bu_1:Text = "创建一个项目";""> <arg value=""Text"" con=""mem""> <arg value=""bu_1"" con=""var"" /> </arg> <arg value=""创建一个项目"" con=""str"" /> </getres_s> <getres_s str=""bu_1:FontSize = 30;""> <arg value=""FontSize"" con=""mem""> <arg value=""bu_1"" con=""var"" /> </arg> <arg value=""30"" con=""num"" /> </getres_s> <getres_s str=""bu_1:Height = 60;""> <arg value=""Height"" con=""mem""> <arg value=""bu_1"" con=""var"" /> </arg> <arg value=""60"" con=""num"" /> </getres_s> <getres_s str=""bu_1:Width = 220;""> <arg value=""Width"" con=""mem""> <arg value=""bu_1"" con=""var"" /> </arg> <arg value=""220"" con=""num"" /> </getres_s> <getres_s str=""bu_1:Margin = List(0,0,0,230);""> <arg value=""Margin"" con=""mem""> <arg value=""bu_1"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""List"" con=""var"" /> </fun> <params> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""230"" con=""num"" /> </params> </arg> </getres_s> <getres_s str=""bu_1:Foreground = "white";""> <arg value=""Foreground"" con=""mem""> <arg value=""bu_1"" con=""var"" /> </arg> <arg value=""white"" con=""str"" /> </getres_s> <var_s varname=""bu_2"" str=""var bu_2 = Bubble("bu_2");"" /> <getres_s str=""var bu_2 = Bubble("bu_2");""> <arg value=""bu_2"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Bubble"" con=""var"" /> </fun> <params> <arg value=""bu_2"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""bu_2:Text = "打开一个项目";""> <arg value=""Text"" con=""mem""> <arg value=""bu_2"" con=""var"" /> </arg> <arg value=""打开一个项目"" con=""str"" /> </getres_s> <getres_s str=""bu_2:FontSize = 30;""> <arg value=""FontSize"" con=""mem""> <arg value=""bu_2"" con=""var"" /> </arg> <arg value=""30"" con=""num"" /> </getres_s> <getres_s str=""bu_2:Height = 60;""> <arg value=""Height"" con=""mem""> <arg value=""bu_2"" con=""var"" /> </arg> <arg value=""60"" con=""num"" /> </getres_s> <getres_s str=""bu_2:Width = 220;""> <arg value=""Width"" con=""mem""> <arg value=""bu_2"" con=""var"" /> </arg> <arg value=""220"" con=""num"" /> </getres_s> <getres_s str=""bu_2:Margin = List(0,0,0,110);""> <arg value=""Margin"" con=""mem""> <arg value=""bu_2"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""List"" con=""var"" /> </fun> <params> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""110"" con=""num"" /> </params> </arg> </getres_s> <getres_s str=""bu_2:Foreground = "white";""> <arg value=""Foreground"" con=""mem""> <arg value=""bu_2"" con=""var"" /> </arg> <arg value=""white"" con=""str"" /> </getres_s> <var_s varname=""bu_3"" str=""var bu_3 = Bubble("bu_3");"" /> <getres_s str=""var bu_3 = Bubble("bu_3");""> <arg value=""bu_3"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Bubble"" con=""var"" /> </fun> <params> <arg value=""bu_3"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""bu_3:Text = "帮助";""> <arg value=""Text"" con=""mem""> <arg value=""bu_3"" con=""var"" /> </arg> <arg value=""帮助"" con=""str"" /> </getres_s> <getres_s str=""bu_3:FontSize = 30;""> <arg value=""FontSize"" con=""mem""> <arg value=""bu_3"" con=""var"" /> </arg> <arg value=""30"" con=""num"" /> </getres_s> <getres_s str=""bu_3:Height = 60;""> <arg value=""Height"" con=""mem""> <arg value=""bu_3"" con=""var"" /> </arg> <arg value=""60"" con=""num"" /> </getres_s> <getres_s str=""bu_3:Width = 220;""> <arg value=""Width"" con=""mem""> <arg value=""bu_3"" con=""var"" /> </arg> <arg value=""220"" con=""num"" /> </getres_s> <getres_s str=""bu_3:Margin = List(0,10,0,0);""> <arg value=""Margin"" con=""mem""> <arg value=""bu_3"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""List"" con=""var"" /> </fun> <params> <arg value=""0"" con=""num"" /> <arg value=""10"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </getres_s> <getres_s str=""bu_3:Foreground = "white";""> <arg value=""Foreground"" con=""mem""> <arg value=""bu_3"" con=""var"" /> </arg> <arg value=""white"" con=""str"" /> </getres_s> <var_s varname=""bu_4"" str=""var bu_4 = Bubble("bu_4");"" /> <getres_s str=""var bu_4 = Bubble("bu_4");""> <arg value=""bu_4"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Bubble"" con=""var"" /> </fun> <params> <arg value=""bu_4"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""bu_4:Text = "设置";""> <arg value=""Text"" con=""mem""> <arg value=""bu_4"" con=""var"" /> </arg> <arg value=""设置"" con=""str"" /> </getres_s> <getres_s str=""bu_4:FontSize = 30;""> <arg value=""FontSize"" con=""mem""> <arg value=""bu_4"" con=""var"" /> </arg> <arg value=""30"" con=""num"" /> </getres_s> <getres_s str=""bu_4:Height = 60;""> <arg value=""Height"" con=""mem""> <arg value=""bu_4"" con=""var"" /> </arg> <arg value=""60"" con=""num"" /> </getres_s> <getres_s str=""bu_4:Width = 220;""> <arg value=""Width"" con=""mem""> <arg value=""bu_4"" con=""var"" /> </arg> <arg value=""220"" con=""num"" /> </getres_s> <getres_s str=""bu_4:Margin = List(0,130,0,0);""> <arg value=""Margin"" con=""mem""> <arg value=""bu_4"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""List"" con=""var"" /> </fun> <params> <arg value=""0"" con=""num"" /> <arg value=""130"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </getres_s> <getres_s str=""bu_4:Foreground = "white";""> <arg value=""Foreground"" con=""mem""> <arg value=""bu_4"" con=""var"" /> </arg> <arg value=""white"" con=""str"" /> </getres_s> <getres_s str=""this:gf1 = GridFlat("gf1");""> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""GridFlat"" con=""var"" /> </fun> <params> <arg value=""gf1"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""this:gf1:Background = "#323232";""> <arg value=""Background"" con=""mem""> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> <arg value=""#323232"" con=""str"" /> </getres_s> <usefun_s str=""this:gf1:Add(tip_title,0,0);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""tip_title"" con=""var"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </usefun_s> <usefun_s str=""this:gf1:Add(bu_1,0,0);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""bu_1"" con=""var"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </usefun_s> <usefun_s str=""this:gf1:Add(bu_2,0,0);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""bu_2"" con=""var"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </usefun_s> <usefun_s str=""this:gf1:Add(bu_3,0,0);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""bu_3"" con=""var"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </usefun_s> <usefun_s str=""this:gf1:Add(bu_4,0,0);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""bu_4"" con=""var"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </usefun_s> <usefun_s str=""this:SetContent(this:gf1);""> <arg con=""fun""> <fun> <arg value=""SetContent"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </fun> <params> <arg value=""gf1"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </params> </arg> </usefun_s> </memfun> </cls> </lib> </code>"); GTXAMInfo.Codes.Add(xmlDocument); GTXAMInfo.SetPlatform("Mac_Xamarin"); Forms.Init(); LoadApplication(new GTXAM.App()); base.DidFinishLaunching(notification); }
public MainPage() { this.InitializeComponent(); XmlDocument xmlDocument = new XmlDocument(); xmlDocument.LoadXml(@"<code minversion=""2007""> <lib name=""App1""> <get value=""IO"" /> <get value=""Control"" /> <get value=""Page"" /> <get value=""List"" /> <get value=""File"" /> <var value=""web"" /> <get value=""Xml"" /> <get value=""System"" /> <get value=""Thread"" /> <deffun funname=""Main"" params=""args"" isref=""False""> <var_s varname=""s"" str=""var s = PickFile("文本文档|*.txt");"" /> <getres_s str=""var s = PickFile("文本文档|*.txt");""> <arg value=""s"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""PickFile"" con=""var"" /> </fun> <params> <arg value=""文本文档|*.txt"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""WriteLine(s:ReadText());""> <arg con=""fun""> <fun> <arg value=""WriteLine"" con=""var"" /> </fun> <params> <arg con=""fun""> <fun> <arg value=""ReadText"" con=""mem""> <arg value=""s"" con=""var"" /> </arg> </fun> <params /> </arg> </params> </arg> </usefun_s> </deffun> <deffun funname=""Mainad"" params=""aargs"" isref=""False""> <var_s varname=""stackflat"" str=""var stackflat = StackFlat("sf");"" /> <getres_s str=""var stackflat = StackFlat("sf");""> <arg value=""stackflat"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""StackFlat"" con=""var"" /> </fun> <params> <arg value=""sf"" con=""str"" /> </params> </arg> </getres_s> <var_s varname=""tip1"" str=""var tip1 = Tip("tip1");"" /> <getres_s str=""var tip1 = Tip("tip1");""> <arg value=""tip1"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Tip"" con=""var"" /> </fun> <params> <arg value=""tip1"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""tip1:Text = "tip1";""> <arg value=""Text"" con=""mem""> <arg value=""tip1"" con=""var"" /> </arg> <arg value=""tip1"" con=""str"" /> </getres_s> <var_s varname=""tip2"" str=""var tip2 = Tip("tip2");"" /> <getres_s str=""var tip2 = Tip("tip2");""> <arg value=""tip2"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Tip"" con=""var"" /> </fun> <params> <arg value=""tip2"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""tip2:Text = "tip2";""> <arg value=""Text"" con=""mem""> <arg value=""tip2"" con=""var"" /> </arg> <arg value=""tip2"" con=""str"" /> </getres_s> <usefun_s str=""stackflat:Add(tip1);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""stackflat"" con=""var"" /> </arg> </fun> <params> <arg value=""tip1"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""stackflat:Add(tip2);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""stackflat"" con=""var"" /> </arg> </fun> <params> <arg value=""tip2"" con=""var"" /> </params> </arg> </usefun_s> <getres_s str=""stackflat:Orientation = "horizontal";""> <arg value=""Orientation"" con=""mem""> <arg value=""stackflat"" con=""var"" /> </arg> <arg value=""horizontal"" con=""str"" /> </getres_s> <var_s varname=""page"" str=""var page = Page("title");"" /> <getres_s str=""var page = Page("title");""> <arg value=""page"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Page"" con=""var"" /> </fun> <params> <arg value=""title"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""page:SetContent(stackflat);""> <arg con=""fun""> <fun> <arg value=""SetContent"" con=""mem""> <arg value=""page"" con=""var"" /> </arg> </fun> <params> <arg value=""stackflat"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""PageLoad(page);""> <arg con=""fun""> <fun> <arg value=""PageLoad"" con=""var"" /> </fun> <params> <arg value=""page"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""WriteLine(stackflat);""> <arg con=""fun""> <fun> <arg value=""WriteLine"" con=""var"" /> </fun> <params> <arg value=""stackflat"" con=""var"" /> </params> </arg> </usefun_s> </deffun> <deffun funname=""Mainss"" params=""args"" isref=""False""> <var_s varname=""file"" str=""var file = FileOpen("X:\\projects\\freestudio\\App1\\App1.gca","open");"" /> <getres_s str=""var file = FileOpen("X:\\projects\\freestudio\\App1\\App1.gca","open");""> <arg value=""file"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""FileOpen"" con=""var"" /> </fun> <params> <arg value=""X:\projects\freestudio\App1\App1.gca"" con=""str"" /> <arg value=""open"" con=""str"" /> </params> </arg> </getres_s> <var_s varname=""xml"" str=""var xml = XmlDocument();"" /> <getres_s str=""var xml = XmlDocument();""> <arg value=""xml"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""XmlDocument"" con=""var"" /> </fun> <params /> </arg> </getres_s> <usefun_s str=""WriteLine(xml);""> <arg con=""fun""> <fun> <arg value=""WriteLine"" con=""var"" /> </fun> <params> <arg value=""xml"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""xml:Load(file);""> <arg con=""fun""> <fun> <arg value=""Load"" con=""mem""> <arg value=""xml"" con=""var"" /> </arg> </fun> <params> <arg value=""file"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""file:Close();""> <arg con=""fun""> <fun> <arg value=""Close"" con=""mem""> <arg value=""file"" con=""var"" /> </arg> </fun> <params /> </arg> </usefun_s> <usefun_s str=""xml:Content:SetAttribute("text","helloworld");""> <arg con=""fun""> <fun> <arg value=""SetAttribute"" con=""mem""> <arg value=""Content"" con=""mem""> <arg value=""xml"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""text"" con=""str"" /> <arg value=""helloworld"" con=""str"" /> </params> </arg> </usefun_s> <var_s varname=""child1"" str=""var child1 = xml:Content:GetChild(0);"" /> <getres_s str=""var child1 = xml:Content:GetChild(0);""> <arg value=""child1"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""GetChild"" con=""mem""> <arg value=""Content"" con=""mem""> <arg value=""xml"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""0"" con=""num"" /> </params> </arg> </getres_s> <usefun_s str=""xml:Content:RemoveChild(child1);""> <arg con=""fun""> <fun> <arg value=""RemoveChild"" con=""mem""> <arg value=""Content"" con=""mem""> <arg value=""xml"" con=""var"" /> </arg> </arg> </fun> <params> <arg value=""child1"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""xml:Save(FileOpen("X:\\projects\\freestudio\\App1\\App1.gca","creat"));""> <arg con=""fun""> <fun> <arg value=""Save"" con=""mem""> <arg value=""xml"" con=""var"" /> </arg> </fun> <params> <arg con=""fun""> <fun> <arg value=""FileOpen"" con=""var"" /> </fun> <params> <arg value=""X:\projects\freestudio\App1\App1.gca"" con=""str"" /> <arg value=""creat"" con=""str"" /> </params> </arg> </params> </arg> </usefun_s> </deffun> <deffun funname=""Mains"" params=""args"" isref=""False""> <var_s varname=""page"" str=""var page = Page("page");"" /> <getres_s str=""var page = Page("page");""> <arg value=""page"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Page"" con=""var"" /> </fun> <params> <arg value=""page"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""page:AddTool("click",Click);""> <arg con=""fun""> <fun> <arg value=""AddTool"" con=""mem""> <arg value=""page"" con=""var"" /> </arg> </fun> <params> <arg value=""click"" con=""str"" /> <arg value=""Click"" con=""var"" /> </params> </arg> </usefun_s> <getres_s str=""web = WebView("wb");""> <arg value=""web"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""WebView"" con=""var"" /> </fun> <params> <arg value=""wb"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""web:Url = "\\\\Mac\Home\Downloads\codemirror-5.59.1\gasoline\zzzz.html";""> <arg value=""Url"" con=""mem""> <arg value=""web"" con=""var"" /> </arg> <arg value=""\\Mac\Home\Downloads\codemirror-5.59.1\gasoline\zzzz.html"" con=""str"" /> </getres_s> <getres_s str=""web:Margin = List(0,100,0,0);""> <arg value=""Margin"" con=""mem""> <arg value=""web"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""List"" con=""var"" /> </fun> <params> <arg value=""0"" con=""num"" /> <arg value=""100"" con=""num"" /> <arg value=""0"" con=""num"" /> <arg value=""0"" con=""num"" /> </params> </arg> </getres_s> <usefun_s str=""page:SetContent(web);""> <arg con=""fun""> <fun> <arg value=""SetContent"" con=""mem""> <arg value=""page"" con=""var"" /> </arg> </fun> <params> <arg value=""web"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""PageLoad(page);""> <arg con=""fun""> <fun> <arg value=""PageLoad"" con=""var"" /> </fun> <params> <arg value=""page"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""WriteLine(web);""> <arg con=""fun""> <fun> <arg value=""WriteLine"" con=""var"" /> </fun> <params> <arg value=""web"" con=""var"" /> </params> </arg> </usefun_s> </deffun> <deffun funname=""Click"" params=""page,e"" isref=""False""> <usefun_s str=""web:InvokeJS("setValue","ok");""> <arg con=""fun""> <fun> <arg value=""InvokeJS"" con=""mem""> <arg value=""web"" con=""var"" /> </arg> </fun> <params> <arg value=""setValue"" con=""str"" /> <arg value=""ok"" con=""str"" /> </params> </arg> </usefun_s> </deffun> </lib> </code>"); GTXAMInfo.Codes = xmlDocument; GTXAMInfo.SetPlatform("UWP_Xamarin"); LoadApplication(new GTXAM.App()); }
// // This method is invoked when the application has loaded and is ready to run. In this // method you should instantiate the window, load the UI into it and then make the window // visible. // // You have 17 seconds to return from this method, or iOS will terminate your application. // public override bool FinishedLaunching(UIApplication app, NSDictionary options) { XmlDocument xmlDocument = new XmlDocument(); xmlDocument.LoadXml(@"<code minversion=""2007""> <lib name=""App1""> <get value=""Math"" /> <get value=""IO"" /> <get value=""Control"" /> <get value=""Page"" /> <get value=""List"" /> <get value=""String"" /> <deffun funname=""Main"" params=""args"" isref=""False""> <var_s varname=""listflat"" str=""var listflat = ListFlat("ft");"" /> <getres_s str=""var listflat = ListFlat("ft");""> <arg value=""listflat"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""ListFlat"" con=""var"" /> </fun> <params> <arg value=""ft"" con=""str"" /> </params> </arg> </getres_s> <foreach_s var_togive=""i"" var_new=""True"" str=""foreach(var i , Range(1,5)):""> <from> <arg con=""fun""> <fun> <arg value=""Range"" con=""var"" /> </fun> <params> <arg value=""1"" con=""num"" /> <arg value=""5"" con=""num"" /> </params> </arg> </from> <run> <usefun_s str=""WriteLine(i);""> <arg con=""fun""> <fun> <arg value=""WriteLine"" con=""var"" /> </fun> <params> <arg value=""i"" con=""var"" /> </params> </arg> </usefun_s> <var_s varname=""textcell"" str=""var textcell = TextCell("tc");"" /> <getres_s str=""var textcell = TextCell("tc");""> <arg value=""textcell"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""TextCell"" con=""var"" /> </fun> <params> <arg value=""tc"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""textcell:Text = "item" & i;""> <arg value=""Text"" con=""mem""> <arg value=""textcell"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""StringAdd"" con=""var"" /> </fun> <params> <arg value=""item"" con=""str"" /> <arg value=""i"" con=""var"" /> </params> </arg> </getres_s> <getres_s str=""textcell:Detail = "this is item" & i;""> <arg value=""Detail"" con=""mem""> <arg value=""textcell"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""StringAdd"" con=""var"" /> </fun> <params> <arg value=""this is item"" con=""str"" /> <arg value=""i"" con=""var"" /> </params> </arg> </getres_s> <getres_s str=""textcell:Clickevent = Click;""> <arg value=""Clickevent"" con=""mem""> <arg value=""textcell"" con=""var"" /> </arg> <arg value=""Click"" con=""var"" /> </getres_s> <usefun_s str=""listflat:Add(textcell);""> <arg con=""fun""> <fun> <arg value=""Add"" con=""mem""> <arg value=""listflat"" con=""var"" /> </arg> </fun> <params> <arg value=""textcell"" con=""var"" /> </params> </arg> </usefun_s> </run> </foreach_s> <var_s varname=""page"" str=""var page = Page("title");"" /> <getres_s str=""var page = Page("title");""> <arg value=""page"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""Page"" con=""var"" /> </fun> <params> <arg value=""title"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""page:SetContent(listflat);""> <arg con=""fun""> <fun> <arg value=""SetContent"" con=""mem""> <arg value=""page"" con=""var"" /> </arg> </fun> <params> <arg value=""listflat"" con=""var"" /> </params> </arg> </usefun_s> <usefun_s str=""PageLoad(page);""> <arg con=""fun""> <fun> <arg value=""PageLoad"" con=""var"" /> </fun> <params> <arg value=""page"" con=""var"" /> </params> </arg> </usefun_s> </deffun> <deffun funname=""Click"" params=""object,e"" isref=""False""> <usefun_s str=""Message("you have clicked me");""> <arg con=""fun""> <fun> <arg value=""Message"" con=""var"" /> </fun> <params> <arg value=""you have clicked me"" con=""str"" /> </params> </arg> </usefun_s> </deffun> </lib> </code>"); GTXAMInfo.Codes.Add(xmlDocument); GTXAMInfo.SetPlatform("IOS_Xamarin"); global::Xamarin.Forms.Forms.Init(); LoadApplication(new App()); return(base.FinishedLaunching(app, options)); }
public static void Main(string[] args) { XmlDocument xmlDocument = new XmlDocument(); xmlDocument.LoadXml(@"<?xml version=""1.0"" encoding=""utf-8""?> <code minversion=""2007""> <lib name=""Program""> <get value=""IO"" /> <get value=""Control"" /> <get value=""Page"" /> <deffun funname=""Main"" params=""args"" isref=""False""> <var_s varname=""page"" str=""var page = MainPage("MainPage");"" /> <getres_s str=""var page = MainPage("MainPage");""> <arg value=""page"" con=""var"" /> <arg con=""fun""> <fun> <arg value=""MainPage"" con=""var"" /> </fun> <params> <arg value=""MainPage"" con=""str"" /> </params> </arg> </getres_s> <usefun_s str=""PageLoad(page);""> <arg con=""fun""> <fun> <arg value=""PageLoad"" con=""var"" /> </fun> <params> <arg value=""page"" con=""var"" /> </params> </arg> </usefun_s> </deffun> <cls name=""MainPage"" parent=""Page""> <member value=""bubble"" /> <member value=""tip"" /> <memfun funname=""init"" params=""title"" isref=""False"" isstatic=""False""> <getres_s str=""this:bubble = Bubble("bu");""> <arg value=""bubble"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> <arg con=""fun""> <fun> <arg value=""Bubble"" con=""var"" /> </fun> <params> <arg value=""bu"" con=""str"" /> </params> </arg> </getres_s> <getres_s str=""this:bubble:Text = "Click me!";""> <arg value=""Text"" con=""mem""> <arg value=""bubble"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> <arg value=""Click me!"" con=""str"" /> </getres_s> <getres_s str=""this:bubble:Clickevent = this:BuClick;""> <arg value=""Clickevent"" con=""mem""> <arg value=""bubble"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </arg> <arg value=""BuClick"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </getres_s> <usefun_s str=""this:SetContent(this:bubble);""> <arg con=""fun""> <fun> <arg value=""SetContent"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </fun> <params> <arg value=""bubble"" con=""mem""> <arg value=""this"" con=""var"" /> </arg> </params> </arg> </usefun_s> </memfun> <memfun funname=""BuClick"" params=""page,e"" isref=""False"" isstatic=""False""> <usefun_s str=""Message("HHH");""> <arg con=""fun""> <fun> <arg value=""Message"" con=""var"" /> </fun> <params> <arg value=""HHH"" con=""str"" /> </params> </arg> </usefun_s> </memfun> </cls> </lib> </code>"); GTXAMInfo.Codes = xmlDocument; GTXAMInfo.SetPlatform("GTK_Xamarin"); Gtk.Application.Init(); Forms.Init(); var app = new GTXAM.App(); var window = new FormsWindow(); window.LoadApplication(app); window.SetApplicationTitle("Gasoline"); window.Show(); Gtk.Application.Run(); }