protected override Size MeasureOverride(Size constraint) { using (var elapsed = new Elapsed("MatrixView2:Measure:")) { CustomMeasure(); var measured = base.MeasureOverride(constraint); return measured; } }
protected override Size ArrangeOverride(Size arrangeBounds) { using (var elapsed = new Elapsed("MatrixView2:Arrange:")) { //Point location = new Point(); //foreach (var textBlock in _textBlocks) { // Rect rect = new Rect(location, textBlock.DesiredSize); // textBlock.Arrange(rect); // location.X += 10; //} return base.ArrangeOverride(arrangeBounds); } }
protected override Size MeasureOverride(Size availableSize) { using (var elapsed = new Elapsed("Measure:")) { Size measured = base.MeasureOverride(availableSize); return measured; } }
private async Task RefreshVisualsInternalAsync(Rect visualViewport) { using (var elapsed = new Elapsed("RefreshVisuals:")) { Debug.Assert(TaskUtilities.IsOnBackgroundThread()); GridRange newViewport = Points.ComputeDataViewport(visualViewport); var data = await DataProvider.GetAsync(newViewport); await Task.Factory.StartNew( () => DrawVisuals(newViewport, data), CancellationToken.None, TaskCreationOptions.None, ui); } }
protected override Size ArrangeOverride(Size finalSize) { using (var elapsed = new Elapsed("Arrange:")) { return base.ArrangeOverride(finalSize); } }