Added icon to project

This commit is contained in:
2025-12-29 14:00:00 -05:00
parent 114b55582c
commit 8713ab0f59
4 changed files with 19 additions and 0 deletions
+11
View File
@@ -33,6 +33,17 @@ namespace ImageFrame
this.Size = new Size(400, 600); // Initial size of the window
this.Text = "Image Frame";
// Use the executable's associated icon (set by the project) for the form and taskbar.
// After building the project the exe will have the app.ico icon and this will pick it up.
try
{
this.Icon = Icon.ExtractAssociatedIcon(Application.ExecutablePath);
}
catch
{
// ignore if icon extraction fails; form will use default icon
}
// Top panel with buttons
var topPanel = new FlowLayoutPanel();
topPanel.Dock = DockStyle.Top;