diff --git a/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs b/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs index 1139096..d973303 100644 --- a/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs +++ b/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs @@ -51,7 +51,7 @@ protected override void WndProc(ref System.Windows.Forms.Message m) public void SetLanguage(SyntaxSettings.Language lang) { Color white = Color.Black; - Color keyword = Color.Red; + Color keyword = Color.Orange; Color integer = Color.LightGreen; Color comment = Color.DarkGray; Color str = Color.Orange; @@ -76,7 +76,7 @@ public void SetLanguage(SyntaxSettings.Language lang) switch (lang) { case SyntaxSettings.Language.Lua: - var kw = new List() { "function", "local", "return", "if", "else", "elseif", "while", "true", "do", "next", "end", "for", "pairs", "in", "{", "}", "false", "=", "+", "-", "/", "*", "..", "," }; + var kw = new List() { "function", "then", "local", "return", "if", "else", "elseif", "while", "true", "do", "next", "end", "for", "pairs", "in", "{", "}", "false", "=", "+", "-", "/", "*", "..", "," }; Settings.Keywords.Clear(); foreach (var k in kw) { diff --git a/source/WindowsFormsApplication1/SkinEngine/skins.cs b/source/WindowsFormsApplication1/SkinEngine/skins.cs index 206646f..8dcaea2 100644 --- a/source/WindowsFormsApplication1/SkinEngine/skins.cs +++ b/source/WindowsFormsApplication1/SkinEngine/skins.cs @@ -10,6 +10,7 @@ namespace Skinning { + [Obsolete("ShiftOS is moving to the new ShiftUI framework which has a built-in skinning engine. This Skin class is mostly un-needed now.")] public class Skin { //Widget Positions public string ALPosition = "Top"; @@ -561,29 +562,21 @@ private static void saveimage(Image img, string Name) /// public static void loadskin() { - if(Directory.Exists(Paths.LoadedSkin)) + if (Directory.Exists(Paths.LoadedSkin)) { - try { - string rawData = File.ReadAllText(Paths.LoadedSkin + "data.json"); - loadedSkin = JsonConvert.DeserializeObject(rawData); - if (File.Exists(Paths.LoadedSkin + "panels.json")) - { - string panels = File.ReadAllText(Paths.LoadedSkin + "panels.json"); - loadedSkin.DesktopPanels = JsonConvert.DeserializeObject>(panels); - LoadPanels(); - } - loadimages(); - LoadEmbeddedNamePack(); - } - catch + string rawData = File.ReadAllText(Paths.LoadedSkin + "data.json"); + loadedSkin = JsonConvert.DeserializeObject(rawData); + if (File.Exists(Paths.LoadedSkin + "panels.json")) { - //No skin to load. - loadedSkin = new Skin(); - loadedskin_images = new Images(); - saveskin(); - + string panels = File.ReadAllText(Paths.LoadedSkin + "panels.json"); + loadedSkin.DesktopPanels = JsonConvert.DeserializeObject>(panels); + LoadPanels(); } - } else + loadimages(); + LoadEmbeddedNamePack(); + + } + else { loadedSkin = new Skin(); loadedskin_images = new Images();