public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { using (var token = ctrl.DataTable.SuspendGetToken()) { ctrl.DataTable.DataColumns.RemoveColumnsAll(); } }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { using (var token = ctrl.DataTable.SuspendGetToken()) { Altaxo.Worksheet.Commands.WorksheetCommands.WorksheetClearData(ctrl); } }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { var comm = new OriginConnection(); comm.Connect(true); comm.PutTable(ctrl.DataTable, false); comm.Disconnect(false, null, false); }
public override void Dispose() { base.Dispose(); if (null != _controller) { _controller.Dispose(); _controller = null; } }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { string msg = Altaxo.Worksheet.Commands.EditCommands.XYVToMatrix(ctrl); if (msg != null) { Current.Gui.ErrorMessageBox(msg); } }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { PresentationCoreLoader.EnsurePresentationCoreLoaded(); var graph = Altaxo.Graph.Graph3D.Templates.TemplateWithXYZPlotLayerWithG3DCartesicCoordinateSystem.CreateGraph( PropertyExtensions.GetPropertyContextOfProjectFolder(ctrl.DataTable.Folder), "GRAPH", ctrl.DataTable.Folder, false); Current.ProjectService.OpenOrCreateViewContentForDocument(graph); }
public static void Sort(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl, bool ascending) { if (ctrl.SelectedDataColumns.Count == 1) { Altaxo.Data.Sorting.SortDataRows(ctrl.DataTable, ctrl.DataTable.DataColumns[ctrl.SelectedDataColumns[0]], ascending); } else if (ctrl.SelectedPropertyColumns.Count == 1) { Altaxo.Data.Sorting.SortDataColumnsByPropertyColumn(ctrl.DataTable, ctrl.DataTable.PropCols[ctrl.SelectedPropertyColumns[0]], ascending); } }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { if (ctrl.SelectedDataColumns.Count > 0) { new OpenDataColumnScriptDialog().Run(ctrl); // Altaxo.Worksheet.Commands.ColumnCommands.SetColumnValues(ctrl); } else { new OpenPropertyColumnScriptDialog().Run(ctrl); } }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { PresentationCoreLoader.EnsurePresentationCoreLoaded(); var table = ctrl.DataTable; var graph = Altaxo.Graph.Graph3D.Templates.TemplateWithXYZPlotLayerWithG3DCartesicCoordinateSystem.CreateGraph( table.GetPropertyContext(), null, table.Name, true); AddSurfacePlot(ctrl, graph); Current.ProjectService.OpenOrCreateViewContentForDocument(graph); }
public static void Sort(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl, bool ascending) { Altaxo.Collections.IAscendingIntegerCollection selectedDataColumns = ctrl.SelectedDataColumns; if (0 == selectedDataColumns.Count) { selectedDataColumns = Altaxo.Collections.ContiguousIntegerRange.FromStartAndCount(0, ctrl.DataTable.DataColumnCount); } if (0 == ctrl.SelectedPropertyColumns.Count || 0 == selectedDataColumns.Count) { return; } Altaxo.Data.Sorting.SortDataColumnsByPropertyColumn(ctrl.DataTable, selectedDataColumns, ctrl.DataTable.PropCols[ctrl.SelectedPropertyColumns[0]], ascending); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { _table = ctrl.DataTable; var script = _table.GetPropertyValue <FileImportScript>("Temp\\FileImportScript") ?? new FileImportScript(); object[] args = new object[] { script, new Altaxo.Gui.Scripting.ScriptExecutionHandler(EhScriptExecution) }; if (Current.Gui.ShowDialog(args, "File import script of " + _table.Name)) { _table.PropertyBag.SetValue <FileImportScript>("Temp\\FileImportScript", (FileImportScript)args[0]); } _table = null; }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { _table = ctrl.DataTable; var script = _table.TableScript ?? new TableScript(); object[] args = new object[] { script, new Altaxo.Gui.Scripting.ScriptExecutionHandler(EhScriptExecution) }; if (Current.Gui.ShowDialog(args, "WorksheetScript of " + _table.Name)) { _table.TableScript = (TableScript)args[0]; } _table = null; }
/// <summary> /// Creates a view content for a table. /// </summary> /// <param name="table">The table which should be viewed.</param> /// <param name="layout">The layout for the table.</param> /// <returns>The view content for the provided table.</returns> private Altaxo.Gui.Worksheet.Viewing.IWorksheetController CreateNewWorksheet_Unsynchronized(Altaxo.Data.DataTable table, Altaxo.Worksheet.WorksheetLayout layout) { layout.DataTable = table; var ctrl = new Altaxo.Gui.Worksheet.Viewing.WorksheetController(layout); var view = new Altaxo.Gui.Worksheet.Viewing.WorksheetViewWpf(); ctrl.ViewObject = view; if (null != Current.Workbench) { Current.Workbench.ShowView(ctrl, true); } return(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { m_Table = ctrl.DataTable; var script = ctrl.DataTable.GetTableProperty(ExtractTableDataScriptPropertyName) as ExtractTableDataScript; if (script == null) { script = new ExtractTableDataScript(); } object[] args = new object[] { script, new ScriptExecutionHandler(EhScriptExecution) }; if (Current.Gui.ShowDialog(args, "WorksheetScript of " + m_Table.Name)) { m_Table.SetTableProperty(ExtractTableDataScriptPropertyName, args[0]); } m_Table = null; }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { var comm = new OriginConnection(); comm.Connect(true); if (!comm.IsConnected()) { return; } string err = comm.GetTable(ctrl.DataTable.Name, ctrl.DataTable); comm.Disconnect(false, null, false); if (err != null) { Current.Gui.ErrorMessageBox(err); return; } }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Data.DataTable dataTable = ctrl.DataTable; if (ctrl.SelectedPropertyColumns.Count == 0) { return; } m_Column = dataTable.PropertyColumns[ctrl.SelectedPropertyColumns[0]]; dataTable.PropertyColumns.ColumnScripts.TryGetValue(m_Column, out var script); if (script == null) { script = new PropertyColumnScript(); } object[] args = new object[] { script, new ScriptExecutionHandler(EhScriptExecution) }; if (Current.Gui.ShowDialog(args, "PropertyColumnScript of " + m_Column.Name)) { dataTable.PropCols.ColumnScripts[m_Column] = (IColumnScriptText)args[0]; } m_Column = null; }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.ChemometricCommands.MultiplyColumnsToMatrix(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { PlotCommands3D.PlotColumnChartNormal(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { PlotCommands3D.PlotBarChartRelativeStack(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { PlotCommands3D.PlotLine(ctrl, true, true); }
public SDWorksheetViewContent(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { _controller = ctrl; ctrl.TitleNameChanged += new WeakEventHandler(this.EhTitleNameChanged, x => ctrl.TitleNameChanged -= x); SetTitle(); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.StatisticCommands.StatisticsOnColumns(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.CalculusCommands.Interpolation(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.CalculusCommands.SavitzkyGolayFiltering(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.ChemometricCommands.ExportPLSCalibration(ctrl.DataTable); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.ChemometricCommands.PlotCrossPredictedVersusActualY(ctrl.DataTable, true); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.ChemometricCommands.PlotPreprocessedSpectra(ctrl.DataTable); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.StatisticCommands.CreateHistogram(ctrl); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.ChemometricCommands.QuestPreferredNumberOfFactors(ctrl.DataTable); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { ctrl.WorksheetLayout.ShowSaveAsDialog(true); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.ChemometricCommands.PlotXResiduals(ctrl.DataTable); }
public override void Run(Altaxo.Gui.Worksheet.Viewing.WorksheetController ctrl) { Altaxo.Worksheet.Commands.Analysis.ChemometricCommands.PredictOnColumns(ctrl); }