diff options
Diffstat (limited to 'Tests')
| -rw-r--r-- | Tests/BasicTests.cs | 14 | ||||
| -rw-r--r-- | Tests/GraphicObjects/TechBorder.cs | 2 | ||||
| -rw-r--r-- | Tests/Interfaces/Divers/welcome.crow | 2 | ||||
| -rwxr-xr-x | Tests/Interfaces/TemplatedContainer/0.crow | 2 | ||||
| -rwxr-xr-x | Tests/Interfaces/TemplatedContainer/6.crow | 21 | ||||
| -rwxr-xr-x | Tests/Interfaces/TemplatedContainer/7.crow | 25 | ||||
| -rwxr-xr-x | Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow | 68 | ||||
| -rw-r--r-- | Tests/Showcase.cs | 2 | ||||
| -rw-r--r-- | Tests/Tests.csproj | 6 | ||||
| -rwxr-xr-x | Tests/ui/showcase.crow | 10 |
10 files changed, 51 insertions, 101 deletions
diff --git a/Tests/BasicTests.cs b/Tests/BasicTests.cs index 149ff4a9..9691f9ec 100644 --- a/Tests/BasicTests.cs +++ b/Tests/BasicTests.cs @@ -177,9 +177,13 @@ namespace Tests this.KeyDown += KeyboardKeyDown1; - testFiles = new string [] { @"Interfaces/Experimental/testDock.crow" }; + //testFiles = new string [] { @"Interfaces/Experimental/testDock.crow" }; //testFiles = new string [] { @"Interfaces/Divers/welcome.crow" }; + //testFiles = new string [] { @"Interfaces/Divers/0.crow" }; + testFiles = new string [] { @"Interfaces/TemplatedContainer/testTreeView.crow" }; //testFiles = new string [] { @"Interfaces/Divers/colorPicker.crow" }; +// testFiles = new string[] { @"Interfaces/TemplatedControl/testItemTemplateTag.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 (); @@ -195,10 +199,10 @@ namespace Tests Load(testFiles[idx]).DataSource = this; - LoadIMLFragment (@"<DockWindow Width=""150"" Height=""150"" Background=""DarkRed"" />", 0); - LoadIMLFragment (@"<DockWindow Width=""200"" Height=""150"" Background=""DarkGreen"" />", 0); - LoadIMLFragment (@"<DockWindow Width=""250"" Height=""150"" Background=""Brown"" />", 0); - LoadIMLFragment (@"<DockWindow Width=""300"" Height=""150"" Background=""DarkBlue"" />", 0); +// LoadIMLFragment (@"<DockWindow Width=""150"" Height=""150"" Background=""DarkRed"" />", 0); +// LoadIMLFragment (@"<DockWindow Width=""200"" Height=""150"" Background=""DarkGreen"" />", 0); +// LoadIMLFragment (@"<DockWindow Width=""250"" Height=""150"" Background=""Brown"" />", 0); +// LoadIMLFragment (@"<DockWindow Width=""300"" Height=""150"" Background=""DarkBlue"" />", 0); } diff --git a/Tests/GraphicObjects/TechBorder.cs b/Tests/GraphicObjects/TechBorder.cs index 4f818e51..d1f73324 100644 --- a/Tests/GraphicObjects/TechBorder.cs +++ b/Tests/GraphicObjects/TechBorder.cs @@ -33,7 +33,7 @@ namespace Tests public TechBorder () : base() {} public TechBorder (Interface iface): base (iface){} - protected override int measureRawSize (LayoutingType lt) + protected override int measureRawSize(LayoutingType lt) { return base.measureRawSize (lt) + 6; } diff --git a/Tests/Interfaces/Divers/welcome.crow b/Tests/Interfaces/Divers/welcome.crow index 3445ef1c..74018ebe 100644 --- a/Tests/Interfaces/Divers/welcome.crow +++ b/Tests/Interfaces/Divers/welcome.crow @@ -1,2 +1,2 @@ <?xml version="1.0"?> -<GraphicObject Height="30" Width="30" Background="#500000"/>
\ No newline at end of file +<ColorCircleSelector />
\ No newline at end of file diff --git a/Tests/Interfaces/TemplatedContainer/0.crow b/Tests/Interfaces/TemplatedContainer/0.crow index 195b981b..b53fa4ec 100755 --- a/Tests/Interfaces/TemplatedContainer/0.crow +++ b/Tests/Interfaces/TemplatedContainer/0.crow @@ -7,7 +7,7 @@ <CheckBox Name="chk4" /> <HorizontalStack Fit="true" Margin="2" Background="SeaGreen"> <Label Name="captionFps" Text="Fps:" Width="30" TextAlignment="Right"/> - <Label Name="valueFps" Text="{fps}" Font="droid , 12" Width="Fit" TextAlignment="Center" Background="AoEnglish"/> + <Label Name="valueFps" Text="{fps}" Font="droid , 12" Width="Fit" TextAlignment="Center" Background="Teal"/> </HorizontalStack> </VerticalStack> </Expandable> diff --git a/Tests/Interfaces/TemplatedContainer/6.crow b/Tests/Interfaces/TemplatedContainer/6.crow deleted file mode 100755 index 041bdf52..00000000 --- a/Tests/Interfaces/TemplatedContainer/6.crow +++ /dev/null @@ -1,21 +0,0 @@ -<Expandable Width="Stretched" Background="Gray"> - <Expandable Width="Stretched" Background="LightBlue"> - <Expandable Width="Stretched" Background="Green"> - <Expandable Width="Stretched" Background="LimeGreen"> - <Expandable Width="Stretched" Background="DimGray"> - <Expandable Width="Stretched" Background="Yellow"> - <Expandable Width="Stretched" Background="NavyBlue"> - <Expandable Width="Stretched" Background="Blue"> - <Expandable Width="Stretched" Background="BlueCrayola"> - <Expandable Width="Stretched" Background="Green"> - <Label Background="Red" Text="{fps}"/> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable>
\ No newline at end of file diff --git a/Tests/Interfaces/TemplatedContainer/7.crow b/Tests/Interfaces/TemplatedContainer/7.crow deleted file mode 100755 index 0c94b6c4..00000000 --- a/Tests/Interfaces/TemplatedContainer/7.crow +++ /dev/null @@ -1,25 +0,0 @@ -<?xml version="1.0"?> -<VerticalStack Height="Fit" Width="Fit"> - <Label Width="Stretched"/> - <Expandable Width="Fit" Background="Gray"> - <Expandable Background="LightBlue"> - <Expandable Background="Green"> - <Expandable Background="LimeGreen"> - <Expandable Background="DimGray"> - <Expandable Width="Stretched" Background="Yellow"> - <Expandable Background="NavyBlue"> - <Expandable Width="Stretched" Background="Blue"> - <Expandable Width="Stretched" Background="BlueCrayola"> - <Expandable Width="Stretched" Background="Green"> - <Label Background="Red" Text="{fps}"/> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> - </Expandable> -</VerticalStack> diff --git a/Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow b/Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow index 90c475a5..7ddaf863 100755 --- a/Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow +++ b/Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow @@ -1,37 +1,33 @@ <?xml version="1.0"?> -<Border BorderWidth="2" Fit="true"> - <VerticalStack Fit="true" Margin="5"> - <ListBox Data="{TestList}" Background="0.5,0.5,0.5,0.7" - HorizontalAlignment="Center" Width="200" Height="200" Margin="5"> - <Template> - <Border BorderWidth="1"> - <HorizontalStack Margin="1"> - <Scroller Name="scroller1" - Margin="2" ScrollY="{../scrollbar1.Value}"> - <VerticalStack Height="Fit" MinimumSize="10,10" - Name="ItemsContainer" Margin="0" VerticalAlignment="Top"/> - </Scroller> - <ScrollBar Name="scrollbar1" Value="{²../scroller1.ScrollY}" - LargeIncrement="{../scroller1.PageHeight}" SmallIncrement="30" CursorSize="{../scroller1.ChildHeightRatio}" - Maximum="{../scroller1.MaximumScroll}" Orientation="Vertical" - Width="14" /> - </HorizontalStack> - </Border> - </Template> - <ItemTemplate DataType="Crow.Color"> - <HorizontalStack - HorizontalAlignment="Left" - Height="Fit" Width="200" Margin="1" Focusable="true" - MouseEnter="{Background=hgradient|0:DarkRed|1:Transparent}" - MouseLeave="{Background=Transparent}"> - <GraphicObject Height="12" Width="20" Background="{}" Margin="0" CornerRadius="3"/> - <Label Text="{}" Margin="0" Width="Stretched"/> - </HorizontalStack> - </ItemTemplate> - </ListBox> - <HorizontalStack Fit="true" HorizontalAlignment="Right"> - <Button Caption="Load list" MouseDown="OnLoadList"/> - <Button Caption="Clear" MouseDown="OnClear"/> - </HorizontalStack> - </VerticalStack> -</Border> +<VerticalStack Fit="true" Margin="5"> + <ListBox Data="{TestList}" + HorizontalAlignment="Center" Width="200" Height="200" Margin="5"> + <Template> + <HorizontalStack Margin="1"> + <Scroller Name="scroller1" Margin="2" > + <VerticalStack Height="Fit" MinimumSize="10,10" Width="Stretched" + Name="ItemsContainer" Margin="0" VerticalAlignment="Top"/> + </Scroller> + <ScrollBar Name="scrollbar1" Value="{²../scroller1.ScrollY}" + LargeIncrement="{../scroller1.PageHeight}" SmallIncrement="30" + CursorSize="{../scroller1.ChildHeightRatio}" + Maximum="{../scroller1.MaxScrollY}" Orientation="Vertical" + Width="14" /> + </HorizontalStack> + </Template> + <ItemTemplate DataType="Crow.Color"> + <HorizontalStack + HorizontalAlignment="Left" + Height="Fit" Width="200" Margin="1" Focusable="true" + MouseEnter="{Background=hgradient|0:DarkRed|1:Transparent}" + MouseLeave="{Background=Transparent}"> + <GraphicObject Name="colIco" Height="12" Width="20" Background="{}" Margin="0" CornerRadius="3"/> + <Label Text="{}" Margin="0" Width="Stretched"/> + </HorizontalStack> + </ItemTemplate> + </ListBox> + <HorizontalStack Fit="true" HorizontalAlignment="Right"> + <Button Caption="Load list" MouseDown="OnLoadList"/> + <Button Caption="Clear" MouseDown="OnClear"/> + </HorizontalStack> +</VerticalStack> diff --git a/Tests/Showcase.cs b/Tests/Showcase.cs index da9b99dc..21593022 100644 --- a/Tests/Showcase.cs +++ b/Tests/Showcase.cs @@ -63,7 +63,7 @@ namespace Tests crowContainer = g.FindByName ("CrowContainer") as Container; //I set an empty object as datasource at this level to force update when new //widgets are added to the interface - crowContainer.DataSource = new object (); + //crowContainer.DataSource = new object (); hideError (); } diff --git a/Tests/Tests.csproj b/Tests/Tests.csproj index c86ff9cb..ab976241 100644 --- a/Tests/Tests.csproj +++ b/Tests/Tests.csproj @@ -269,12 +269,6 @@ <None Include="Interfaces\TemplatedContainer\0.crow"> <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> </None> - <None Include="Interfaces\TemplatedContainer\6.crow"> - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> - </None> - <None Include="Interfaces\TemplatedContainer\7.crow"> - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> - </None> <None Include="Interfaces\TemplatedControl\testButton.crow"> <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> </None> diff --git a/Tests/ui/showcase.crow b/Tests/ui/showcase.crow index 61df4443..9e273326 100755 --- a/Tests/ui/showcase.crow +++ b/Tests/ui/showcase.crow @@ -1,7 +1,8 @@ <?xml version="1.0"?> +<Border Margin="5" Height="90%" Width="20%"> <HorizontalStack Background="Jet" Margin="5"> - <DirectoryView Name="dv" CurrentDirectory="Interfaces" Width="25%" SelectedItemChanged="Dv_SelectedItemChanged"/> - <Splitter Width="6"/> + <DirectoryView Name="dv" CurrentDirectory="Interfaces" SelectedItemChanged="Dv_SelectedItemChanged"/> +<!-- <Splitter Width="6"/> <VerticalStack> <Container Name="CrowContainer" Height="60%" Background="DimGray"/> <Splitter/> @@ -16,10 +17,11 @@ <ScrollBar Name="scrollbar1" Value="{../scroller1.ScrollY}" LargeIncrement="{../scroller1.PageHeight}" SmallIncrement="30" CursorSize="{../scroller1.ChildHeightRatio}" - Maximum="{../scroller1.MaximumScroll}" Orientation="Vertical" + Maximum="{../scroller1.MaxScrollY}" Orientation="Vertical" Width="14" /> </HorizontalStack> <Label Visible="{ShowError}" Text="{ErrorMessage}" Background="Red" Foreground="White" Width="Stretched" Margin="2" Multiline="true"/> - </VerticalStack> + </VerticalStack>--> </HorizontalStack> +</Border> |