A desktop drawing application built with C# and Windows Forms, inspired by the classic Microsoft Paint experience.
This project started as a hands-on challenge while learning C#, but it grew into a feature-rich WinForms app that covers drawing tools, shape rendering, text, image editing actions, selection workflows, and basic canvas manipulation. It was a practical way to learn event-driven programming, graphics rendering, and desktop UI development.
- Pencil / freehand drawing
- Eraser
- Airbrush
- Straight line tool
- Curve support
- Text tool
- Rectangle
- Ellipse / oval
- Triangle
- Right triangle
- Polygon
- Diamond
- Pentagon
- Hexagon
- Right / left / up / down arrows
- Four-point, five-point, and six-point stars
- Rounded rectangle callout
- Oval callout
- Cloud callout
- Heart
- Lightning
- Foreground and background color selection
- Custom color editing
- Adjustable pen/brush size
- Fill and outline behavior
- Color picker
- Fill bucket
- Open image
- Insert image onto canvas
- Save drawing
- Undo / redo
- Zoom in / zoom out
- Crop
- Flip horizontally / vertically
- Rotate left / right
- New canvas
- Rectangular selection
- Free-form selection
- Resize/move workflow for selected content
This was one of my early C# projects and an important milestone in my learning journey. I wanted to build something interactive that would help me understand how desktop applications respond to user input in real time.
The goal was not just to recreate a simple paint program, but to explore:
- Event-driven programming in WinForms
- Mouse-based drawing interactions
- Rendering graphics with
System.Drawing - Managing drawing state across tools
- Building a more complete desktop UI with multiple editing actions
- Language: C#
- Framework: .NET Framework 4.8
- UI: Windows Forms (WinForms)
- Graphics:
System.Drawing - Project Type: Desktop application
The project is organized as a classic WinForms desktop app with drawing-specific helper classes.
-
Form1.cs
Contains the main UI logic, event handling, tool state, mouse interaction flow, canvas actions, and command behavior. -
Draw.cs
Encapsulates shape rendering logic for lines, polygons, arrows, stars, and custom callout-style shapes. -
DoubleBufferedPanel.cs
Enables double buffering to reduce flicker while drawing and repainting the canvas. -
TinySquare.cs
Supports selection/resize handles for interactive editing.
The app uses Bitmap, Graphics, mouse events, and control repainting to provide a drawing surface that updates in real time as the user interacts with the canvas.
Working on this project helped me build confidence in:
- WinForms UI design
- Handling
MouseDown,MouseMove, andMouseUp - Drawing with
Graphics,Pen,Brush, andBitmap - Building reusable drawing logic
- Managing application state across multiple tools
- Supporting editing actions like crop, rotate, flip, and zoom
- Improving UI responsiveness with double buffering
- Windows
- Visual Studio
- .NET Framework 4.8 targeting pack

