コード例 #1
0
 private void RenderChart()
 {
     if (modelChart != null)
     {
         ChartsModel.ModelRect rect = new ChartsModel.ModelRect(0, 0, viewPanel.ActualWidth, viewPanel.ActualHeight);
         var renderContext          = factory.CreateRenderContext(rect, viewPanel);
         controller.RenderChart(renderContext);
     }
 }
コード例 #2
0
 private void View_Paint(object sender, PaintEventArgs e)
 {
     if (modelChart != null)
     {
         var graphics = e.Graphics;
         ChartsModel.ModelRect rect = new ChartsModel.ModelRect(8, 8, viewPanel.ClientSize.Width - 16, viewPanel.ClientSize.Height - 16);
         var renderContext          = factory.CreateRenderContext(rect, graphics);
         controller.RenderChart(renderContext);
     }
 }