BusynessNotification

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 96b2f9d5b05ee5fa03425e6db578894aa91411b0
parent b065b9f0387da9be8b0f5d3175cbe9816368a47c
Author: Minerva_juppiter <ryouturn@gmail.com>
Date:   Thu, 14 Mar 2024 23:30:28 +0900

基礎UIの構築および、テーマの自動適応

Diffstat:
MApp.xaml | 10+++++++++-
MBusynessNotification.csproj | 4++++
MMainWindow.xaml | 21++++++++++++++++++++-
MREADME.md | 15+++++++++++++--
4 files changed, 46 insertions(+), 4 deletions(-)

diff --git a/App.xaml b/App.xaml @@ -1,9 +1,17 @@ <Application x:Class="BusynessNotification.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:ui="http://schemas.modernwpf.com/2019" xmlns:local="clr-namespace:BusynessNotification" StartupUri="MainWindow.xaml"> <Application.Resources> - + <ResourceDictionary> + <ResourceDictionary.MergedDictionaries> + <ui:ThemeResources /> + <ui:XamlControlsResources /> + <!-- Other merged dictionaries here --> + </ResourceDictionary.MergedDictionaries> + <!-- Other app resources here --> + </ResourceDictionary> </Application.Resources> </Application> diff --git a/BusynessNotification.csproj b/BusynessNotification.csproj @@ -9,6 +9,10 @@ </PropertyGroup> <ItemGroup> + <PackageReference Include="ModernWpfUI" Version="0.9.6" /> + </ItemGroup> + + <ItemGroup> <Compile Update="Settings1.Designer.cs"> <DesignTimeSharedInput>True</DesignTimeSharedInput> <AutoGen>True</AutoGen> diff --git a/MainWindow.xaml b/MainWindow.xaml @@ -3,10 +3,29 @@ 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:ui="http://schemas.modernwpf.com/2019" + ui:WindowHelper.UseModernWindowStyle="True" xmlns:local="clr-namespace:BusynessNotification" mc:Ignorable="d" Title="MainWindow" Height="450" Width="800"> <Grid> - + <Grid.RowDefinitions> + <RowDefinition/> + <RowDefinition/> + <RowDefinition/> + <RowDefinition/> + </Grid.RowDefinitions> + <Grid.ColumnDefinitions> + <ColumnDefinition/> + <ColumnDefinition/> + <ColumnDefinition/> + </Grid.ColumnDefinitions> + <CheckBox x:Name="CPUcheck" Content="CPU" HorizontalAlignment="Center" VerticalAlignment="Center" d:LayoutOverrides="LeftPosition, RightPosition"/> + <CheckBox Content="Memory" HorizontalAlignment="Center" Grid.Row="1" VerticalAlignment="Center"/> + <CheckBox Content="Disk" HorizontalAlignment="Center" Grid.Row="2" VerticalAlignment="Center" d:LayoutOverrides="LeftPosition, RightPosition"/> + <Button x:Name="SaveSettingButton" Content="Save" Margin="83,0,84,0" Grid.Row="3" VerticalAlignment="Center"/> + <Slider x:Name="CPUSlider" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center" Width="150"/> + <Slider x:Name="MemorySlider" Grid.Column="1" HorizontalAlignment="Center" Width="150" Margin="0,38,0,38" Grid.Row="1" d:LayoutOverrides="Height"/> + <Slider x:Name="DiskSlider" Grid.Column="1" HorizontalAlignment="Center" Width="150" Margin="0,38,0,39" Grid.Row="2" d:LayoutOverrides="Height"/> </Grid> </Window> diff --git a/README.md b/README.md @@ -1,4 +1,15 @@ # BusynessNotification ͋NɒxPCɑ΂āAKȓԂɂȂƂʒmAvP[VłB HDDVXehCuɂPCX^[gAbvAvPCɑ΂čłʓIɓ܂B -܂ÃAv풓邱ƂŁA삪dȂۂɂǂ̃\[XJׂʒmĂ@\lj\łB- \ No newline at end of file +܂ÃAv풓邱ƂŁA삪dȂۂɂǂ̃\[XJׂʒmĂ@\lj\łB + +_[Ne[}Ql:https://zenn.dev/apterygiformes/books/470ba1042dfbef/viewer/b798d6 +to ModernWpfUI + +SystemCPUuseage +SystemMemoryUseage +from Windows.System.Diagnostics + +and Disk activeTime + +e[}̓[U[windows̃e[}IɓK܂B+ \ No newline at end of file