From fea3514defe67513ee23177662662a7086ce151f Mon Sep 17 00:00:00 2001
From: Bunny <1319900154@qq.com>
Date: Mon, 30 Dec 2024 11:00:03 +0800
Subject: [PATCH] =?UTF-8?q?StackPanel=E5=88=9B=E5=BB=BA?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
WPF基础-2-StackPanel/App.xaml | 9 ++++++
WPF基础-2-StackPanel/App.xaml.cs | 12 ++++++++
WPF基础-2-StackPanel/AssemblyInfo.cs | 10 +++++++
WPF基础-2-StackPanel/MainWindow.xaml | 28 +++++++++++++++++++
WPF基础-2-StackPanel/MainWindow.xaml.cs | 17 +++++++++++
.../WPF基础-2-StackPanel.csproj | 12 ++++++++
WPF基础.sln | 6 ++++
7 files changed, 94 insertions(+)
create mode 100644 WPF基础-2-StackPanel/App.xaml
create mode 100644 WPF基础-2-StackPanel/App.xaml.cs
create mode 100644 WPF基础-2-StackPanel/AssemblyInfo.cs
create mode 100644 WPF基础-2-StackPanel/MainWindow.xaml
create mode 100644 WPF基础-2-StackPanel/MainWindow.xaml.cs
create mode 100644 WPF基础-2-StackPanel/WPF基础-2-StackPanel.csproj
diff --git a/WPF基础-2-StackPanel/App.xaml b/WPF基础-2-StackPanel/App.xaml
new file mode 100644
index 0000000..eef94c1
--- /dev/null
+++ b/WPF基础-2-StackPanel/App.xaml
@@ -0,0 +1,9 @@
+
+
+
+
+
diff --git a/WPF基础-2-StackPanel/App.xaml.cs b/WPF基础-2-StackPanel/App.xaml.cs
new file mode 100644
index 0000000..b9b9593
--- /dev/null
+++ b/WPF基础-2-StackPanel/App.xaml.cs
@@ -0,0 +1,12 @@
+using System.Configuration;
+using System.Data;
+using System.Windows;
+
+namespace WPF基础_2_StackPanel;
+
+///
+/// Interaction logic for App.xaml
+///
+public partial class App : Application
+{
+}
\ No newline at end of file
diff --git a/WPF基础-2-StackPanel/AssemblyInfo.cs b/WPF基础-2-StackPanel/AssemblyInfo.cs
new file mode 100644
index 0000000..4a05c7d
--- /dev/null
+++ b/WPF基础-2-StackPanel/AssemblyInfo.cs
@@ -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)
+)]
\ No newline at end of file
diff --git a/WPF基础-2-StackPanel/MainWindow.xaml b/WPF基础-2-StackPanel/MainWindow.xaml
new file mode 100644
index 0000000..6f694cc
--- /dev/null
+++ b/WPF基础-2-StackPanel/MainWindow.xaml
@@ -0,0 +1,28 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/WPF基础-2-StackPanel/MainWindow.xaml.cs b/WPF基础-2-StackPanel/MainWindow.xaml.cs
new file mode 100644
index 0000000..e8aa8df
--- /dev/null
+++ b/WPF基础-2-StackPanel/MainWindow.xaml.cs
@@ -0,0 +1,17 @@
+using System.Windows;
+
+namespace WPF基础_2_StackPanel;
+
+///
+/// Interaction logic for MainWindow.xaml
+///
+public partial class MainWindow : Window
+{
+ public MainWindow()
+ {
+ InitializeComponent();
+
+ // 支持三种重载方式
+ CmdButton.Margin = new Thickness(10);
+ }
+}
\ No newline at end of file
diff --git a/WPF基础-2-StackPanel/WPF基础-2-StackPanel.csproj b/WPF基础-2-StackPanel/WPF基础-2-StackPanel.csproj
new file mode 100644
index 0000000..f1d578f
--- /dev/null
+++ b/WPF基础-2-StackPanel/WPF基础-2-StackPanel.csproj
@@ -0,0 +1,12 @@
+
+
+
+ WinExe
+ net8.0-windows
+ WPF基础_2_StackPanel
+ enable
+ enable
+ true
+
+
+
diff --git a/WPF基础.sln b/WPF基础.sln
index 5a447ae..c08a397 100644
--- a/WPF基础.sln
+++ b/WPF基础.sln
@@ -8,6 +8,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WPF基础-1-1-只使用代
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WPF基础-1-2-和xaml一起创建", "WPF基础-1-2-和xaml一起创建\WPF基础-1-2-和xaml一起创建.csproj", "{BEC5A610-FCE9-4A38-AE54-E1C516CED5E6}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WPF基础-2-StackPanel", "WPF基础-2-StackPanel\WPF基础-2-StackPanel.csproj", "{0BF66DA6-EDC2-41D2-8D92-ABF4383B8DFB}"
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -30,5 +32,9 @@ Global
{BEC5A610-FCE9-4A38-AE54-E1C516CED5E6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{BEC5A610-FCE9-4A38-AE54-E1C516CED5E6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{BEC5A610-FCE9-4A38-AE54-E1C516CED5E6}.Release|Any CPU.Build.0 = Release|Any CPU
+ {0BF66DA6-EDC2-41D2-8D92-ABF4383B8DFB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {0BF66DA6-EDC2-41D2-8D92-ABF4383B8DFB}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {0BF66DA6-EDC2-41D2-8D92-ABF4383B8DFB}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {0BF66DA6-EDC2-41D2-8D92-ABF4383B8DFB}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
EndGlobal