aboutsummaryrefslogtreecommitdiffstatsci
path: root/CrowIDE/ui/MembersItem.template
blob: cc653ef881c6ad5708a52f6e2d419a92dfc37be0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
<?xml version="1.0"?>
<ItemTemplate>
	<HorizontalStack Style="MemberViewHStack" ContextCommands="{Commands}">
		<Label Style="MemberViewLabel" Text="{Name}" Foreground = "{LabForeground}"/>
		<TextBox Margin="1" Text="{²Value}" Height="Fit" Foreground = "{LabForeground}"/>
	</HorizontalStack>
</ItemTemplate>
<ItemTemplate DataType="System.Boolean" >
	<HorizontalStack Style="MemberViewHStack" ContextCommands="{Commands}">
		<Label Style="MemberViewLabel" Text="{Name}" Foreground = "{LabForeground}"/>
		<CheckBox Background="White" Foreground = "{LabForeground}" Height="Stretched" Caption="" IsChecked="{²Value}"/>
	</HorizontalStack>
</ItemTemplate>
<ItemTemplate DataType="System.Enum">
	<HorizontalStack Style="MemberViewHStack" ContextCommands="{Commands}">
		<Label Style="MemberViewLabel" Text="{Name}" Foreground = "{LabForeground}"/>
		<ComboBox Margin="0"  Height="Stretched" Width="50%" Data="{Choices}"
				SelectedItem="{²Value}">
			<Template>
				<Popper Name="popper" PopDirection="Bottom">
					<Template>
						<CheckBox Caption="{./Caption}" IsChecked="{²./IsPopped}" Foreground="{./Foreground}" Background="{./Background}">
							<Template>
								<Border CornerRadius="0" Foreground="LightGray" Background="White">
									<HorizontalStack Margin="0" Spacing="1">
										<Label Width="Stretched" MinimumSize="80,10" Margin="1" Foreground = "{LabForeground}" Background="White"
											Text="{../../../../../SelectedItem}"/>
										<Button Width="12" Height="12" Focusable="false"
											Template="#Crow.Templates.ArrowBut.template">
											<Image Margin="1" Path="#Crow.Images.Icons.updown.svg" SvgSub="down"/>
										</Button>
									</HorizontalStack>
								</Border>
							</Template>
						</CheckBox>
					</Template>
					<Border Background="White" BorderWidth="1" Margin="1" Foreground="Black"
						MinimumSize="{../../MinimumPopupSize}" Fit="true">
						<Scroller Name="scroller1" Margin="2" VerticalScrolling="true"
							MaximumSize="0,200"
							HorizontalAlignment="Left"
							ValueChanged="../../../_scroller_ValueChanged">
							<VerticalStack LayoutChanged="../../../../_list_LayoutChanged"
								MouseClick="../../../onMouseClick" Focusable="True"
								Height="Fit" Name="ItemsContainer" Margin="0"
								HorizontalAlignment="Left"
								VerticalAlignment="Top"/>
						</Scroller>
					</Border>
				</Popper>
			</Template>
			<ItemTemplate>
				<Container Fit="true" Margin="0" Focusable="true"
						HorizontalAlignment="Left"
						MouseEnter="{Background=SteelBlue}"
						MouseLeave="{Background=Transparent}">
					<Label Text="{}" Foreground="Black"/>
				</Container>
			</ItemTemplate>
		</ComboBox>
	</HorizontalStack>
</ItemTemplate>
<ItemTemplate DataType="Crow.Fill">
	<HorizontalStack Style="MemberViewHStack" ContextCommands="{Commands}">
		<Label Style="MemberViewLabel" Text="{Name}" Foreground = "{LabForeground}"/>
		<Popper Height="Stretched" Caption="{Value}">
			<Template>
				<CheckBox Caption="{./Caption}" IsChecked="{²./IsPopped}">
					<Template>
						<HorizontalStack Margin="1" Height="Stretched" Spacing="3" Background="White">
							<Border Foreground="{LabForeground}" Width="18" Height="12" CornerRadius="3"
								Background="{Value}">
							</Border>
							<Label Width="Stretched" Text="{./Caption}" Foreground="{LabForeground}"/>
						</HorizontalStack>
					</Template>
				</CheckBox>
			</Template>
			<ColorPicker SelectedColor="{²Value}" Background="Onyx" Margin="5" Fit="True" />
		</Popper>
	</HorizontalStack>
</ItemTemplate>