A Drawing WebApp
Chromium-based browsers only. FreeHands was developed and tested exclusively on Chromium-based browsers (Chrome, Edge, Brave). Firefox may exhibit visual inconsistencies in Canvas rendering,
globalCompositeOperationcompositing, CSS filters, and custom scrollbars. A Chromium browser is strongly recommended.
PressureBrush) with real pointer pressure support, stabilized pencil (
ImageData via BFS traversal.
IText editor (
SelectionPanel for align/distribute operations, magnetic snap guides via AlignmentGuides rendered on Fabric's contextTop.
multiply, screen, overlay, etc.), visibility, lock, drag-to-reorder, duplicate, merge-down, and delete.
add, remove, modify, raster, layer). Periodic snapshots every 15 commands for fast rewind.
CutAreaManager for region-based selection and pixel extraction. Native Fabric clipboard for object-level copy/paste/duplicate (Ctrl+C/V/X/D).
EffectManager (shadow, noise, color overlay).
FreeHands uses a Manager-based architecture in Vanilla JS. Each subsystem is an encapsulated class that communicates via direct object references held by the central CanvasManager. No event bus, no framework reactivity.
The rendering pipeline overrides Fabric.js's internal _renderObjects to composite each layer onto an offscreen layerCanvas with its own globalAlpha and globalCompositeOperation before drawing to the main context. The brush engine combines the perfect-freehand library for stroke geometry with fabric.Path for vector storage, committing to the canvas and history only on mouseup.
See docs/ARCHITECTURE.md for the full technical breakdown.
git clone https://github.com/jm-works/FreeHands.git
cd FreeHands
# Open index.html in Chrome, Edge, or BraveNo npm install. No build step. Fabric.js is loaded via CDN.
| Document | Description |
|---|---|
docs/ARCHITECTURE.md |
System design, module graph, communication model |
docs/MODULES.md |
Per-module API and responsibilities |
docs/HISTORY_SYSTEM.md |
Command Pattern internals, op types, undo/redo flow |
docs/CANVAS_RENDER.md |
Layer compositing pipeline, offscreen rendering |
docs/CONTRIBUTING.md |
Contribution guidelines and code conventions |
| Documentação Técnica (PT-BR) | Documentação técnica completa em português |
Parts of the codebase underwent AI-assisted technical review for bug identification and targeted corrections. Architecture, design, and implementation are original authorial work.