aboutsummaryrefslogtreecommitdiffstatsci
path: root/Tests/Interfaces/TemplatedControl
diff options
context:
space:
mode:
authorjpbruyere <jp.bruyere@hotmail.com>2016-08-18 17:26:50 +0200
committerjpbruyere <jp.bruyere@hotmail.com>2016-09-01 12:44:38 +0200
commit5fc76c5f6234fcdcf208607c434a6d5d8bbf79da (patch)
tree393b14c6c193846d33e7e5842d34250333a4cfaa /Tests/Interfaces/TemplatedControl
parentd4bc4a1aba5df1d5a93474259c5d5a52f993d475 (diff)
tests reorganization
modifié : Crow.csproj modifié : Tests/BasicTests.cs renommé : Tests/Interfaces/Expandable/0.crow -> Tests/Interfaces/TemplatedContainer/0.crow renommé : Tests/Interfaces/Expandable/6.crow -> Tests/Interfaces/TemplatedContainer/6.crow renommé : Tests/Interfaces/Expandable/7.crow -> Tests/Interfaces/TemplatedContainer/7.crow renommé : Tests/Interfaces/Divers/testDirViewer2.crow -> Tests/Interfaces/TemplatedContainer/testDirViewer2.crow renommé : Tests/Interfaces/Divers/testGroupBox.crow -> Tests/Interfaces/TemplatedContainer/testGroupBox.crow renommé : Tests/Interfaces/Divers/testMsgBox.crow -> Tests/Interfaces/TemplatedContainer/testMsgBox.crow renommé : Tests/Interfaces/Divers/testPopper.crow -> Tests/Interfaces/TemplatedContainer/testPopper.crow renommé : Tests/Interfaces/Divers/testTabView.crow -> Tests/Interfaces/TemplatedContainer/testTabView.crow renommé : Tests/Interfaces/Divers/testTreeView.crow -> Tests/Interfaces/TemplatedContainer/testTreeView.crow renommé : Tests/Interfaces/Divers/testWindow.goml -> Tests/Interfaces/TemplatedContainer/testWindow.goml renommé : Tests/Interfaces/Divers/testWindow2.goml -> Tests/Interfaces/TemplatedContainer/testWindow2.goml renommé : Tests/Interfaces/Divers/testWindow3.goml -> Tests/Interfaces/TemplatedContainer/testWindow3.goml renommé : Tests/Interfaces/Divers/test_Listbox.crow -> Tests/Interfaces/TemplatedContainer/test_Listbox.crow renommé : Tests/Interfaces/Divers/testButton.crow -> Tests/Interfaces/TemplatedControl/testButton.crow renommé : Tests/Interfaces/Divers/testCheckbox.crow -> Tests/Interfaces/TemplatedControl/testCheckbox.crow renommé : Tests/Interfaces/Divers/testCombobox.crow -> Tests/Interfaces/TemplatedControl/testCombobox.crow renommé : Tests/Interfaces/Divers/testItemTemplateTag.crow -> Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow renommé : Tests/Interfaces/Divers/testRadioButton.crow -> Tests/Interfaces/TemplatedControl/testRadioButton.crow renommé : Tests/Interfaces/Divers/testScrollbar.goml -> Tests/Interfaces/TemplatedControl/testScrollbar.goml renommé : Tests/Interfaces/Divers/testSpinner.goml -> Tests/Interfaces/TemplatedControl/testSpinner.goml modifié : Tests/Tests.csproj modifié : src/GraphicObjects/Expandable.cs modifié : src/GraphicObjects/Group.cs TemplatedGroup class nouveau fichier : src/GraphicObjects/TemplatedGroup.cs nouveau fichier : Tests/Interfaces/TemplatedGroup/0.crow modifié : src/IMLReader.cs
Diffstat (limited to 'Tests/Interfaces/TemplatedControl')
-rwxr-xr-xTests/Interfaces/TemplatedControl/testButton.crow10
-rwxr-xr-xTests/Interfaces/TemplatedControl/testCheckbox.crow11
-rwxr-xr-xTests/Interfaces/TemplatedControl/testCombobox.crow4
-rwxr-xr-xTests/Interfaces/TemplatedControl/testItemTemplateTag.crow40
-rwxr-xr-xTests/Interfaces/TemplatedControl/testRadioButton.crow7
-rwxr-xr-xTests/Interfaces/TemplatedControl/testScrollbar.goml5
-rwxr-xr-xTests/Interfaces/TemplatedControl/testSpinner.goml11
7 files changed, 88 insertions, 0 deletions
diff --git a/Tests/Interfaces/TemplatedControl/testButton.crow b/Tests/Interfaces/TemplatedControl/testButton.crow
new file mode 100755
index 00000000..69367eaa
--- /dev/null
+++ b/Tests/Interfaces/TemplatedControl/testButton.crow
@@ -0,0 +1,10 @@
+<?xml version="1.0"?>
+<VerticalStack Fit="true" Background="vgradient|0:DimGray|1:Black">
+ <HorizontalStack Fit="True">
+ <Button Caption="but" MouseClick="onButClick"/>
+ <Button Caption="but" MouseClick="onButClick" Fit="true"/>
+ <Button Width="60" Height="40" MouseClick="onButClick"/>
+ <Button Caption="Long text button" MouseClick="onButClick"/>
+ <Button Font="droid, 20" Caption="Button"/>
+ </HorizontalStack>
+</VerticalStack> \ No newline at end of file
diff --git a/Tests/Interfaces/TemplatedControl/testCheckbox.crow b/Tests/Interfaces/TemplatedControl/testCheckbox.crow
new file mode 100755
index 00000000..5147a151
--- /dev/null
+++ b/Tests/Interfaces/TemplatedControl/testCheckbox.crow
@@ -0,0 +1,11 @@
+<?xml version="1.0"?>
+<VerticalStack Fit="true" Margin="100" Background="DimGray" >
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+ <CheckBox Background="Gray" MouseEnter="{Background=Red}" MouseLeave="{Background=Transparent}"/>
+</VerticalStack>
diff --git a/Tests/Interfaces/TemplatedControl/testCombobox.crow b/Tests/Interfaces/TemplatedControl/testCombobox.crow
new file mode 100755
index 00000000..2ef6d391
--- /dev/null
+++ b/Tests/Interfaces/TemplatedControl/testCombobox.crow
@@ -0,0 +1,4 @@
+<?xml version="1.0"?>
+<Container Background="Onyx" Width="300">
+ <ComboBox Data="{TestList}" ItemTemplate="#Tests.Interfaces.colorItem.crow"/>
+</Container> \ No newline at end of file
diff --git a/Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow b/Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow
new file mode 100755
index 00000000..5f860719
--- /dev/null
+++ b/Tests/Interfaces/TemplatedControl/testItemTemplateTag.crow
@@ -0,0 +1,40 @@
+<?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" Height="{../HeightPolicy}" Width="{../WidthPolicy}">
+ <HorizontalStack Margin="1" Height="{../../HeightPolicy}" Width="{../../WidthPolicy}" >
+ <Scroller Name="scroller1" Height="{../../../HeightPolicy}" Width="{../../../WidthPolicy}"
+ Margin="2" VerticalScrolling="true" ScrollY="{../scrollbar1.Value}"
+ ValueChanged="../../../_scroller_ValueChanged">
+ <VerticalStack Width="{../../../../WidthPolicy}" Height="Fit" MinimumSize="10,10"
+ Name="List" Margin="0"
+ VerticalAlignment="Top"
+ HorizontalAlignment="Left"
+ LayoutChanged="../../../../_list_LayoutChanged"/>
+ </Scroller>
+ <ScrollBar Name="scrollbar1" Value="{../scroller1.ScrollY}"
+ Maximum="{../scroller1.MaximumScroll}" Orientation="Vertical"
+ Width="14" Height="{../../../HeightPolicy}" />
+ </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="{Name}" Margin="0" Width="Stretched"/>
+ </HorizontalStack>
+ </ItemTemplate>
+ </ListBox>
+ <HorizontalStack Fit="true" HorizontalAlignment="Right">
+ <Button Caption="Load list" MouseClick="OnLoadList"/>
+ <Button Caption="Clear" MouseClick="OnClear"/>
+ </HorizontalStack>
+ </VerticalStack>
+</Border> \ No newline at end of file
diff --git a/Tests/Interfaces/TemplatedControl/testRadioButton.crow b/Tests/Interfaces/TemplatedControl/testRadioButton.crow
new file mode 100755
index 00000000..905cdeba
--- /dev/null
+++ b/Tests/Interfaces/TemplatedControl/testRadioButton.crow
@@ -0,0 +1,7 @@
+<?xml version="1.0"?>
+<VerticalStack Width="200" Height="Fit" Margin="20" Background="DimGray">
+ <RadioButton Caption="Radio1"/>
+ <RadioButton Caption="Radio2" IsChecked="true"/>
+ <RadioButton Caption="Radio3"/>
+ <RadioButton Caption="Radio4"/>
+</VerticalStack>
diff --git a/Tests/Interfaces/TemplatedControl/testScrollbar.goml b/Tests/Interfaces/TemplatedControl/testScrollbar.goml
new file mode 100755
index 00000000..c494e347
--- /dev/null
+++ b/Tests/Interfaces/TemplatedControl/testScrollbar.goml
@@ -0,0 +1,5 @@
+<?xml version="1.0"?>
+<Group Name="TopContainer" Width="400" Height="400"
+ Focusable="True" Background="Gray">
+ <ScrollBar Height="Stretched" Orientation="Vertical" Width="16" Maximum="100"/>
+</Group> \ No newline at end of file
diff --git a/Tests/Interfaces/TemplatedControl/testSpinner.goml b/Tests/Interfaces/TemplatedControl/testSpinner.goml
new file mode 100755
index 00000000..4efd587a
--- /dev/null
+++ b/Tests/Interfaces/TemplatedControl/testSpinner.goml
@@ -0,0 +1,11 @@
+<?xml version="1.0"?>
+<VerticalStack Name="TopContainer" Width="400" Height="Fit"
+ Margin="20" Background="DarkGray">
+
+ <HorizontalStack Fit="true" Margin="5" Background="SkyBlue">
+ <Spinner Value="{IntValue}" ValueChanged="onSpinnerValueChange"/>
+ <Spinner Value="5"/>
+ <Spinner Value="5"/>
+ <Button/>
+ </HorizontalStack>
+</VerticalStack> \ No newline at end of file