From 883dbb189f8dc975334f8e0f2acadda1f4180eae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=98=D0=B2=D0=B0=D0=BD=20=D0=98=D0=B2=D0=B0=D1=88=D0=BA?= =?UTF-8?q?=D0=B8=D0=BD?= Date: Mon, 14 Oct 2024 20:36:25 +0500 Subject: [PATCH] Fix: return graph from player to independent button, develop: add MainGraphView, TreeView, TreeCommand. --- StructureHelper/StructureHelper.csproj.user | 12 ++ .../Windows/MainGraph/AddTable.xaml | 25 +++ .../Windows/MainGraph/AddTable.xaml.cs | 27 ++++ .../Windows/MainGraph/AddTableViewModel.cs | 14 ++ .../Windows/MainGraph/GraphView.xaml | 75 ++++++++- .../Windows/MainGraph/GraphView.xaml.cs | 14 +- .../Windows/MainGraph/GraphViewModel.cs | 142 ++++++++++++++++++ .../MainWindow/Analyses/AnalysesLogic.cs | 6 +- .../MainWindow/Analyses/VisualAnalysis.cs | 10 +- .../Windows/TreeGraph/TreeGraph.xaml | 67 +++++++++ .../Windows/TreeGraph/TreeGraph.xaml.cs | 28 ++++ .../Windows/TreeGraph/TreeGraphViewModel.cs | 22 +++ StructureHelperCommon/FunctionDecorator.cd | 6 +- .../Interfaces/IOneVariableFunction.cs | 3 + .../Models/Functions/FormulaFunction.cs | 4 + .../Models/Functions/TableFunction.cs | 4 + .../StructureHelperTests.csproj | 2 - 17 files changed, 440 insertions(+), 21 deletions(-) create mode 100644 StructureHelper/Windows/MainGraph/AddTable.xaml create mode 100644 StructureHelper/Windows/MainGraph/AddTable.xaml.cs create mode 100644 StructureHelper/Windows/MainGraph/AddTableViewModel.cs create mode 100644 StructureHelper/Windows/MainGraph/GraphViewModel.cs create mode 100644 StructureHelper/Windows/TreeGraph/TreeGraph.xaml create mode 100644 StructureHelper/Windows/TreeGraph/TreeGraph.xaml.cs create mode 100644 StructureHelper/Windows/TreeGraph/TreeGraphViewModel.cs diff --git a/StructureHelper/StructureHelper.csproj.user b/StructureHelper/StructureHelper.csproj.user index a0b9e13..261919a 100644 --- a/StructureHelper/StructureHelper.csproj.user +++ b/StructureHelper/StructureHelper.csproj.user @@ -57,6 +57,9 @@ Code + + Code + Code @@ -81,6 +84,9 @@ Code + + Code + Code @@ -158,6 +164,9 @@ Designer + + Designer + Designer @@ -182,6 +191,9 @@ Designer + + Designer + Designer diff --git a/StructureHelper/Windows/MainGraph/AddTable.xaml b/StructureHelper/Windows/MainGraph/AddTable.xaml new file mode 100644 index 0000000..b10c9fc --- /dev/null +++ b/StructureHelper/Windows/MainGraph/AddTable.xaml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + diff --git a/StructureHelper/Windows/MainGraph/AddTable.xaml.cs b/StructureHelper/Windows/MainGraph/AddTable.xaml.cs new file mode 100644 index 0000000..870629f --- /dev/null +++ b/StructureHelper/Windows/MainGraph/AddTable.xaml.cs @@ -0,0 +1,27 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Shapes; + +namespace StructureHelper.Windows.MainGraph +{ + /// + /// Interaction logic for AddTable.xaml + /// + public partial class AddTable : Window + { + public AddTable() + { + InitializeComponent(); + } + } +} diff --git a/StructureHelper/Windows/MainGraph/AddTableViewModel.cs b/StructureHelper/Windows/MainGraph/AddTableViewModel.cs new file mode 100644 index 0000000..7719aea --- /dev/null +++ b/StructureHelper/Windows/MainGraph/AddTableViewModel.cs @@ -0,0 +1,14 @@ +using StructureHelper.Infrastructure; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace StructureHelper.Windows.MainGraph +{ + class AddTableViewModel : ViewModelBase + { + + } +} diff --git a/StructureHelper/Windows/MainGraph/GraphView.xaml b/StructureHelper/Windows/MainGraph/GraphView.xaml index 4c7aed6..d2c363f 100644 --- a/StructureHelper/Windows/MainGraph/GraphView.xaml +++ b/StructureHelper/Windows/MainGraph/GraphView.xaml @@ -3,15 +3,76 @@ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" + xmlns:lvc="clr-namespace:LiveCharts.Wpf;assembly=LiveCharts.Wpf" xmlns:local="clr-namespace:StructureHelper.Windows.MainGraph" mc:Ignorable="d" - Title="GraphView" Height="450" Width="800"> + d:DataContext="{d:DesignInstance local:GraphViewModel}" + Title="StructureHelper" Height="700" + Width="1000" MinHeight="400" MinWidth="600"> - + + + + + + + + + + + + + + + + + + + + + + + + + +