aboutsummaryrefslogtreecommitdiffstatsci
path: root/Samples/common/ui/Interfaces/Widget/textBox.crow
blob: 2094de4b2b3642762cb797f837378506411c1cbd (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
<?xml version="1.0"?>
<HorizontalStack >
	<VerticalStack Background="Jet" Height="Stretched" Width="50%" Margin="10" >
		<TextBox Margin="0"  Text="Hello World this is a test string" Focusable="true" Font="serif,14"/>
		<TextBox Margin="15" Text="Hello World this is a test string" Focusable="true" Font="serif,14"
			   Background="Grey" Focused="{Background=White}" Unfocused="{Background=Grey}"/>				
		<TextBox Name="lab" TextAlignment="Center" Width="Fit" Height="50"  Text="Hello World this is a test string" Focusable="true" Font="serif,14"
			   Background="Grey" Focused="{Background=White}" Unfocused="{Background=Grey}"/>
		<TextBox TextAlignment="{TextAlignment}" Multiline="false" Width="300" Height="Fit"  Text="Hello World this is a test string" Focusable="true" Font="serif,14"
			   Background="Grey" Focused="{Background=White}" Unfocused="{Background=Grey}"/>
	</VerticalStack>
	<VerticalStack Background="Jet" Height="Stretched" Margin="10">
		<TextBox Multiline="true" TextAlignment="{TextAlignment}" Width="320" Height="Fit"
				 Text="{MultilineText}" Focusable="true" Font="consolas,12" 
				 Background="Grey" Focused="{Background=White}" Unfocused="{Background=Grey}"/>
		<VerticalStack Width="300" Height="100">
			<HorizontalStack>
				<TextBox Name="tb" Multiline="true" TextAlignment="{TextAlignment}" Width="Stretched" Height="Stretched"
						 ClipToClientRect="true"
						 Text="{MultilineText}" Focusable="true" Font="consolas,12" Margin="10"
						 Background="Grey" Focused="{Background=White}" Unfocused="{Background=Grey}"
						 />
				<ScrollBar Value="{²../tb.ScrollY}"
						LargeIncrement="{../tb.PageHeight}" SmallIncrement="1"
						CursorRatio="{../tb.ChildHeightRatio}" Maximum="{../tb.MaxScrollY}" />
			</HorizontalStack>
			<ScrollBar Style="HScrollBar" Value="{²../tb.ScrollX}"
					LargeIncrement="{../tb.PageWidth}" SmallIncrement="1"
					CursorRatio="{../tb.ChildWidthRatio}" Maximum="{../tb.MaxScrollX}" />
		</VerticalStack>
		<EnumSelector RadioButtonStyle="CheckBox2" Caption="Text Alignment" EnumValue="{²TextAlignment}" >
			<Template>
				<GroupBox Caption="{./Caption}" CornerRadius="{./CornerRadius}" Foreground="{./Foreground}" Background="{./Background}">
					<VerticalStack Name="Content" Width="100"/>
				</GroupBox>
			</Template>
		</EnumSelector>
	</VerticalStack>
</HorizontalStack>