diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.Designer.cs b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.Designer.cs new file mode 100644 index 00000000..b512d4e8 --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.Designer.cs @@ -0,0 +1,45 @@ +namespace UniversalEditor.Controls.Michelangelo +{ + partial class CanvasControl + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Component Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.SuspendLayout(); + // + // CanvasControl + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.White; + this.Name = "CanvasControl"; + this.ResumeLayout(false); + + } + + #endregion + } +} diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.cs b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.cs new file mode 100644 index 00000000..e87a685f --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.cs @@ -0,0 +1,43 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Drawing; +using System.Text; +using System.Windows.Forms; + +namespace UniversalEditor.Controls.Michelangelo +{ + public partial class CanvasControl : UserControl + { + public CanvasControl() + { + InitializeComponent(); + + BuildTransparentBackgroundBrush(); + } + + private TextureBrush mvarTransparentBackgroundBrush = null; + private void BuildTransparentBackgroundBrush() + { + Bitmap bitmap = new Bitmap(16, 16); + Graphics g = Graphics.FromImage(bitmap); + + SolidBrush light = new SolidBrush(Color.FromArgb(153, 153, 153)); + SolidBrush dark = new SolidBrush(Color.FromArgb(102, 102, 102)); + + g.FillRectangle(light, new Rectangle(0, 0, 8, 8)); + g.FillRectangle(dark, new Rectangle(8, 0, 8, 8)); + g.FillRectangle(dark, new Rectangle(0, 8, 8, 8)); + g.FillRectangle(light, new Rectangle(8, 8, 8, 8)); + + mvarTransparentBackgroundBrush = new TextureBrush(bitmap); + } + + protected override void OnPaint(PaintEventArgs e) + { + base.OnPaint(e); + + e.Graphics.FillRectangle(mvarTransparentBackgroundBrush, new Rectangle(0, 0, Width - 1, Height - 1)); + } + } +} diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.resx b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.resx new file mode 100644 index 00000000..7080a7d1 --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Controls/Michelangelo/CanvasControl.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.Designer.cs b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.Designer.cs new file mode 100644 index 00000000..cb4c0b48 --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.Designer.cs @@ -0,0 +1,270 @@ +namespace UniversalEditor.Editors.Michelangelo.Canvas +{ + partial class CanvasEditor + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Component Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.splitContainer1 = new System.Windows.Forms.SplitContainer(); + this.tabControl1 = new System.Windows.Forms.TabControl(); + this.tabToolbox = new System.Windows.Forms.TabPage(); + this.treeView2 = new System.Windows.Forms.TreeView(); + this.splitContainer2 = new System.Windows.Forms.SplitContainer(); + this.splitContainer3 = new System.Windows.Forms.SplitContainer(); + this.tabControl2 = new System.Windows.Forms.TabControl(); + this.tabProperties = new System.Windows.Forms.TabPage(); + this.tabControl3 = new System.Windows.Forms.TabControl(); + this.tabExplorer = new System.Windows.Forms.TabPage(); + this.treeView1 = new System.Windows.Forms.TreeView(); + this.tabControl4 = new System.Windows.Forms.TabControl(); + this.tabDocument = new System.Windows.Forms.TabPage(); + this.canvasControl1 = new UniversalEditor.Controls.Michelangelo.CanvasControl(); + this.splitContainer1.Panel1.SuspendLayout(); + this.splitContainer1.Panel2.SuspendLayout(); + this.splitContainer1.SuspendLayout(); + this.tabControl1.SuspendLayout(); + this.tabToolbox.SuspendLayout(); + this.splitContainer2.Panel1.SuspendLayout(); + this.splitContainer2.Panel2.SuspendLayout(); + this.splitContainer2.SuspendLayout(); + this.splitContainer3.Panel1.SuspendLayout(); + this.splitContainer3.Panel2.SuspendLayout(); + this.splitContainer3.SuspendLayout(); + this.tabControl2.SuspendLayout(); + this.tabControl3.SuspendLayout(); + this.tabExplorer.SuspendLayout(); + this.tabControl4.SuspendLayout(); + this.tabDocument.SuspendLayout(); + this.SuspendLayout(); + // + // splitContainer1 + // + this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill; + this.splitContainer1.FixedPanel = System.Windows.Forms.FixedPanel.Panel1; + this.splitContainer1.Location = new System.Drawing.Point(0, 0); + this.splitContainer1.Name = "splitContainer1"; + // + // splitContainer1.Panel1 + // + this.splitContainer1.Panel1.Controls.Add(this.tabControl1); + // + // splitContainer1.Panel2 + // + this.splitContainer1.Panel2.Controls.Add(this.splitContainer2); + this.splitContainer1.Size = new System.Drawing.Size(713, 509); + this.splitContainer1.SplitterDistance = 158; + this.splitContainer1.TabIndex = 0; + // + // tabControl1 + // + this.tabControl1.Controls.Add(this.tabToolbox); + this.tabControl1.Dock = System.Windows.Forms.DockStyle.Fill; + this.tabControl1.Location = new System.Drawing.Point(0, 0); + this.tabControl1.Name = "tabControl1"; + this.tabControl1.SelectedIndex = 0; + this.tabControl1.Size = new System.Drawing.Size(158, 509); + this.tabControl1.TabIndex = 0; + // + // tabToolbox + // + this.tabToolbox.Controls.Add(this.treeView2); + this.tabToolbox.Location = new System.Drawing.Point(4, 22); + this.tabToolbox.Name = "tabToolbox"; + this.tabToolbox.Padding = new System.Windows.Forms.Padding(3); + this.tabToolbox.Size = new System.Drawing.Size(150, 483); + this.tabToolbox.TabIndex = 0; + this.tabToolbox.Text = "Toolbox"; + this.tabToolbox.UseVisualStyleBackColor = true; + // + // treeView2 + // + this.treeView2.Dock = System.Windows.Forms.DockStyle.Fill; + this.treeView2.Location = new System.Drawing.Point(3, 3); + this.treeView2.Name = "treeView2"; + this.treeView2.Size = new System.Drawing.Size(144, 477); + this.treeView2.TabIndex = 1; + // + // splitContainer2 + // + this.splitContainer2.Dock = System.Windows.Forms.DockStyle.Fill; + this.splitContainer2.FixedPanel = System.Windows.Forms.FixedPanel.Panel2; + this.splitContainer2.Location = new System.Drawing.Point(0, 0); + this.splitContainer2.Name = "splitContainer2"; + // + // splitContainer2.Panel1 + // + this.splitContainer2.Panel1.Controls.Add(this.splitContainer3); + // + // splitContainer2.Panel2 + // + this.splitContainer2.Panel2.Controls.Add(this.tabControl3); + this.splitContainer2.Size = new System.Drawing.Size(551, 509); + this.splitContainer2.SplitterDistance = 341; + this.splitContainer2.TabIndex = 0; + // + // splitContainer3 + // + this.splitContainer3.Dock = System.Windows.Forms.DockStyle.Fill; + this.splitContainer3.FixedPanel = System.Windows.Forms.FixedPanel.Panel2; + this.splitContainer3.Location = new System.Drawing.Point(0, 0); + this.splitContainer3.Name = "splitContainer3"; + this.splitContainer3.Orientation = System.Windows.Forms.Orientation.Horizontal; + // + // splitContainer3.Panel1 + // + this.splitContainer3.Panel1.Controls.Add(this.tabControl4); + // + // splitContainer3.Panel2 + // + this.splitContainer3.Panel2.Controls.Add(this.tabControl2); + this.splitContainer3.Size = new System.Drawing.Size(341, 509); + this.splitContainer3.SplitterDistance = 356; + this.splitContainer3.TabIndex = 1; + // + // tabControl2 + // + this.tabControl2.Controls.Add(this.tabProperties); + this.tabControl2.Dock = System.Windows.Forms.DockStyle.Fill; + this.tabControl2.Location = new System.Drawing.Point(0, 0); + this.tabControl2.Name = "tabControl2"; + this.tabControl2.SelectedIndex = 0; + this.tabControl2.Size = new System.Drawing.Size(341, 149); + this.tabControl2.TabIndex = 1; + // + // tabProperties + // + this.tabProperties.Location = new System.Drawing.Point(4, 22); + this.tabProperties.Name = "tabProperties"; + this.tabProperties.Padding = new System.Windows.Forms.Padding(3); + this.tabProperties.Size = new System.Drawing.Size(333, 123); + this.tabProperties.TabIndex = 0; + this.tabProperties.Text = "Properties"; + this.tabProperties.UseVisualStyleBackColor = true; + // + // tabControl3 + // + this.tabControl3.Controls.Add(this.tabExplorer); + this.tabControl3.Dock = System.Windows.Forms.DockStyle.Fill; + this.tabControl3.Location = new System.Drawing.Point(0, 0); + this.tabControl3.Name = "tabControl3"; + this.tabControl3.SelectedIndex = 0; + this.tabControl3.Size = new System.Drawing.Size(206, 509); + this.tabControl3.TabIndex = 1; + // + // tabExplorer + // + this.tabExplorer.Controls.Add(this.treeView1); + this.tabExplorer.Location = new System.Drawing.Point(4, 22); + this.tabExplorer.Name = "tabExplorer"; + this.tabExplorer.Padding = new System.Windows.Forms.Padding(3); + this.tabExplorer.Size = new System.Drawing.Size(198, 483); + this.tabExplorer.TabIndex = 0; + this.tabExplorer.Text = "Explorer"; + this.tabExplorer.UseVisualStyleBackColor = true; + // + // treeView1 + // + this.treeView1.Dock = System.Windows.Forms.DockStyle.Fill; + this.treeView1.Location = new System.Drawing.Point(3, 3); + this.treeView1.Name = "treeView1"; + this.treeView1.Size = new System.Drawing.Size(192, 477); + this.treeView1.TabIndex = 0; + // + // tabControl4 + // + this.tabControl4.Controls.Add(this.tabDocument); + this.tabControl4.Dock = System.Windows.Forms.DockStyle.Fill; + this.tabControl4.Location = new System.Drawing.Point(0, 0); + this.tabControl4.Name = "tabControl4"; + this.tabControl4.SelectedIndex = 0; + this.tabControl4.Size = new System.Drawing.Size(341, 356); + this.tabControl4.TabIndex = 0; + // + // tabDocument + // + this.tabDocument.Controls.Add(this.canvasControl1); + this.tabDocument.Location = new System.Drawing.Point(4, 22); + this.tabDocument.Name = "tabDocument"; + this.tabDocument.Padding = new System.Windows.Forms.Padding(3); + this.tabDocument.Size = new System.Drawing.Size(333, 330); + this.tabDocument.TabIndex = 0; + this.tabDocument.Text = "Document"; + this.tabDocument.UseVisualStyleBackColor = true; + // + // canvasControl1 + // + this.canvasControl1.BackColor = System.Drawing.Color.White; + this.canvasControl1.Dock = System.Windows.Forms.DockStyle.Fill; + this.canvasControl1.Location = new System.Drawing.Point(3, 3); + this.canvasControl1.Name = "canvasControl1"; + this.canvasControl1.Size = new System.Drawing.Size(327, 324); + this.canvasControl1.TabIndex = 1; + // + // CanvasEditor + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.Controls.Add(this.splitContainer1); + this.Name = "CanvasEditor"; + this.Size = new System.Drawing.Size(713, 509); + this.splitContainer1.Panel1.ResumeLayout(false); + this.splitContainer1.Panel2.ResumeLayout(false); + this.splitContainer1.ResumeLayout(false); + this.tabControl1.ResumeLayout(false); + this.tabToolbox.ResumeLayout(false); + this.splitContainer2.Panel1.ResumeLayout(false); + this.splitContainer2.Panel2.ResumeLayout(false); + this.splitContainer2.ResumeLayout(false); + this.splitContainer3.Panel1.ResumeLayout(false); + this.splitContainer3.Panel2.ResumeLayout(false); + this.splitContainer3.ResumeLayout(false); + this.tabControl2.ResumeLayout(false); + this.tabControl3.ResumeLayout(false); + this.tabExplorer.ResumeLayout(false); + this.tabControl4.ResumeLayout(false); + this.tabDocument.ResumeLayout(false); + this.ResumeLayout(false); + + } + + #endregion + + private System.Windows.Forms.SplitContainer splitContainer1; + private System.Windows.Forms.TabControl tabControl1; + private System.Windows.Forms.TabPage tabToolbox; + private System.Windows.Forms.SplitContainer splitContainer2; + private System.Windows.Forms.SplitContainer splitContainer3; + private System.Windows.Forms.TabControl tabControl2; + private System.Windows.Forms.TabPage tabProperties; + private System.Windows.Forms.TabControl tabControl3; + private System.Windows.Forms.TabPage tabExplorer; + private System.Windows.Forms.TreeView treeView2; + private System.Windows.Forms.TreeView treeView1; + private System.Windows.Forms.TabControl tabControl4; + private System.Windows.Forms.TabPage tabDocument; + private Controls.Michelangelo.CanvasControl canvasControl1; + } +} diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.cs b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.cs new file mode 100644 index 00000000..4acdb0cc --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.cs @@ -0,0 +1,24 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Drawing; +using System.Text; +using System.Windows.Forms; +using UniversalEditor.UserInterface.WindowsForms; + +namespace UniversalEditor.Editors.Michelangelo.Canvas +{ + public partial class CanvasEditor : Editor + { + public CanvasEditor() + { + InitializeComponent(); + } + + protected override void OnObjectModelChanged(EventArgs e) + { + base.OnObjectModelChanged(e); + + } + } +} diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.resx b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.resx new file mode 100644 index 00000000..7080a7d1 --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Editors/Michelangelo/Canvas/CanvasEditor.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Properties/AssemblyInfo.cs b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..5ac3e26d --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("Universal Editor plugin for Michelangelo - Windows Forms user interface")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("Mike Becker's Software")] +[assembly: AssemblyProduct("Michelangelo")] +[assembly: AssemblyCopyright("Copyright ©2014 Mike Becker's Software")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("9d01b3d2-04ae-4693-8be4-895efd3f0cc3")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms.csproj b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms.csproj new file mode 100644 index 00000000..0a8ddcee --- /dev/null +++ b/CSharp/Engines/WindowsForms/Plugins/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms/UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms.csproj @@ -0,0 +1,104 @@ + + + + + Debug + AnyCPU + {E1A1FD87-BEA4-41B7-9472-B4E35A0630B5} + Library + Properties + UniversalEditor + UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms + v3.5 + 512 + + + + true + full + false + ..\..\..\..\Output\Debug\Plugins\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + ..\..\..\..\Output\Release\Plugins\ + TRACE + prompt + 4 + + + + + + + + + + UserControl + + + CanvasControl.cs + + + UserControl + + + CanvasEditor.cs + + + + + + CanvasControl.cs + + + CanvasEditor.cs + + + + + {617d9eb5-ca93-45d6-aa6b-5a012b7698ac} + AwesomeControls + + + {3f664673-7e22-4486-9ad0-fc81861d0b78} + UniversalEditor.Compression + + + {2d4737e6-6d95-408a-90db-8dff38147e85} + UniversalEditor.Core + + + {8622ebc4-8e20-476e-b284-33d472081f5c} + UniversalEditor.UserInterface + + + {30467e5c-05bc-4856-aadc-13906ef4cadd} + UniversalEditor.Essential + + + {76fd1306-9ca4-428f-993b-b7e4eeeacbf3} + UniversalEditor.Plugins.FileSystem + + + {d623ec26-1a04-4bfe-84ee-e738281499c0} + UniversalEditor.Plugins.Michelangelo + + + {bcbb72bd-0ecb-4ff2-8d91-e466361fb6f9} + UniversalEditor.UserInterface.WindowsForms + + + + + \ No newline at end of file diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/DataFormats/Michelangelo/Canvas/MichelangeloCanvasDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/DataFormats/Michelangelo/Canvas/MichelangeloCanvasDataFormat.cs new file mode 100644 index 00000000..78a9cbb0 --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/DataFormats/Michelangelo/Canvas/MichelangeloCanvasDataFormat.cs @@ -0,0 +1,54 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using UniversalEditor.DataFormats.FileSystem.ZIP; + +using UniversalEditor.ObjectModels.FileSystem; +using UniversalEditor.ObjectModels.Michelangelo.Canvas; + +namespace UniversalEditor.DataFormats.Michelangelo.Canvas +{ + public class MichelangeloCanvasDataFormat : ZIPDataFormat + { + private static DataFormatReference _dfr = null; + public override DataFormatReference MakeReference() + { + if (_dfr == null) + { + _dfr = new DataFormatReference(GetType()); + _dfr.Capabilities.Add(typeof(CanvasObjectModel), DataFormatCapabilities.All); + _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.Bootstrap); + _dfr.Filters.Add("Michelangelo canvas", new string[] { "*.mcv" }); + } + return _dfr; + } + + protected override void BeforeLoadInternal(Stack objectModels) + { + base.BeforeLoadInternal(objectModels); + objectModels.Push(new FileSystemObjectModel()); + } + protected override void AfterLoadInternal(Stack objectModels) + { + base.AfterLoadInternal(objectModels); + + FileSystemObjectModel fsom = (objectModels.Pop() as FileSystemObjectModel); + CanvasObjectModel canvas = (objectModels.Pop() as CanvasObjectModel); + + } + + protected override void BeforeSaveInternal(Stack objectModels) + { + base.BeforeSaveInternal(objectModels); + + CanvasObjectModel canvas = (objectModels.Pop() as CanvasObjectModel); + + FileSystemObjectModel fsom = new FileSystemObjectModel(); + + + objectModels.Push(fsom); + } + + } +} diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObject.cs b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObject.cs new file mode 100644 index 00000000..1eaf82e9 --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObject.cs @@ -0,0 +1,26 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace UniversalEditor.ObjectModels.Michelangelo.Canvas +{ + public class CanvasObject + { + public class CanvasObjectCollection + : System.Collections.ObjectModel.Collection + { + + } + + private Guid mvarID = Guid.Empty; + public Guid ID { get { return mvarID; } set { mvarID = value; } } + + private string mvarName = String.Empty; + public string Name { get { return mvarName; } set { mvarName = value; } } + + private CanvasObjectProperty.CanvasObjectPropertyCollection mvarProperties = new CanvasObjectProperty.CanvasObjectPropertyCollection(); + public CanvasObjectProperty.CanvasObjectPropertyCollection Properties { get { return mvarProperties; } } + + } +} diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectInstance.cs b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectInstance.cs new file mode 100644 index 00000000..5b23beb9 --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectInstance.cs @@ -0,0 +1,44 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace UniversalEditor.ObjectModels.Michelangelo.Canvas +{ + public class CanvasObjectInstance + { + public class CanvasObjectInstanceCollection + : System.Collections.ObjectModel.Collection + { + + } + + private Guid mvarID = Guid.Empty; + public Guid ID { get { return mvarID; } set { mvarID = value; } } + + private string mvarName = String.Empty; + public string Name { get { return mvarName; } set { mvarName = value; } } + + private CanvasObject mvarObject = null; + public CanvasObject Object { get { return mvarObject; } set { mvarObject = value; } } + + private CanvasObjectPropertyInstance.CanvasObjectPropertyInstanceCollection mvarProperties = new CanvasObjectPropertyInstance.CanvasObjectPropertyInstanceCollection(); + public CanvasObjectPropertyInstance.CanvasObjectPropertyInstanceCollection Properties { get { return mvarProperties; } } + + private double mvarX = 0.0; + public double X { get { return mvarX; } set { mvarX = value; } } + private double mvarY = 0.0; + public double Y { get { return mvarY; } set { mvarY = value; } } + private double mvarZ = 0.0; + public double Z { get { return mvarZ; } set { mvarZ = value; } } + + + private double mvarWidth = 0.0; + public double Width { get { return mvarWidth; } set { mvarWidth = value; } } + private double mvarHeight = 0.0; + public double Height { get { return mvarHeight; } set { mvarHeight = value; } } + private double mvarDepth = 0.0; + public double Depth { get { return mvarDepth; } set { mvarDepth = value; } } + + } +} diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectModel.cs b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectModel.cs new file mode 100644 index 00000000..a019f84b --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectModel.cs @@ -0,0 +1,37 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace UniversalEditor.ObjectModels.Michelangelo.Canvas +{ + public class CanvasObjectModel : ObjectModel + { + private static ObjectModelReference _omr = null; + public override ObjectModelReference MakeReference() + { + if (_omr == null) + { + _omr = base.MakeReference(); + _omr.Title = "Michelangelo canvas"; + _omr.Path = new string[] { "Michelangelo" }; + } + return _omr; + } + + private CanvasObject.CanvasObjectCollection mvarObjects = new CanvasObject.CanvasObjectCollection(); + public CanvasObject.CanvasObjectCollection Objects { get { return mvarObjects; } } + + private CanvasObjectInstance.CanvasObjectInstanceCollection mvarObjectInstances = new CanvasObjectInstance.CanvasObjectInstanceCollection(); + public CanvasObjectInstance.CanvasObjectInstanceCollection ObjectInstances { get { return mvarObjectInstances; } } + + public override void Clear() + { + + } + + public override void CopyTo(ObjectModel where) + { + } + } +} diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectProperty.cs b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectProperty.cs new file mode 100644 index 00000000..0b8ea764 --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectProperty.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace UniversalEditor.ObjectModels.Michelangelo.Canvas +{ + public class CanvasObjectProperty + { + public class CanvasObjectPropertyCollection + : System.Collections.ObjectModel.Collection + { + + } + + private Guid mvarID = Guid.Empty; + public Guid ID { get { return mvarID; } set { mvarID = value; } } + + private string mvarName = String.Empty; + public string Name { get { return mvarName; } set { mvarName = value; } } + + private Type mvarDataType = null; + public Type DataType { get { return mvarDataType; } set { mvarDataType = value; } } + + private object mvarValue = null; + public object Value { get { return mvarValue; } set { mvarValue = value; } } + } +} diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectPropertyInstance.cs b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectPropertyInstance.cs new file mode 100644 index 00000000..a3c1679e --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/ObjectModels/Michelangelo/Canvas/CanvasObjectPropertyInstance.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace UniversalEditor.ObjectModels.Michelangelo.Canvas +{ + public class CanvasObjectPropertyInstance + { + public class CanvasObjectPropertyInstanceCollection + : System.Collections.ObjectModel.Collection + { + + } + + private CanvasObjectProperty mvarProperty = null; + public CanvasObjectProperty Property { get { return mvarProperty; } set { mvarProperty = value; } } + + private object mvarValue = null; + public object Value { get { return mvarValue; } set { mvarValue = value; } } + + } +} diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/Properties/AssemblyInfo.cs b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..8c36eb37 --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("UniversalEditor plugin for Michelangelo")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("Mike Becker's Software")] +[assembly: AssemblyProduct("Michelangelo")] +[assembly: AssemblyCopyright("Copyright ©2014 Mike Becker's Software")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("e90eec42-a07f-447d-a078-ac6be9133744")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/UniversalEditor.Plugins.Michelangelo.csproj b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/UniversalEditor.Plugins.Michelangelo.csproj new file mode 100644 index 00000000..77448c63 --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Michelangelo/UniversalEditor.Plugins.Michelangelo.csproj @@ -0,0 +1,73 @@ + + + + + Debug + AnyCPU + {D623EC26-1A04-4BFE-84EE-E738281499C0} + Library + Properties + UniversalEditor + UniversalEditor.Plugins.Michelangelo + v3.5 + 512 + + + + true + full + false + ..\..\Output\Debug\Plugins\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + ..\..\Output\Release\Plugins\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + + + + {3f664673-7e22-4486-9ad0-fc81861d0b78} + UniversalEditor.Compression + + + {2d4737e6-6d95-408a-90db-8dff38147e85} + UniversalEditor.Core + + + {30467e5c-05bc-4856-aadc-13906ef4cadd} + UniversalEditor.Essential + + + {76fd1306-9ca4-428f-993b-b7e4eeeacbf3} + UniversalEditor.Plugins.FileSystem + + + + + \ No newline at end of file diff --git a/CSharp/UniversalEditor.WindowsForms.sln b/CSharp/UniversalEditor.WindowsForms.sln index 9c97a846..66220c97 100644 --- a/CSharp/UniversalEditor.WindowsForms.sln +++ b/CSharp/UniversalEditor.WindowsForms.sln @@ -1,8 +1,6 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2013 -VisualStudioVersion = 12.0.21005.1 -MinimumVisualStudioVersion = 10.0.40219.1 +# Visual Studio 2012 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Libraries", "Libraries", "{15D19291-4200-4C30-A68A-0191B6F83BE1}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UniversalEditor.Core", "Libraries\UniversalEditor.Core\UniversalEditor.Core.csproj", "{2D4737E6-6D95-408A-90DB-8DFF38147E85}" @@ -135,6 +133,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UniversalEditor.Plugins.Web EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UniversalEditor.Plugins.Gainax", "Plugins\UniversalEditor.Plugins.Gainax\UniversalEditor.Plugins.Gainax.csproj", "{7BB04C9F-DC3F-448A-8FD3-9A6BB52BC886}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UniversalEditor.Plugins.Michelangelo", "Plugins\UniversalEditor.Plugins.Michelangelo\UniversalEditor.Plugins.Michelangelo.csproj", "{D623EC26-1A04-4BFE-84EE-E738281499C0}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms", "Engines\WindowsForms\Plugins\UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms\UniversalEditor.Plugins.Michelangelo.UserInterface.WindowsForms.csproj", "{E1A1FD87-BEA4-41B7-9472-B4E35A0630B5}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -362,6 +364,14 @@ Global {7BB04C9F-DC3F-448A-8FD3-9A6BB52BC886}.Debug|Any CPU.Build.0 = Debug|Any CPU {7BB04C9F-DC3F-448A-8FD3-9A6BB52BC886}.Release|Any CPU.ActiveCfg = Release|Any CPU {7BB04C9F-DC3F-448A-8FD3-9A6BB52BC886}.Release|Any CPU.Build.0 = Release|Any CPU + {D623EC26-1A04-4BFE-84EE-E738281499C0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {D623EC26-1A04-4BFE-84EE-E738281499C0}.Debug|Any CPU.Build.0 = Debug|Any CPU + {D623EC26-1A04-4BFE-84EE-E738281499C0}.Release|Any CPU.ActiveCfg = Release|Any CPU + {D623EC26-1A04-4BFE-84EE-E738281499C0}.Release|Any CPU.Build.0 = Release|Any CPU + {E1A1FD87-BEA4-41B7-9472-B4E35A0630B5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {E1A1FD87-BEA4-41B7-9472-B4E35A0630B5}.Debug|Any CPU.Build.0 = Debug|Any CPU + {E1A1FD87-BEA4-41B7-9472-B4E35A0630B5}.Release|Any CPU.ActiveCfg = Release|Any CPU + {E1A1FD87-BEA4-41B7-9472-B4E35A0630B5}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -406,6 +416,7 @@ Global {7C861D40-8214-4DC5-89D1-129F267C1D1B} = {71CFF024-26F7-4626-A526-B435FDF8D64E} {64089452-6A08-47A5-A857-BF418F80D4A3} = {71CFF024-26F7-4626-A526-B435FDF8D64E} {7BB04C9F-DC3F-448A-8FD3-9A6BB52BC886} = {71CFF024-26F7-4626-A526-B435FDF8D64E} + {D623EC26-1A04-4BFE-84EE-E738281499C0} = {71CFF024-26F7-4626-A526-B435FDF8D64E} {FE016EA3-DC31-4A92-8B0A-8C746EC117E1} = {46041F27-7C1C-4209-B72B-251EDB5D4C61} {ED627DF7-3E78-4428-AB31-810BA1586E62} = {46041F27-7C1C-4209-B72B-251EDB5D4C61} {C1F34183-7A2F-41A6-9958-F6F329099654} = {A846CA33-9CAA-4237-B14F-8721DBA89442} @@ -425,6 +436,7 @@ Global {094E86E4-903B-493C-91EF-4597658748A9} = {D3CE7A47-3989-4B6D-9867-0EA3C8DD7AB1} {F635B40D-4BC1-48CB-9FFD-38076D569640} = {D3CE7A47-3989-4B6D-9867-0EA3C8DD7AB1} {997FFB89-0ED6-47EB-BD97-68B3138F91AD} = {D3CE7A47-3989-4B6D-9867-0EA3C8DD7AB1} + {E1A1FD87-BEA4-41B7-9472-B4E35A0630B5} = {D3CE7A47-3989-4B6D-9867-0EA3C8DD7AB1} {118E40C4-323E-4B4B-8EF4-38EED6CC5E83} = {54990D5E-CE09-459F-916E-AF13101765B4} {A5A14A71-5DB3-4495-92F6-8D27C98FF0F4} = {BC6859FB-B61C-471D-9F84-613E5C388C52} EndGlobalSection