diff options
| author | Jean-Philippe Bruyère <jp_bruyere@hotmail.com> | 2018-03-13 17:16:24 +0100 |
|---|---|---|
| committer | Jean-Philippe Bruyère <jp_bruyere@hotmail.com> | 2018-03-13 17:16:24 +0100 |
| commit | fda39ed7506551ab48dce271cb2d5e9c63f2b00c (patch) | |
| tree | d0ed602830692962c044f0614639a0939caa03f6 /Tests/BasicTests.cs | |
| parent | 80dc0221c3455a50b8877f19c4a19043af0042f4 (diff) | |
limit to html safe color plus several ones, crowIDE wip
Diffstat (limited to 'Tests/BasicTests.cs')
| -rw-r--r-- | Tests/BasicTests.cs | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/Tests/BasicTests.cs b/Tests/BasicTests.cs index 66ee3d0a..e17f1540 100644 --- a/Tests/BasicTests.cs +++ b/Tests/BasicTests.cs @@ -140,7 +140,8 @@ namespace Tests void OnClear (object sender, MouseButtonEventArgs e) => TestList = null; - void OnLoadList (object sender, MouseButtonEventArgs e) => TestList = Color.ColorDic.Values.ToList(); + void OnLoadList (object sender, MouseButtonEventArgs e) => TestList = + Color.ColorDic.Values.OrderBy(c=>c.Hue).ToList(); void command1(){ Console.WriteLine("command1 triggered"); @@ -159,6 +160,14 @@ namespace Tests { base.OnLoad (e); + foreach (Color c in Color.ColorDic.Values) { + if (string.IsNullOrEmpty(c.htmlCode)) + Console.WriteLine ("no htmlcode for {0}", c.Name); + else if (c.htmlCode.Substring(1) != c.HtmlCode) + Console.WriteLine ("{2} orig: {0} comp: {1}",c.htmlCode, c.HtmlCode, c.Name); + } + + Commands = new List<Crow.Command> (new Crow.Command[] { new Crow.Command(new Action(() => command1())) { Caption = "command1"}, new Crow.Command(new Action(() => command2())) { Caption = "command2"}, @@ -168,7 +177,8 @@ namespace Tests this.KeyDown += KeyboardKeyDown1; - testFiles = new string [] { @"Interfaces/Divers/welcome.crow" }; + //testFiles = new string [] { @"Interfaces/Divers/welcome.crow" }; + testFiles = new string [] { @"Interfaces/Divers/colorPicker.crow" }; testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/GraphicObject", "*.crow")).ToArray (); testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/Container", "*.crow")).ToArray (); testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/Group", "*.crow")).ToArray (); @@ -230,7 +240,7 @@ namespace Tests GraphicObject obj = Load (testFiles[idx]); obj.DataSource = this; } catch (Exception ex) { - MessageBox.Show (CurrentInterface, MessageBox.Type.Error, ex.Message + "\n" + ex.InnerException.Message); + MessageBox.Show (CurrentInterface, MessageBox.Type.Error, ex.Message + "\n" + ex.InnerException.Message).Modal = true; } } // void Tv_SelectedItemChanged (object sender, SelectionChangeEventArgs e) |