Add Shape controls and vector geometry - #53
Merged
Conversation
Add Shape base and Ellipse, Circle, Line, Polygon, Polyline, and Path controls. Add a platform-neutral Geometry and PathGeometry model with line, quadratic, and cubic Bézier segments. Support Fill, Stroke, gradient brushes, caps, joins, transforms, clipping, geometry-aware hit testing, and mutable Geometry/Brush cache invalidation. Integrate Designer Toolbox and Property Grid support, structured Point/Path editors, .mfdesign serialization, code generation, reverse parsing, ControlGallery coverage, and extensive regression tests. Keep rendering shared between Windows and Android through the Skia pipeline.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a complete, platform-neutral Shape and vector-geometry subsystem to ModernFormsNext. The implementation follows the existing Skia rendering, Brush, layout, input, accessibility, and Designer pipelines without introducing platform types into shared projects.
Closes #11.
Implementation
Shapebase control andEllipse,Circle,Line,Polygon,Polyline, andPathcontrols.Geometrymodel with ellipse, rectangle, line, and path geometries.Designer integration
PointCollectionandPathGeometry.Rendering and hit testing
Serialization and code generation
.mfdesignpersistence for Shape controls, points, figures, segments, transforms, fill rules, and brush values.ModernFormsNext.Pathname would otherwise conflict withSystem.IO.Path.Testing
dotnet restore .\ModernFormsNext.slnxgit diff --checkpassed.Manual validation
Manually verified on Windows:
Pathrendering afterGeometry.Transform.PointCollectionandPathGeometrystructured editors.Known limitations
PathGeometryuses a structured Designer editor; this change does not add a graphical Bézier canvas editor.