/// <inheritdoc/> public override DM.IDock CreateLayout() { // Documents var pageDocument = new PageDocument { Id = nameof(PageDocument), Title = "Page" }; // Tools var projectTool = new ProjectTool { Id = nameof(ProjectTool), Title = "Project" }; var optionsTool = new OptionsTool { Id = nameof(OptionsTool), Title = "Options" }; var imagesTool = new ImagesTool { Id = nameof(ImagesTool), Title = "Images" }; var groupsTool = new GroupsTool { Id = nameof(GroupsTool), Title = "Groups" }; var databasesTool = new DatabasesTool { Id = nameof(DatabasesTool), Title = "Databases" }; var scriptTool = new ScriptTool { Id = nameof(ScriptTool), Title = "Script" }; var exportTool = new ExportTool { Id = nameof(ExportTool), Title = "Export" }; var browserTool = new BrowserTool { Id = nameof(BrowserTool), Title = "Browser" }; var documentTool = new DocumentTool { Id = nameof(DocumentTool), Title = "Document" }; var stylesTool = new StylesTool { Id = nameof(StylesTool), Title = "Styles" }; var templatesTool = new TemplatesTool { Id = nameof(TemplatesTool), Title = "Templates" }; var scriptsTool = new ScriptsTool { Id = nameof(ScriptsTool), Title = "Scripts" }; var containerTool = new ContainerTool { Id = nameof(ContainerTool), Title = "Container" }; var zoomTool = new ZoomTool { Id = nameof(ZoomTool), Title = "Zoom" }; var rendererTool = new RendererTool { Id = nameof(RendererTool), Title = "Renderer" }; var shapeTool = new ShapeTool { Id = nameof(ShapeTool), Title = "Shape" }; var toolsTool = new ToolsTool { Id = nameof(ToolsTool), Title = "Tools" }; var recordTool = new RecordTool { Id = nameof(RecordTool), Title = "Record" }; var propertiesTool = new PropertiesTool { Id = nameof(PropertiesTool), Title = "Properties" }; var styleTool = new StyleTool { Id = nameof(StyleTool), Title = "Style" }; var templateTool = new TemplateTool { Id = nameof(TemplateTool), Title = "Template" }; // Panes var leftPane = new DMC.ProportionalDock { Id = nameof(DMC.IProportionalDock), Title = "EditorLeft", Orientation = DM.Orientation.Vertical, Proportion = 0.17, ActiveDockable = null, VisibleDockables = CreateList <DM.IDockable> ( new DMC.ToolDock { Id = nameof(DMC.IToolDock), Title = "EditorLeftTop", Proportion = double.NaN, ActiveDockable = projectTool, VisibleDockables = CreateList <DM.IDockable> ( projectTool, optionsTool, rendererTool, imagesTool ) }, new DMC.SplitterDock() { Id = nameof(DMC.ISplitterDock), Title = "LeftTopSplitter" }, new DMC.ToolDock { Id = nameof(DMC.IToolDock), Title = "EditorLeftBottom", Proportion = double.NaN, ActiveDockable = groupsTool, VisibleDockables = CreateList <DM.IDockable> ( groupsTool, databasesTool, toolsTool, scriptsTool ) } ) }; var rightPane = new DMC.ProportionalDock { Id = nameof(DMC.IProportionalDock), Title = "EditorRight", Orientation = DM.Orientation.Vertical, Proportion = 0.20, ActiveDockable = null, VisibleDockables = CreateList <DM.IDockable> ( new DMC.ToolDock { Id = nameof(DMC.IToolDock), Title = "EditorRightTop", Proportion = double.NaN, ActiveDockable = stylesTool, VisibleDockables = CreateList <DM.IDockable> ( stylesTool, containerTool, templatesTool, templateTool ) }, new DMC.SplitterDock() { Id = nameof(DMC.ISplitterDock), Title = "RightTopSplitter" }, new DMC.ToolDock { Id = nameof(DMC.IToolDock), Title = "EditorRightBottom", Proportion = double.NaN, ActiveDockable = shapeTool, VisibleDockables = CreateList <DM.IDockable> ( shapeTool, propertiesTool, recordTool, styleTool, zoomTool ) } ) }; var documentsPane = new DMC.DocumentDock { Id = nameof(DMC.IDocumentDock), Title = "DocumentsPane", IsCollapsable = false, Proportion = double.NaN, ActiveDockable = pageDocument, VisibleDockables = CreateList <DM.IDockable> ( pageDocument, documentTool, scriptTool, exportTool, browserTool ) }; // Editor var editorLayout = new DMC.ProportionalDock { Id = nameof(DMC.IProportionalDock), Title = "EditorLayout", Orientation = DM.Orientation.Horizontal, Proportion = double.NaN, ActiveDockable = null, VisibleDockables = CreateList <DM.IDockable> ( leftPane, new DMC.SplitterDock() { Id = nameof(DMC.ISplitterDock), Title = "LeftSplitter" }, documentsPane, new DMC.SplitterDock() { Id = nameof(DMC.ISplitterDock), Title = "RightSplitter" }, rightPane ) }; // Views var dashboardView = new DashboardView { Id = nameof(DashboardView), Title = "Dashboard" }; var editorView = new EditorView { Id = nameof(EditorView), Title = "Editor", ActiveDockable = editorLayout, VisibleDockables = CreateList <DM.IDockable> ( editorLayout ) }; // Root var root = new DMC.RootDock { Id = nameof(DMC.IRootDock), Title = "Root", IsCollapsable = false, ActiveDockable = dashboardView, DefaultDockable = dashboardView, VisibleDockables = CreateList <DM.IDockable> ( dashboardView, editorView ) }; root.Top = CreatePinDock(); root.Top.Alignment = DM.Alignment.Top; root.Bottom = CreatePinDock(); root.Bottom.Alignment = DM.Alignment.Bottom; root.Left = CreatePinDock(); root.Left.Alignment = DM.Alignment.Left; root.Right = CreatePinDock(); root.Right.Alignment = DM.Alignment.Right; return(root); }
/// <inheritdoc/> public override IDock CreateLayout() { // Documents var pageDocument = new PageDocument { Id = nameof(PageDocument), Title = "Page" }; // Tools var projectTool = new ProjectTool { Id = nameof(ProjectTool), Title = "Project" }; var optionsTool = new OptionsTool { Id = nameof(OptionsTool), Title = "Options" }; var imagesTool = new ImagesTool { Id = nameof(ImagesTool), Title = "Images" }; var groupsTool = new GroupsTool { Id = nameof(GroupsTool), Title = "Groups" }; var databasesTool = new DatabasesTool { Id = nameof(DatabasesTool), Title = "Databases" }; var scriptTool = new ScriptTool { Id = nameof(ScriptTool), Title = "Script" }; var browserTool = new BrowserTool { Id = nameof(BrowserTool), Title = "Browser" }; var stylesTool = new StylesTool { Id = nameof(StylesTool), Title = "Styles" }; var templatesTool = new TemplatesTool { Id = nameof(TemplatesTool), Title = "Templates" }; var containerTool = new ContainerTool { Id = nameof(ContainerTool), Title = "Container" }; var zoomTool = new ZoomTool { Id = nameof(ZoomTool), Title = "Zoom" }; var shapeTool = new ShapeTool { Id = nameof(ShapeTool), Title = "Shape" }; var toolsTool = new ToolsTool { Id = nameof(ToolsTool), Title = "Tools" }; var dataTool = new DataTool { Id = nameof(DataTool), Title = "Data" }; var styleTool = new StyleTool { Id = nameof(StyleTool), Title = "Style" }; var templateTool = new TemplateTool { Id = nameof(TemplateTool), Title = "Template" }; // Panes var leftPane = new LayoutDock { Id = nameof(ILayoutDock), Title = "EditorLeft", Orientation = Orientation.Vertical, Proportion = 0.17, CurrentView = null, Views = new ObservableCollection <IView> { new ToolDock { Id = nameof(IToolDock), Title = "EditorLeftTop", Proportion = double.NaN, CurrentView = projectTool, Views = new ObservableCollection <IView> { projectTool, optionsTool, imagesTool } }, new SplitterDock() { Id = nameof(ISplitterDock), Title = "LeftTopSplitter" }, new ToolDock { Id = nameof(IToolDock), Title = "EditorLeftBottom", Proportion = double.NaN, CurrentView = groupsTool, Views = new ObservableCollection <IView> { groupsTool, databasesTool, scriptTool, browserTool } } } }; var rightPane = new LayoutDock { Id = nameof(ILayoutDock), Title = "EditorRight", Orientation = Orientation.Vertical, Proportion = 0.17, CurrentView = null, Views = new ObservableCollection <IView> { new ToolDock { Id = nameof(IToolDock), Title = "EditorRightTop", Proportion = double.NaN, CurrentView = stylesTool, Views = new ObservableCollection <IView> { stylesTool, templatesTool, containerTool, zoomTool } }, new SplitterDock() { Id = nameof(ISplitterDock), Title = "RightTopSplitter" }, new ToolDock { Id = nameof(IToolDock), Title = "EditorRightBottom", Proportion = double.NaN, CurrentView = shapeTool, Views = new ObservableCollection <IView> { shapeTool, toolsTool, dataTool, styleTool, templateTool } } } }; var documentsPane = new DocumentDock { Id = nameof(IDocumentDock), Title = "DocumentsPane", Proportion = double.NaN, CurrentView = pageDocument, Views = new ObservableCollection <IView> { pageDocument } }; // Editor var editorLayout = new LayoutDock { Id = nameof(ILayoutDock), Title = "EditorLayout", Orientation = Orientation.Horizontal, Proportion = double.NaN, CurrentView = null, Views = new ObservableCollection <IView> { leftPane, new SplitterDock() { Id = nameof(ISplitterDock), Title = "LeftSplitter" }, documentsPane, new SplitterDock() { Id = nameof(ISplitterDock), Title = "RightSplitter" }, rightPane } }; // Views var editorView = new EditorView { Id = nameof(EditorView), Title = "Editor", CurrentView = editorLayout, Views = new ObservableCollection <IView> { editorLayout } }; var aboutView = new AboutView { Id = nameof(AboutView), Title = "About" }; var browserView = new BrowserView { Id = nameof(BrowserView), Title = "Browser" }; var scriptView = new ScriptView { Id = nameof(ScriptView), Title = "Script" }; var documentView = new DocumentView { Id = nameof(DocumentView), Title = "Document" }; var dashboardView = new DashboardView { Id = nameof(DashboardView), Title = "Dashboard" }; // Root var layout = new RootDock { Id = nameof(IRootDock), Title = "Root", CurrentView = dashboardView, DefaultView = dashboardView, Views = new ObservableCollection <IView> { dashboardView, editorView, aboutView, browserView, scriptView, documentView } }; return(layout); }
/// <inheritdoc/> public override IDock CreateLayout() { // Documents var pageDocument = new PageDocument { Id = nameof(PageDocument), Width = double.NaN, Height = double.NaN, Title = "Page" }; // Left / Top var projectView = new ProjectTool { Id = nameof(ProjectTool), Width = double.NaN, Height = double.NaN, Title = "Project" }; var optionsView = new OptionsTool { Id = nameof(OptionsTool), Width = 200, Height = 200, Title = "Options" }; var imagesView = new ImagesTool { Id = nameof(ImagesTool), Width = double.NaN, Height = double.NaN, Title = "Images" }; // Left / Bottom var groupsView = new GroupsTool { Id = nameof(GroupsTool), Width = double.NaN, Height = double.NaN, Title = "Groups" }; var databasesView = new DatabasesTool { Id = nameof(DatabasesTool), Width = double.NaN, Height = double.NaN, Title = "Databases" }; // Right / Top var stylesView = new StylesTool { Id = nameof(StylesTool), Width = double.NaN, Height = double.NaN, Title = "Styles" }; var templatesView = new TemplatesTool { Id = nameof(TemplatesTool), Width = double.NaN, Height = double.NaN, Title = "Templates" }; var containerView = new ContainerTool { Id = nameof(ContainerTool), Width = double.NaN, Height = double.NaN, Title = "Container" }; var zoomView = new ZoomTool { Id = nameof(ZoomTool), Width = double.NaN, Height = double.NaN, Title = "Zoom" }; // Right / Bottom var toolsView = new ToolsTool { Id = nameof(ToolsTool), Width = double.NaN, Height = double.NaN, Title = "Tools" }; var shapeView = new ShapeTool { Id = nameof(ShapeTool), Width = double.NaN, Height = double.NaN, Title = "Shape" }; var dataView = new DataTool { Id = nameof(DataTool), Width = double.NaN, Height = double.NaN, Title = "Data" }; var styleView = new StyleTool { Id = nameof(StyleTool), Width = double.NaN, Height = double.NaN, Title = "Style" }; var templateView = new TemplateTool { Id = nameof(TemplateTool), Width = double.NaN, Height = double.NaN, Title = "Template" }; // Left Pane var leftPane = new LayoutDock { Id = nameof(ILayoutDock), Dock = "Left", Width = 200, Height = double.NaN, Title = "EditorLeft", CurrentView = null, Views = new ObservableCollection <IView> { new ToolDock { Id = nameof(IToolDock), Dock = "Top", Width = double.NaN, Height = 340, Title = "EditorLeftTop", CurrentView = projectView, Views = new ObservableCollection <IView> { projectView, optionsView, imagesView } }, new SplitterDock() { Id = nameof(ISplitterDock), Dock = "Top", Title = "LeftTopSplitter" }, new ToolDock { Id = nameof(IToolDock), Dock = "Bottom", Width = double.NaN, Height = double.NaN, Title = "EditorLeftBottom", CurrentView = groupsView, Views = new ObservableCollection <IView> { groupsView, databasesView } } } }; // Right Pane var rightPane = new LayoutDock { Id = nameof(ILayoutDock), Dock = "Right", Width = 240, Height = double.NaN, Title = "EditorRight", CurrentView = null, Views = new ObservableCollection <IView> { new ToolDock { Id = nameof(IToolDock), Dock = "Top", Width = double.NaN, Height = 340, Title = "EditorRightTop", CurrentView = stylesView, Views = new ObservableCollection <IView> { stylesView, templatesView, containerView, zoomView } }, new SplitterDock() { Id = nameof(ISplitterDock), Dock = "Top", Title = "RightTopSplitter" }, new ToolDock { Id = nameof(IToolDock), Dock = "Bottom", Width = double.NaN, Height = double.NaN, Title = "EditorRightBottom", CurrentView = toolsView, Views = new ObservableCollection <IView> { toolsView, shapeView, dataView, styleView, templateView } } } }; // Documents var documentsPane = new DocumentDock { Id = nameof(IDocumentDock), Dock = "", Width = double.NaN, Height = double.NaN, Title = "DocumentsPane", CurrentView = pageDocument, Views = new ObservableCollection <IView> { pageDocument } }; // Main var editorLayout = new LayoutDock { Id = nameof(ILayoutDock), Dock = "", Width = double.NaN, Height = double.NaN, Title = "EditorLayout", CurrentView = null, Views = new ObservableCollection <IView> { leftPane, new SplitterDock() { Id = nameof(ISplitterDock), Dock = "Left", Title = "LeftSplitter" }, rightPane, new SplitterDock() { Id = nameof(ISplitterDock), Dock = "Right", Title = "RightSplitter" }, documentsPane } }; var editorView = new EditorView { Id = nameof(EditorView), Width = double.NaN, Height = double.NaN, Title = "Editor", CurrentView = editorLayout, Views = new ObservableCollection <IView> { editorLayout } }; // About var aboutView = new AboutView { Id = nameof(AboutView), Width = double.NaN, Height = double.NaN, Title = "About" }; // Browser var browserView = new BrowserView { Id = nameof(BrowserView), Width = double.NaN, Height = double.NaN, Title = "Browser" }; // Document var documentView = new DocumentView { Id = nameof(DocumentView), Width = double.NaN, Height = double.NaN, Title = "Document" }; // Dashboard var dashboardView = new DashboardView { Id = nameof(DashboardView), Width = double.NaN, Height = double.NaN, Title = "Dashboard" }; // Main var layout = new RootDock { Id = nameof(IRootDock), Width = double.NaN, Height = double.NaN, Title = "Root", CurrentView = dashboardView, DefaultView = dashboardView, Views = new ObservableCollection <IView> { dashboardView, editorView, aboutView, browserView, documentView } }; return(layout); }