Skip to content

Commit

Permalink
WPF Application update
Browse files Browse the repository at this point in the history
  • Loading branch information
KUTlime committed Jun 24, 2020
1 parent 25c5228 commit 23cbf04
Show file tree
Hide file tree
Showing 9 changed files with 535 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Ultimate Temperature Library.sln
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "UltimateTemperatureLibrary"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "UltimateTemperatureLibrary.UnitTests", "UltimateTemperatureLibrary.UnitTests\UltimateTemperatureLibrary.UnitTests.csproj", "{CA18515F-ED14-41F8-B23E-DD1F285AE5A4}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UltimateTemperatureLibrary.WPF", "UltimateTemperatureLibrary.WPF\UltimateTemperatureLibrary.WPF.csproj", "{F3BBA712-8CA8-474D-8ACD-243D990BBDCC}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -21,6 +23,10 @@ Global
{CA18515F-ED14-41F8-B23E-DD1F285AE5A4}.Debug|Any CPU.Build.0 = Debug|Any CPU
{CA18515F-ED14-41F8-B23E-DD1F285AE5A4}.Release|Any CPU.ActiveCfg = Release|Any CPU
{CA18515F-ED14-41F8-B23E-DD1F285AE5A4}.Release|Any CPU.Build.0 = Release|Any CPU
{F3BBA712-8CA8-474D-8ACD-243D990BBDCC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F3BBA712-8CA8-474D-8ACD-243D990BBDCC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F3BBA712-8CA8-474D-8ACD-243D990BBDCC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F3BBA712-8CA8-474D-8ACD-243D990BBDCC}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
9 changes: 9 additions & 0 deletions UltimateTemperatureLibrary.WPF/App.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<Application
x:Class="UltimateTemperatureLibrary.WPF.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:UltimateTemperatureLibrary.WPF"
StartupUri="MainWindow.xaml"
>
<Application.Resources />
</Application>
17 changes: 17 additions & 0 deletions UltimateTemperatureLibrary.WPF/App.xaml.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Threading.Tasks;
using System.Windows;

namespace UltimateTemperatureLibrary.WPF
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
{
}
}
10 changes: 10 additions & 0 deletions UltimateTemperatureLibrary.WPF/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
using System.Windows;

[assembly: ThemeInfo(
ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
//(used if a resource is not found in the page,
// or application resource dictionaries)
ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
//(used if a resource is not found in the page,
// app, or any theme specific resource dictionaries)
)]
250 changes: 250 additions & 0 deletions UltimateTemperatureLibrary.WPF/MainWindow.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,250 @@
<Window
x:Class="UltimateTemperatureLibrary.WPF.MainWindow"
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:local="clr-namespace:UltimateTemperatureLibrary.WPF"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
Title="Ultimate Temperature Converter"
Width="500"
Height="550"
MinWidth="500"
MinHeight="550"
MaxWidth="500"
MaxHeight="550"
mc:Ignorable="d"
>
<Grid Margin="0,0,0,0">
<Grid.RowDefinitions>
<RowDefinition Height="494*" />
<RowDefinition Height="5*" />
<RowDefinition Height="20*" />
</Grid.RowDefinitions>
<TextBlock
Margin="94,10,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="20"
FontWeight="Bold"
Text="Ultimate Temperature Converter"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,68,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
Text="Kelvin:"
TextWrapping="Wrap"
/>
<TextBox
Name="KelvinTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,66,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
Text="273.15 K"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,108,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
TextWrapping="Wrap"
><Run Text="Celsius" /><Run Text=":" /></TextBlock>
<TextBox
Name="CelsiusTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,106,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,148,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
Text="Fahrenheit:"
TextWrapping="Wrap"
/>
<TextBox
Name="FahrenheitTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,146,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,188,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
Text="Rankine:"
TextWrapping="Wrap"
/>
<TextBox
Name="RankineTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,186,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,227,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
Text="Delisle:"
TextWrapping="Wrap"
/>
<TextBox
Name="DelisleTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,225,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,267,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
Text="Newton:"
TextWrapping="Wrap"
/>
<TextBox
Name="NewtonTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,265,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,308,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
Text="Réaumur"
TextWrapping="Wrap"
/>
<TextBox
Name="RéaumurTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,306,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Height="21"
Margin="12,348,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
Text="Rømer"
TextWrapping="Wrap"
/>
<TextBox
Name="RømerTextBox"
Grid.Row="0"
Width="300"
Height="23"
Margin="117,346,0,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
FontSize="16"
FontWeight="Bold"
LostFocus="OnLostFocus"
MaxLines="1"
TextChanged="OnTextChanged"
TextWrapping="Wrap"
/>
<TextBlock
Grid.Row="0"
Grid.RowSpan="3"
Width="300"
Height="30"
Margin="10,0,0,10"
HorizontalAlignment="Left"
VerticalAlignment="Bottom"
FontSize="16"
>
<Hyperlink
NavigateUri="https://github.com/KUTlime/Ultimate-Temperature-Library/"
RequestNavigate="Hyperlink_RequestNavigate"
>
Powered by Ultimate Temperature Library
</Hyperlink>
</TextBlock>

</Grid>
</Window>
Loading

0 comments on commit 23cbf04

Please sign in to comment.