├── .editorconfig
├── .gitattributes
├── .github
├── FUNDING.yml
├── stale.yml
└── workflows
│ └── build.yml
├── .gitignore
├── Core2D.sln
├── Directory.Build.props
├── Directory.Packages.props
├── LICENSE.TXT
├── NuGet.Config
├── README.md
├── global.json
└── src
├── Core2D.Generators
├── AutoNotifyGenerator.cs
└── Core2D.Generators.csproj
└── Core2D
├── App.axaml
├── App.axaml.cs
├── AppModule.cs
├── AppState.cs
├── Assets
├── Core2D.ico
└── Fonts
│ └── RobotoMono-Regular.ttf
├── Behaviors
├── AttachEditor.cs
├── AttachEditorBehavior.cs
├── CancelContextMenuBehavior.cs
└── DragAndDrop
│ ├── DefaultDropHandler.cs
│ ├── EditorDropHandler.cs
│ ├── GroupsListBoxDropHandler.cs
│ ├── ListBoxDropHandler.cs
│ ├── PageDropHandler.cs
│ ├── ScriptsListBoxDropHandler.cs
│ ├── StylesListBoxDropHandler.cs
│ ├── TemplatesListBoxDropHandler.cs
│ └── TreeViewDropHandler.cs
├── Configuration
└── Windows
│ ├── WindowConfiguration.cs
│ └── WindowConfigurationFactory.cs
├── Controls
├── Dialog
│ ├── DialogPresenterView.axaml
│ ├── DialogPresenterView.axaml.cs
│ ├── DialogView.axaml
│ └── DialogView.axaml.cs
├── EditableItem.axaml
├── EditableItem.axaml.cs
├── Editor
│ ├── MenuView.axaml
│ ├── MenuView.axaml.cs
│ ├── PageView.axaml
│ ├── PageView.axaml.cs
│ ├── ToolsView.axaml
│ └── ToolsView.axaml.cs
├── ToggleItem.axaml
└── ToggleItem.axaml.cs
├── Converters
├── ArgbColorToBrushConverter.cs
├── BaseShapeIconConverter.cs
├── ContainerToTypeStringConverter.cs
├── EditorToTitleMultiConverter.cs
├── FontStyleFlagsConverter.cs
├── HexToColorConverter.cs
├── IsCurrentToolConverter.cs
├── IsGroupConverter.cs
├── ObjectEqualityMultiConverter.cs
├── SelectedShapesFirstItemStyleValueConverter.cs
├── SelectedShapesFirstItemValueConverter.cs
├── SelectedShapesHasItemsValueConverter.cs
├── SelectedShapesIsEmptyValueConverter.cs
├── ShapeStateFlagsConverter.cs
├── ShapeToTypeStringConverter.cs
├── ToolIconConverter.cs
├── UInt32ToColorConverter.cs
└── ViewModelToTypeStringConverter.cs
├── Core2D.csproj
├── Editor
├── AvaloniaEditorCanvasPlatform.cs
├── AvaloniaImageImporter.cs
├── AvaloniaInputSource.cs
├── AvaloniaProjectEditorPlatform.cs
└── AvaloniaTextClipboard.cs
├── Json
└── ListContractResolver.cs
├── Model
├── Editor
│ ├── IBounds.cs
│ ├── IDialogPresenter.cs
│ ├── IEditorCanvasPlatform.cs
│ ├── IEditorTool.cs
│ ├── IHitTest.cs
│ ├── IPathTool.cs
│ ├── IProjectEditorPlatform.cs
│ ├── IShapeEditor.cs
│ ├── ITool.cs
│ └── MoveMode.cs
├── History
│ └── IHistory.cs
├── IConnectable.cs
├── IContainerFactory.cs
├── IDataObject.cs
├── IDrawable.cs
├── IFileSystem.cs
├── IFileWriter.cs
├── IImageImporter.cs
├── IJsonSerializer.cs
├── ILog.cs
├── IMetafileExporter.cs
├── IPathConverter.cs
├── IPickerItem.cs
├── IProjectExporter.cs
├── IScriptRunner.cs
├── ISelectable.cs
├── ISelection.cs
├── IShapeFactory.cs
├── IStringExporter.cs
├── ISvgConverter.cs
├── ISvgExporter.cs
├── ITextClipboard.cs
├── ITextFieldReader.cs
├── ITextFieldWriter.cs
├── IViewModelFactory.cs
├── IXamlExporter.cs
├── Input
│ ├── InputArgs.cs
│ ├── InputArgsObserver.cs
│ ├── InputProcessor.cs
│ ├── InputSource.cs
│ ├── InputTarget.cs
│ └── ModifierFlags.cs
├── Path
│ ├── FillRule.cs
│ └── SweepDirection.cs
├── Renderer
│ ├── ICache.cs
│ ├── IContainerPresenter.cs
│ ├── IDecorator.cs
│ ├── IGrid.cs
│ ├── IImageCache.cs
│ ├── IImageKey.cs
│ ├── IShapeRenderer.cs
│ ├── Nodes
│ │ ├── IArcDrawNode.cs
│ │ ├── ICubicBezierDrawNode.cs
│ │ ├── IDrawNode.cs
│ │ ├── IDrawNodeFactory.cs
│ │ ├── IEllipseDrawNode.cs
│ │ ├── IFillDrawNode.cs
│ │ ├── IGridDrawNode.cs
│ │ ├── IImageDrawNode.cs
│ │ ├── ILineDrawNode.cs
│ │ ├── IMarker.cs
│ │ ├── IPathDrawNode.cs
│ │ ├── IPointDrawNode.cs
│ │ ├── IQuadraticBezierDrawNode.cs
│ │ ├── IRectangleDrawNode.cs
│ │ └── ITextDrawNode.cs
│ ├── PathOp.cs
│ └── ShapeStateFlags.cs
└── Style
│ ├── ArrowType.cs
│ ├── Colors.cs
│ ├── FontStyleFlags.cs
│ ├── LineCap.cs
│ ├── TextHAlignment.cs
│ └── TextVAlignment.cs
├── Modules
├── FileSystem
│ └── DotNet
│ │ └── DotNetFileSystem.cs
├── FileWriter
│ ├── Dxf
│ │ └── DxfWriter.cs
│ ├── Emf
│ │ └── EmfWriter.cs
│ ├── PdfSharp
│ │ └── PdfSharpWriter.cs
│ ├── SkiaSharp
│ │ ├── JpegSkiaSharpExporter.cs
│ │ ├── JpegSkiaSharpWriter.cs
│ │ ├── PdfSkiaSharpExporter.cs
│ │ ├── PdfSkiaSharpWriter.cs
│ │ ├── PngSkiaSharpExporter.cs
│ │ ├── PngSkiaSharpWriter.cs
│ │ ├── SkpSkiaSharpExporter.cs
│ │ ├── SkpSkiaSharpWriter.cs
│ │ ├── SvgSkiaSharpExporter.cs
│ │ ├── SvgSkiaSharpWriter.cs
│ │ ├── WebpSkiaSharpExporter.cs
│ │ └── WebpSkiaSharpWriter.cs
│ ├── Svg
│ │ └── SvgSvgWriter.cs
│ └── Xaml
│ │ └── DrawingGroupXamlWriter.cs
├── Log
│ └── Trace
│ │ └── TraceLog.cs
├── Renderer
│ ├── Avalonia
│ │ ├── AvaloniaDrawNodeFactory.cs
│ │ ├── AvaloniaDrawUtil.cs
│ │ ├── AvaloniaRendererViewModel.cs
│ │ ├── Nodes
│ │ │ ├── ArcDrawNode.cs
│ │ │ ├── CubicBezierDrawNode.cs
│ │ │ ├── DrawNode.cs
│ │ │ ├── EllipseDrawNode.cs
│ │ │ ├── FillDrawNode.cs
│ │ │ ├── GridDrawNode.cs
│ │ │ ├── ImageDrawNode.cs
│ │ │ ├── LineDrawNode.cs
│ │ │ ├── Markers
│ │ │ │ ├── ArrowMarker.cs
│ │ │ │ ├── EllipseMarker.cs
│ │ │ │ ├── MarkerBase.cs
│ │ │ │ ├── NoneMarker.cs
│ │ │ │ └── RectangleMarker.cs
│ │ │ ├── PathDrawNode.cs
│ │ │ ├── PointDrawNode.cs
│ │ │ ├── QuadraticBezierDrawNode.cs
│ │ │ ├── RectangleDrawNode.cs
│ │ │ └── TextDrawNode.cs
│ │ └── PathGeometryConverter.cs
│ ├── Dxf
│ │ ├── DxfRenderer.IProjectExporter.cs
│ │ └── DxfRenderer.cs
│ ├── PdfSharp
│ │ ├── PathGeometryConverter.cs
│ │ ├── PdfSharpRenderer.IProjectExporter.cs
│ │ └── PdfSharpRenderer.cs
│ ├── SkiaSharp
│ │ ├── MatrixHelper.cs
│ │ ├── Nodes
│ │ │ ├── ArcDrawNode.cs
│ │ │ ├── CubicBezierDrawNode.cs
│ │ │ ├── DrawNode.cs
│ │ │ ├── EllipseDrawNode.cs
│ │ │ ├── FillDrawNode.cs
│ │ │ ├── GridDrawNode.cs
│ │ │ ├── ImageDrawNode.cs
│ │ │ ├── LineDrawNode.cs
│ │ │ ├── Markers
│ │ │ │ ├── ArrowMarker.cs
│ │ │ │ ├── EllipseMarker.cs
│ │ │ │ ├── MarkerBase.cs
│ │ │ │ ├── NoneMarker.cs
│ │ │ │ └── RectangleMarker.cs
│ │ │ ├── PathDrawNode.cs
│ │ │ ├── PointDrawNode.cs
│ │ │ ├── QuadraticBezierDrawNode.cs
│ │ │ ├── RectangleDrawNode.cs
│ │ │ └── TextDrawNode.cs
│ │ ├── PathGeometryConverter.cs
│ │ ├── SkiaSharpDrawNodeFactory.cs
│ │ ├── SkiaSharpDrawUtil.cs
│ │ ├── SkiaSharpPathConverter.cs
│ │ ├── SkiaSharpRendererViewModel.cs
│ │ └── SkiaSharpSvgConverter.cs
│ └── WinForms
│ │ ├── PathGeometryConverter.cs
│ │ └── WinFormsRenderer.cs
├── ScriptRunner
│ └── Roslyn
│ │ └── RoslynScriptRunner.cs
├── Serializer
│ └── Newtonsoft
│ │ ├── NewtonsoftJsonSerializer.cs
│ │ └── ProjectContractResolver.cs
├── ServiceProvider
│ └── Autofac
│ │ └── AutofacServiceProvider.cs
├── SvgExporter
│ └── Svg
│ │ └── SvgSvgExporter.cs
├── TextFieldReader
│ ├── CsvHelper
│ │ └── CsvHelperReader.cs
│ └── OpenXml
│ │ └── OpenXmlReader.cs
├── TextFieldWriter
│ ├── CsvHelper
│ │ └── CsvHelperWriter.cs
│ └── OpenXml
│ │ └── OpenXmlWriter.cs
└── XamlExporter
│ └── Avalonia
│ └── DrawingGroupXamlExporter.cs
├── Program.cs
├── Services
└── StorageService.cs
├── Settings.cs
├── Spatial
├── Arc
│ ├── GdiArc.cs
│ └── WpfArc.cs
├── ConvexHull
│ └── MonotoneChain.cs
├── DouglasPeucker
│ └── RDP.cs
├── Line2.cs
├── Matrix2.cs
├── MatrixD.cs
├── Point2.cs
├── PointD.cs
├── Polygon2.cs
├── Rect2.cs
├── Sat
│ ├── MinimumTranslationVector.cs
│ ├── Projection.cs
│ └── SeparatingAxisTheorem.cs
├── Size2.cs
└── Vector2.cs
├── Styles
├── Common.axaml
├── Dock.axaml
├── Geometry.axaml
└── Icons.axaml
├── Themes
└── Themes.axaml
├── Util
└── Utilities.cs
├── ViewLocator.cs
├── ViewModels
├── Containers
│ ├── BaseContainerViewModel.cs
│ ├── DocumentContainerViewModel.cs
│ ├── FrameContainerViewModel.cs
│ ├── LayerContainerViewModel.cs
│ ├── LibraryViewModel.cs
│ ├── OptionsViewModel.cs
│ ├── PageContainerViewModel.cs
│ ├── ProjectContainerViewModel.Commands.cs
│ ├── ProjectContainerViewModel.IImageCache.cs
│ ├── ProjectContainerViewModel.cs
│ ├── ProjectContainerViewModelExtensions.cs
│ └── TemplateContainerViewModel.cs
├── CopyExtensions.cs
├── Data
│ ├── Bindings
│ │ ├── BindingParser.cs
│ │ ├── BindingPart.cs
│ │ └── TextBinding.cs
│ ├── ColumnViewModel.cs
│ ├── DataFlow.cs
│ ├── DatabaseExtensions.cs
│ ├── DatabaseViewModel.cs
│ ├── PropertyViewModel.cs
│ ├── RecordViewModel.cs
│ └── ValueViewModel.cs
├── Designer
│ └── DesignerContext.cs
├── Docking
│ ├── DockFactory.cs
│ ├── Docks
│ │ └── PageDocumentDock.cs
│ ├── Documents
│ │ └── PageViewModel.cs
│ ├── Tools
│ │ ├── Libraries
│ │ │ ├── DatabaseLibraryViewModel.cs
│ │ │ ├── GroupLibraryViewModel.cs
│ │ │ ├── ScriptLibraryViewModel.cs
│ │ │ ├── StyleLibraryViewModel.cs
│ │ │ └── TemplateLibraryViewModel.cs
│ │ ├── ObjectBrowserViewModel.cs
│ │ ├── Options
│ │ │ ├── ImageOptionsViewModel.cs
│ │ │ ├── ProjectOptionsViewModel.cs
│ │ │ ├── RendererOptionsViewModel.cs
│ │ │ └── ZoomOptionsViewModel.cs
│ │ ├── ProjectExplorerViewModel.cs
│ │ └── Properties
│ │ │ ├── DataPropertiesViewModel.cs
│ │ │ ├── PagePropertiesViewModel.cs
│ │ │ ├── ShapePropertiesViewModel.cs
│ │ │ ├── StatePropertiesViewModel.cs
│ │ │ └── StylePropertiesViewModel.cs
│ └── Views
│ │ ├── DashboardMenuViewModel.cs
│ │ ├── DashboardViewModel.cs
│ │ ├── HomeMenuViewModel.cs
│ │ ├── HomeStatusBarViewModel.cs
│ │ └── HomeViewModel.cs
├── Editor
│ ├── AboutInfoViewModel.cs
│ ├── Bounds
│ │ ├── HitTest.cs
│ │ ├── HitTestHelper.cs
│ │ └── Shapes
│ │ │ ├── ArcBounds.cs
│ │ │ ├── CubicBezierBounds.cs
│ │ │ ├── EllipseBounds.cs
│ │ │ ├── GroupBounds.cs
│ │ │ ├── ImageBounds.cs
│ │ │ ├── LineBounds.cs
│ │ │ ├── PathBounds.cs
│ │ │ ├── PointBounds.cs
│ │ │ ├── QuadraticBezierBounds.cs
│ │ │ ├── RectangleBounds.cs
│ │ │ └── TextBounds.cs
│ ├── DialogViewModel.cs
│ ├── Factories
│ │ ├── ContainerFactory.cs
│ │ └── ShapeFactory.cs
│ ├── History
│ │ ├── StackHistory.cs
│ │ └── UndoRedo.cs
│ ├── IClipboardService.cs
│ ├── ISelectionService.cs
│ ├── IShapeService.cs
│ ├── ProjectEditorConfiguration.cs
│ ├── ProjectEditorInputTarget.cs
│ ├── ProjectEditorViewModel.Clipboard.cs
│ ├── ProjectEditorViewModel.Editor.cs
│ ├── ProjectEditorViewModel.Properties.cs
│ ├── ProjectEditorViewModel.Selection.cs
│ ├── ProjectEditorViewModel.Shape.cs
│ ├── ProjectEditorViewModel.Tool.cs
│ ├── ProjectEditorViewModel.cs
│ ├── ProjectExtensions.cs
│ ├── ShapeEditor.cs
│ ├── StyleEditorViewModel.cs
│ └── Tools
│ │ ├── ArcToolViewModel.cs
│ │ ├── CubicBezierToolViewModel.cs
│ │ ├── Decorators
│ │ └── BoxDecoratorViewModel.cs
│ │ ├── EllipseToolViewModel.cs
│ │ ├── ImageToolViewModel.cs
│ │ ├── LineToolViewModel.cs
│ │ ├── NoneToolViewModel.cs
│ │ ├── Path
│ │ ├── ArcPathToolViewModel.cs
│ │ ├── CubicBezierPathToolViewModel.cs
│ │ ├── LinePathToolViewModel.cs
│ │ ├── MovePathToolViewModel.cs
│ │ └── QuadraticBezierPathToolViewModel.cs
│ │ ├── PathToolViewModel.cs
│ │ ├── PointToolViewModel.cs
│ │ ├── QuadraticBezierToolViewModel.cs
│ │ ├── RectangleToolViewModel.cs
│ │ ├── Selection
│ │ ├── ArcSelection.cs
│ │ ├── BezierSelectionSelection.cs
│ │ ├── EllipseSelection.cs
│ │ ├── ImageSelection.cs
│ │ ├── LineSelection.cs
│ │ ├── PathSelection.cs
│ │ ├── PointSelection.cs
│ │ ├── QuadraticBezierSelection.cs
│ │ ├── RectangleSelection.cs
│ │ └── TextSelection.cs
│ │ ├── SelectionToolViewModel.cs
│ │ └── TextToolViewModel.cs
├── Editors
│ └── TextBindingEditorViewModel.cs
├── Layout
│ ├── AlignMode.cs
│ ├── Box.cs
│ ├── BoxLayout.cs
│ ├── DistributeMode.cs
│ ├── FlipMode.cs
│ ├── GroupBox.cs
│ ├── PointUtil.cs
│ ├── ShapeBox.cs
│ └── StackMode.cs
├── Path
│ ├── GeometryContext.cs
│ ├── PathFigureViewModel.cs
│ ├── PathSegmentViewModel.cs
│ ├── PathSizeViewModel.cs
│ └── Segments
│ │ ├── ArcSegmentViewModel.cs
│ │ ├── CubicBezierSegmentViewModel.cs
│ │ ├── LineSegmentViewModel.cs
│ │ └── QuadraticBezierSegmentViewModel.cs
├── Renderer
│ ├── Cache.cs
│ ├── ImageKeyViewModel.cs
│ ├── NodeRendererViewModel.cs
│ ├── Presenters
│ │ ├── EditorPresenter.cs
│ │ ├── ExportPresenter.cs
│ │ └── TemplatePresenter.cs
│ └── ShapeRendererStateViewModel.cs
├── Scripting
│ └── ScriptViewModel.cs
├── ServiceProviderExtensions.cs
├── Shapes
│ ├── ArcShapeViewModel.cs
│ ├── BaseShapeViewModel.cs
│ ├── BaseShapeViewModelExtensions.cs
│ ├── ConnectableShapeExtensions.cs
│ ├── ConnectableShapeViewModel.cs
│ ├── CubicBezierShapeViewModel.cs
│ ├── EllipseShapeViewModel.cs
│ ├── GroupShapeExtensions.cs
│ ├── GroupShapeViewModel.cs
│ ├── ImageShapeViewModel.cs
│ ├── LineShapeViewModel.cs
│ ├── PathShapeViewModel.cs
│ ├── PointShapeExtensions.cs
│ ├── PointShapeViewModel.cs
│ ├── QuadraticBezierShapeViewModel.cs
│ ├── RectangleShapeViewModel.cs
│ └── TextShapeViewModel.cs
├── Style
│ ├── ArgbColorViewModelViewModel.cs
│ ├── ArrowStyleViewModel.cs
│ ├── BaseColorViewModel.cs
│ ├── FillStyleViewModel.cs
│ ├── ShapeStyleViewModel.cs
│ ├── StrokeStyleViewModel.cs
│ ├── StyleHelper.cs
│ └── TextStyleViewModel.cs
├── ViewModelBase.cs
└── ViewModelFactory.cs
└── Views
├── Containers
├── DocumentContainerView.axaml
├── DocumentContainerView.axaml.cs
├── LayerContainerView.axaml
├── LayerContainerView.axaml.cs
├── OptionsView.axaml
├── OptionsView.axaml.cs
├── PageContainerView.axaml
├── PageContainerView.axaml.cs
├── ProjectContainerView.axaml
├── ProjectContainerView.axaml.cs
├── TemplateContainerView.axaml
└── TemplateContainerView.axaml.cs
├── Data
├── DataObjectView.axaml
├── DataObjectView.axaml.cs
├── DatabaseView.axaml
├── DatabaseView.axaml.cs
├── RecordView.axaml
└── RecordView.axaml.cs
├── Docking
├── Documents
│ ├── PageView.axaml
│ └── PageView.axaml.cs
├── Tools
│ ├── Libraries
│ │ ├── DatabaseLibraryView.axaml
│ │ ├── DatabaseLibraryView.axaml.cs
│ │ ├── GroupLibraryView.axaml
│ │ ├── GroupLibraryView.axaml.cs
│ │ ├── ScriptLibraryView.axaml
│ │ ├── ScriptLibraryView.axaml.cs
│ │ ├── StyleLibraryView.axaml
│ │ ├── StyleLibraryView.axaml.cs
│ │ ├── TemplateLibraryView.axaml
│ │ └── TemplateLibraryView.axaml.cs
│ ├── ObjectBrowserView.axaml
│ ├── ObjectBrowserView.axaml.cs
│ ├── Options
│ │ ├── ImageOptionsView.axaml
│ │ ├── ImageOptionsView.axaml.cs
│ │ ├── ProjectOptionsView.axaml
│ │ ├── ProjectOptionsView.axaml.cs
│ │ ├── RendererOptionsView.axaml
│ │ ├── RendererOptionsView.axaml.cs
│ │ ├── ZoomOptionsView.axaml
│ │ └── ZoomOptionsView.axaml.cs
│ ├── ProjectExplorerView.axaml
│ ├── ProjectExplorerView.axaml.cs
│ └── Properties
│ │ ├── DataPropertiesView.axaml
│ │ ├── DataPropertiesView.axaml.cs
│ │ ├── PagePropertiesView.axaml
│ │ ├── PagePropertiesView.axaml.cs
│ │ ├── ShapePropertiesView.axaml
│ │ ├── ShapePropertiesView.axaml.cs
│ │ ├── StatePropertiesView.axaml
│ │ ├── StatePropertiesView.axaml.cs
│ │ ├── StylePropertiesView.axaml
│ │ └── StylePropertiesView.axaml.cs
└── Views
│ ├── DashboardMenuView.axaml
│ ├── DashboardMenuView.axaml.cs
│ ├── DashboardView.axaml
│ ├── DashboardView.axaml.cs
│ ├── HomeMenuView.axaml
│ ├── HomeMenuView.axaml.cs
│ ├── HomeStatusBarView.axaml
│ ├── HomeStatusBarView.axaml.cs
│ ├── HomeView.axaml
│ └── HomeView.axaml.cs
├── Editor
├── AboutInfoView.axaml
└── AboutInfoView.axaml.cs
├── Editors
├── TextBindingEditorView.axaml
└── TextBindingEditorView.axaml.cs
├── Libraries
├── DatabasesView.axaml
├── DatabasesView.axaml.cs
├── GroupsView.axaml
├── GroupsView.axaml.cs
├── ImagesView.axaml
├── ImagesView.axaml.cs
├── ScriptsView.axaml
├── ScriptsView.axaml.cs
├── StylesView.axaml
├── StylesView.axaml.cs
├── TemplatesView.axaml
└── TemplatesView.axaml.cs
├── MainView.axaml
├── MainView.axaml.cs
├── MainWindow.axaml
├── MainWindow.axaml.cs
├── Path
├── PathFigureView.axaml
├── PathFigureView.axaml.cs
├── PathSizeView.axaml
├── PathSizeView.axaml.cs
└── Segments
│ ├── ArcSegmentView.axaml
│ ├── ArcSegmentView.axaml.cs
│ ├── CubicBezierSegmentView.axaml
│ ├── CubicBezierSegmentView.axaml.cs
│ ├── LineSegmentView.axaml
│ ├── LineSegmentView.axaml.cs
│ ├── QuadraticBezierSegmentView.axaml
│ └── QuadraticBezierSegmentView.axaml.cs
├── Renderer
├── GridView.axaml
├── GridView.axaml.cs
├── RenderDrawOperation.cs
├── RenderState.cs
├── RenderType.cs
├── RenderView.axaml
├── RenderView.axaml.cs
├── RendererOptions.cs
├── ShapeRendererStateView.axaml
├── ShapeRendererStateView.axaml.cs
├── ShapeStateView.axaml
└── ShapeStateView.axaml.cs
├── Scripting
├── ScriptView.axaml
└── ScriptView.axaml.cs
├── Shapes
├── ArcShapeView.axaml
├── ArcShapeView.axaml.cs
├── CubicBezierShapeView.axaml
├── CubicBezierShapeView.axaml.cs
├── EllipseShapeView.axaml
├── EllipseShapeView.axaml.cs
├── GroupShapeView.axaml
├── GroupShapeView.axaml.cs
├── ImageShapeView.axaml
├── ImageShapeView.axaml.cs
├── LineShapeView.axaml
├── LineShapeView.axaml.cs
├── PathShapeView.axaml
├── PathShapeView.axaml.cs
├── PointShapeView.axaml
├── PointShapeView.axaml.cs
├── QuadraticBezierShapeView.axaml
├── QuadraticBezierShapeView.axaml.cs
├── RectangleShapeView.axaml
├── RectangleShapeView.axaml.cs
├── TextShapeView.axaml
└── TextShapeView.axaml.cs
└── Style
├── ArgbColorView.axaml
├── ArgbColorView.axaml.cs
├── FillStyleView.axaml
├── FillStyleView.axaml.cs
├── ShapeStyleView.axaml
├── ShapeStyleView.axaml.cs
├── StrokeStyleView.axaml
├── StrokeStyleView.axaml.cs
├── TextStyleView.axaml
└── TextStyleView.axaml.cs
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Auto detect text files and perform LF normalization
2 | * text=auto
3 |
4 | # Custom for Visual Studio
5 | *.cs diff=csharp
6 |
7 | # Standard to msysgit
8 | *.doc diff=astextplain
9 | *.DOC diff=astextplain
10 | *.docx diff=astextplain
11 | *.DOCX diff=astextplain
12 | *.dot diff=astextplain
13 | *.DOT diff=astextplain
14 | *.pdf diff=astextplain
15 | *.PDF diff=astextplain
16 | *.rtf diff=astextplain
17 | *.RTF diff=astextplain
18 |
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | github: [wieslawsoltes]
2 |
--------------------------------------------------------------------------------
/.github/stale.yml:
--------------------------------------------------------------------------------
1 | # https://probot.github.io/apps/stale/
2 |
3 | # Number of days of inactivity before an issue becomes stale
4 | daysUntilStale: 60
5 |
6 | # Number of days of inactivity before a stale issue is closed
7 | daysUntilClose: 7
8 |
9 | # Issues with these labels will never be considered stale
10 | exemptLabels:
11 | - pinned
12 | - security
13 |
14 | # Label to use when marking an issue as stale
15 | staleLabel: stale
16 |
17 | # Comment to post when marking an issue as stale. Set to `false` to disable
18 | markComment: >
19 | This issue has been automatically marked as stale because it has not had
20 | recent activity. It will be closed if no further activity occurs. Thank you
21 | for your contributions.
22 |
23 | # Comment to post when closing a stale issue. Set to `false` to disable
24 | closeComment: true
25 |
--------------------------------------------------------------------------------
/.github/workflows/build.yml:
--------------------------------------------------------------------------------
1 | name: CI
2 |
3 | on:
4 | push:
5 | branches:
6 | - master
7 | - release/*
8 | pull_request:
9 | branches:
10 | - master
11 |
12 | jobs:
13 | build:
14 | strategy:
15 | matrix:
16 | os: [ubuntu-latest, windows-latest, macos-latest]
17 | name: Build ${{ matrix.os }}
18 | runs-on: ${{ matrix.os }}
19 | steps:
20 | - uses: actions/checkout@v1
21 | - name: Setup .NET Core
22 | uses: actions/setup-dotnet@v1
23 | - name: Build Release
24 | run: dotnet build -c Release
25 |
--------------------------------------------------------------------------------
/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 | true
4 | latest
5 |
6 |
7 | 11.1.0
8 |
9 | Wiesław Šoltés
10 | Wiesław Šoltés
11 | A multi-platform data driven 2D diagram editor.
12 | Copyright © Wiesław Šoltés 2024
13 |
14 |
15 |
--------------------------------------------------------------------------------
/LICENSE.TXT:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2021 Wiesław Šoltés
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/NuGet.Config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/global.json:
--------------------------------------------------------------------------------
1 | {
2 | "sdk": {
3 | "version": "9.0.100",
4 | "rollForward": "latestMinor",
5 | "allowPrerelease": true
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/src/Core2D.Generators/Core2D.Generators.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | netstandard2.0
5 | Library
6 | True
7 | latest
8 | enable
9 | latest
10 | False
11 | False
12 | True
13 | true
14 | True
15 |
16 |
17 |
18 | Core2D.Generators
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/src/Core2D/App.axaml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/src/Core2D/Assets/Core2D.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/wieslawsoltes/Core2D/6076ad962702e470001a6fdbe22f393aebc22f63/src/Core2D/Assets/Core2D.ico
--------------------------------------------------------------------------------
/src/Core2D/Assets/Fonts/RobotoMono-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/wieslawsoltes/Core2D/6076ad962702e470001a6fdbe22f393aebc22f63/src/Core2D/Assets/Fonts/RobotoMono-Regular.ttf
--------------------------------------------------------------------------------
/src/Core2D/Behaviors/AttachEditorBehavior.cs:
--------------------------------------------------------------------------------
1 | #nullable enable
2 | using Avalonia.Controls;
3 | using Avalonia.Xaml.Interactivity;
4 |
5 | namespace Core2D.Behaviors;
6 |
7 | public class AttachEditorBehavior : Behavior
8 | {
9 | private AttachEditor? _input;
10 |
11 | protected override void OnAttached()
12 | {
13 | base.OnAttached();
14 |
15 | if (AssociatedObject is { })
16 | {
17 | _input = new AttachEditor(AssociatedObject);
18 | }
19 | }
20 |
21 | protected override void OnDetaching()
22 | {
23 | base.OnDetaching();
24 |
25 | if (AssociatedObject is { })
26 | {
27 | _input?.Detach();
28 | }
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/src/Core2D/Behaviors/DragAndDrop/GroupsListBoxDropHandler.cs:
--------------------------------------------------------------------------------
1 | #nullable enable
2 | using Avalonia.Controls;
3 | using Avalonia.Input;
4 | using Core2D.ViewModels.Shapes;
5 |
6 | namespace Core2D.Behaviors.DragAndDrop;
7 |
8 | public class GroupsListBoxDropHandler : ListBoxDropHandler
9 | {
10 | public override bool Validate(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
11 | {
12 | if (e.Source is Control && sender is ListBox listBox)
13 | {
14 | return ValidateLibrary(listBox, e, sourceContext, targetContext, false);
15 | }
16 | return false;
17 | }
18 |
19 | public override bool Execute(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
20 | {
21 | if (e.Source is Control && sender is ListBox listBox)
22 | {
23 | return ValidateLibrary(listBox, e, sourceContext, targetContext, true);
24 | }
25 | return false;
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/src/Core2D/Behaviors/DragAndDrop/ScriptsListBoxDropHandler.cs:
--------------------------------------------------------------------------------
1 | #nullable enable
2 | using Avalonia.Controls;
3 | using Avalonia.Input;
4 |
5 | namespace Core2D.Behaviors.DragAndDrop;
6 |
7 | public class ScriptsListBoxDropHandler : ListBoxDropHandler
8 | {
9 | public override bool Validate(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
10 | {
11 | if (e.Source is Control && sender is ListBox listBox)
12 | {
13 | // TODO:
14 | }
15 | return false;
16 | }
17 |
18 | public override bool Execute(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
19 | {
20 | if (e.Source is Control && sender is ListBox listBox)
21 | {
22 | // TODO:
23 | }
24 | return false;
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/src/Core2D/Behaviors/DragAndDrop/StylesListBoxDropHandler.cs:
--------------------------------------------------------------------------------
1 | #nullable enable
2 | using Avalonia.Controls;
3 | using Avalonia.Input;
4 | using Core2D.ViewModels.Style;
5 |
6 | namespace Core2D.Behaviors.DragAndDrop;
7 |
8 | public class StylesListBoxDropHandler : ListBoxDropHandler
9 | {
10 | public override bool Validate(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
11 | {
12 | if (e.Source is Control && sender is ListBox listBox)
13 | {
14 | return ValidateLibrary(listBox, e, sourceContext, targetContext, false);
15 | }
16 | return false;
17 | }
18 |
19 | public override bool Execute(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
20 | {
21 | if (e.Source is Control && sender is ListBox listBox)
22 | {
23 | return ValidateLibrary(listBox, e, sourceContext, targetContext, true);
24 | }
25 | return false;
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/src/Core2D/Behaviors/DragAndDrop/TemplatesListBoxDropHandler.cs:
--------------------------------------------------------------------------------
1 | #nullable enable
2 | using Avalonia.Controls;
3 | using Avalonia.Input;
4 |
5 | namespace Core2D.Behaviors.DragAndDrop;
6 |
7 | public class TemplatesListBoxDropHandler : ListBoxDropHandler
8 | {
9 | public override bool Validate(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
10 | {
11 | if (e.Source is Control && sender is ListBox listBox)
12 | {
13 | // TODO:
14 | }
15 | return false;
16 | }
17 |
18 | public override bool Execute(object? sender, DragEventArgs e, object? sourceContext, object? targetContext, object? state)
19 | {
20 | if (e.Source is Control && sender is ListBox listBox)
21 | {
22 | // TODO:
23 | }
24 | return false;
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/src/Core2D/Configuration/Windows/WindowConfiguration.cs:
--------------------------------------------------------------------------------
1 | using Avalonia.Controls;
2 |
3 | namespace Core2D.Configuration.Windows;
4 |
5 | public class WindowConfiguration
6 | {
7 | public double X { get; set; } = double.NaN;
8 | public double Y { get; set; } = double.NaN;
9 | public double Width { get; set; } = double.NaN;
10 | public double Height { get; set; } = double.NaN;
11 | public WindowState WindowState { get; set; } = WindowState.Normal;
12 | }
--------------------------------------------------------------------------------
/src/Core2D/Configuration/Windows/WindowConfigurationFactory.cs:
--------------------------------------------------------------------------------
1 | using Avalonia;
2 | using Avalonia.Controls;
3 |
4 | namespace Core2D.Configuration.Windows;
5 |
6 | public static class WindowConfigurationFactory
7 | {
8 | public static WindowConfiguration Save(Window window)
9 | {
10 | return new()
11 | {
12 | Width = window.Width,
13 | Height = window.Height,
14 | X = window.Position.X,
15 | Y = window.Position.Y,
16 | WindowState = window.WindowState
17 | };
18 | }
19 |
20 | public static void Load(Window window, WindowConfiguration settings)
21 | {
22 | if (!double.IsNaN(settings.Width))
23 | {
24 | window.Width = settings.Width;
25 | }
26 |
27 | if (!double.IsNaN(settings.Height))
28 | {
29 | window.Height = settings.Height;
30 | }
31 |
32 | if (!double.IsNaN(settings.X) && !double.IsNaN(settings.Y))
33 | {
34 | window.Position = new PixelPoint((int)settings.X, (int)settings.Y);
35 | window.WindowStartupLocation = WindowStartupLocation.Manual;
36 | }
37 | else
38 | {
39 | window.WindowStartupLocation = WindowStartupLocation.CenterScreen;
40 | }
41 |
42 | window.WindowState = settings.WindowState;
43 | }
44 | }
--------------------------------------------------------------------------------
/src/Core2D/Controls/Dialog/DialogPresenterView.axaml:
--------------------------------------------------------------------------------
1 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/src/Core2D/Controls/Dialog/DialogPresenterView.axaml.cs:
--------------------------------------------------------------------------------
1 | using Avalonia.Controls;
2 |
3 | namespace Core2D.Controls.Dialog;
4 |
5 | public partial class DialogPresenterView : UserControl
6 | {
7 | public DialogPresenterView()
8 | {
9 | InitializeComponent();
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/src/Core2D/Controls/Dialog/DialogView.axaml.cs:
--------------------------------------------------------------------------------
1 | using Avalonia.Controls;
2 |
3 | namespace Core2D.Controls.Dialog;
4 |
5 | public partial class DialogView : UserControl
6 | {
7 | public DialogView()
8 | {
9 | InitializeComponent();
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/src/Core2D/Controls/Editor/MenuView.axaml.cs:
--------------------------------------------------------------------------------
1 | using Avalonia.Controls;
2 |
3 | namespace Core2D.Controls.Editor;
4 |
5 | public partial class MenuView : UserControl
6 | {
7 | public MenuView()
8 | {
9 | InitializeComponent();
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/src/Core2D/Controls/Editor/PageView.axaml.cs:
--------------------------------------------------------------------------------
1 | using Avalonia.Controls;
2 |
3 | namespace Core2D.Controls.Editor;
4 |
5 | public partial class PageView : UserControl
6 | {
7 | public PageView()
8 | {
9 | InitializeComponent();
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/src/Core2D/Controls/Editor/ToolsView.axaml.cs:
--------------------------------------------------------------------------------
1 | using Avalonia.Controls;
2 |
3 | namespace Core2D.Controls.Editor;
4 |
5 | public partial class ToolsView : UserControl
6 | {
7 | public ToolsView()
8 | {
9 | InitializeComponent();
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/src/Core2D/Controls/ToggleItem.axaml.cs:
--------------------------------------------------------------------------------
1 | #nullable enable
2 | using Avalonia;
3 | using Avalonia.Controls.Primitives;
4 |
5 | namespace Core2D.Controls;
6 |
7 | public class ToggleItem : TemplatedControl
8 | {
9 | public static readonly StyledProperty