public IVisualComponentContainer <IRPlotDeviceVisualComponent> GetOrCreate(IRPlotManagerVisual plotManager, IRSession session, int instanceId = 0) { return(GetOrCreate(instanceId, container => new RPlotDeviceVisualComponent(plotManager, instanceId, container, _coreShell.Services) { TestDeviceProperties = DeviceProperties })); }
public async Task InitializeAsync() { await _remoteBroker.ConnectAsync(_workflow.RSessions); _replVisualComponent = await _workflow.GetOrCreateVisualComponentAsync(); _plotManager = (IRPlotManagerVisual)_workflow.Plots; _plotDeviceVisualComponentContainerFactory.DeviceProperties = new PlotDeviceProperties(600, 500, 96); }
public async Task InitializeAsync() { await _workflow.RSessions.TrySwitchBrokerAsync(nameof(RPlotIntegrationTest)); _replVisualComponent = await _workflow.GetOrCreateVisualComponentAsync(); _plotManager = (IRPlotManagerVisual)_workflow.Plots; _plotDeviceVisualComponentContainerFactory.DeviceProperties = new PlotDeviceProperties(600, 500, 96); }
public PlotDeviceWindowPane(IRPlotManagerVisual plotManager, IRSession session, int instanceId, IServiceContainer services) : base(services) { _plotManager = plotManager; _instanceId = instanceId; // this value matches with icmdShowPlotWindow's Icon in VSCT file BitmapImageMoniker = KnownMonikers.LineChart; Caption = Resources.PlotWindowCaption; ToolBar = new System.ComponentModel.Design.CommandID(RGuidList.RCmdSetGuid, RPackageCommandId.plotWindowToolBarId); }
public RPlotIntegrationUITest(IServiceContainer services, ContainerHostMethodFixture containerHost) { _containerHost = containerHost; _plotDeviceVisualComponentContainerFactory = services.GetService <TestRPlotDeviceVisualComponentContainerFactory>(); // Don't override the standard behavior of using the control size _plotDeviceVisualComponentContainerFactory.DeviceProperties = null; _plotHistoryVisualComponentContainerFactory = services.GetService <IRPlotHistoryVisualComponentContainerFactory>(); _workflow = services.GetService <IRInteractiveWorkflowVisualProvider>().GetOrCreate(); _plotVisual = (IRPlotManagerVisual)_workflow.Plots; _plotVisualComponent = UIThreadHelper.Instance.Invoke(() => _workflow.Plots.GetOrCreateVisualComponent(_plotDeviceVisualComponentContainerFactory, PlotWindowInstanceId)); UIThreadHelper.Instance.Invoke(() => ((IRPlotManagerVisual)_workflow.Plots).RegisterVisualComponent(_plotVisualComponent)); }
public IVisualComponentContainer <IRPlotDeviceVisualComponent> GetOrCreate(IRPlotManagerVisual plotManager, IRSession session, int instanceId = 0) { return(GetOrCreate(instanceId, i => new PlotDeviceWindowPane(plotManager, session, i, _coreShell.Services))); }
public ShowPlotWindowCommand(ICoreShell shell, IRInteractiveWorkflow workflow) { _plotManager = workflow.Plots as IRPlotManagerVisual; _shell = shell.GetService <IVsUIShell4>(typeof(SVsUIShell)); }