-
Notifications
You must be signed in to change notification settings - Fork 0
/
Calculator.xaml
69 lines (59 loc) · 3.84 KB
/
Calculator.xaml
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
<Window x:Class="Applications.Calculator"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:Applications"
mc:Ignorable="d"
Title="Calculator" Height="800" Width="450" WindowStyle="ThreeDBorderWindow" WindowStartupLocation="CenterScreen">
<Window.Background>
<ImageBrush Stretch="UniformToFill" ImageSource="/backiee-189646.jpg"/>
</Window.Background>
<Grid>
<Grid.Background>
<ImageBrush/>
</Grid.Background>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="30"/>
<RowDefinition />
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
</Grid.RowDefinitions>
<Rectangle Grid.Row="5" Grid.Column="0" ></Rectangle>
<Button Grid.Row="5" Grid.Column="1" x:Name="btn_Brackets" Content="()" FontSize="20" Click="btn_Brackets_Click"/>
<Button Grid.Row="5" Grid.Column="2" x:Name="btn_Clear" Content="C" FontSize="20" Click="btn_Clear_Click"/>
<Button Grid.Row="5" Grid.Column="3" x:Name="btn_Divide" Content="/" FontSize="20" Click="btn_Divide_Click"/>
<Button Grid.Row="6" Grid.Column="0" x:Name="btn_Num7" Content="7" FontSize="20" Click="btn_Num7_Click"/>
<Button Grid.Row="6" Grid.Column="1" x:Name="btn_Num8" Content="8" FontSize="20" Click="btn_Num8_Click"/>
<Button Grid.Row="6" Grid.Column="2" x:Name="btn_Num9" Content="9" FontSize="20" Click="btn_Num9_Click"/>
<Button Grid.Row="6" Grid.Column="3" x:Name="btn_Multiple" Content="*" FontSize="20" Click="btn_Multiple_Click"/>
<Button Grid.Row="7" Grid.Column="0" x:Name="btn_Num4" Content="4" FontSize="20" Click="btn_Num4_Click"/>
<Button Grid.Row="7" Grid.Column="1" x:Name="btn_Num5" Content="5" FontSize="20" Click="btn_Num5_Click"/>
<Button Grid.Row="7" Grid.Column="2" x:Name="btn_Num6" Content="6" FontSize="20" Click="btn_Num6_Click"/>
<Button Grid.Row="7" Grid.Column="3" x:Name="btn_Minus" Content="-" FontSize="20" Click="btn_Minus_Click"/>
<Button Grid.Row="8" Grid.Column="0" x:Name="btn_Num1" Content="1" FontSize="20" Click="btn_Num1_Click"/>
<Button Grid.Row="8" Grid.Column="1" x:Name="btn_Num2" Content="2" FontSize="20" Click="btn_Num2_Click"/>
<Button Grid.Row="8" Grid.Column="2" x:Name="btn_Num3" Content="3" FontSize="20" Click="btn_Num3_Click"/>
<Button Grid.Row="8" Grid.Column="3" x:Name="btn_Plus" Content="+" FontSize="20" Click="btn_Plus_Click"/>
<Rectangle Grid.Row="9" Grid.Column="0"></Rectangle>
<Button Grid.Row="9" Grid.Column="1" x:Name="btn_Num0" Content="0" FontSize="20" Click="btn_Num0_Click"/>
<Button Grid.Row="9" Grid.Column="2" x:Name="btn_Dot" Content="." FontSize="20" Click="btn_Dot_Click"/>
<Button Grid.Row="9" Grid.Column="3" x:Name="btn_Equal" Content="=" FontSize="20" Click="btn_Equal_Click"/>
<TextBox Grid.Row="2" Grid.ColumnSpan="3" x:Name="txt_Result" Background="#FFE8E8E8"></TextBox>
<TextBox Grid.Row="3" Grid.ColumnSpan="3" x:Name="txt_formula" Background="#FFE8E8E8"></TextBox>
<TextBox></TextBox>
<Button Grid.Column="0" VerticalAlignment="Center" Height="30" Content="Home Page" Click="Button_Click"/>
</Grid>
</Window>