Free cookie consent management tool by TermsFeed Policy Generator

Changeset 13105 for branches


Ignore:
Timestamp:
11/03/15 11:29:00 (9 years ago)
Author:
jkarder
Message:

#1265: worked on visualization

  • added BackgroundColor to IChart
  • added RulerChartMode
  • renamed MoveChartMode to PanChartMode
Location:
branches/HeuristicLab.Visualization/HeuristicLab.Visualization/3.3
Files:
1 added
4 edited
1 moved

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.Visualization/HeuristicLab.Visualization/3.3/Chart.cs

    r13045 r13105  
    4141    }
    4242
     43    private Color backgroundColor;
     44    public Color BackgroundColor {
     45      get { return backgroundColor; }
     46      set {
     47        if (backgroundColor == value) return;
     48        backgroundColor = value;
     49        OnRedrawRequired();
     50      }
     51    }
     52
    4353    protected bool SuppressRedraw { get; set; }
    4454
     
    7585      SetPosition(lowerLeft, upperRight);
    7686      mySizeInPixels = new Size((int)Size.Width, (int)Size.Height);
     87      backgroundColor = Color.White;
    7788      Scale = 1.0;
    7889      Group = new Group(this);
     
    228239    public virtual void Render(Graphics graphics, int width, int height) {
    229240      mySizeInPixels = new Size(width, height);
     241      graphics.Clear(backgroundColor);
    230242      Group.PreDraw(graphics);
    231243      Group.Draw(graphics);
  • branches/HeuristicLab.Visualization/HeuristicLab.Visualization/3.3/ChartControl.cs

    r13076 r13105  
    3939    public PictureBox PictureBox { get { return pictureBox; } }
    4040
     41    public Color BackgroundColor {
     42      get { return chart != null ? chart.BackgroundColor : null; }
     43      set {
     44        if (chart == null || chart.BackgroundColor == value) return;
     45        chart.BackgroundColor = value;
     46      }
     47    }
     48
    4149    private IChart chart;
    4250    public IChart Chart {
  • branches/HeuristicLab.Visualization/HeuristicLab.Visualization/3.3/ChartModes/PanChartMode.cs

    r13104 r13105  
    2525
    2626namespace HeuristicLab.Visualization {
    27   public class MoveChartMode : ChartMode {
     27  public class PanChartMode : ChartMode {
    2828    public override Image Image { get { return VSImageLibrary.Breakpoint; } }
    29     public override string ToolTip { get { return "Move"; } }
     29    public override string ToolTip { get { return "Pan"; } }
    3030
    3131    public override Cursor Cursor {
     
    3333    }
    3434
    35     public MoveChartMode(ChartControl control) : base(control) { }
     35    public PanChartMode(ChartControl control) : base(control) { }
    3636
    3737    public override void HandleOnMouseUp(object sender, MouseEventArgs e) {
  • branches/HeuristicLab.Visualization/HeuristicLab.Visualization/3.3/HeuristicLab.Visualization-3.3.csproj

    r13076 r13105  
    130130    <Compile Include="ChartMode.cs" />
    131131    <Compile Include="AxisType.cs" />
    132     <Compile Include="ChartModes\MoveChartMode.cs" />
     132    <Compile Include="ChartModes\PanChartMode.cs" />
     133    <Compile Include="ChartModes\RulerChartMode.cs" />
    133134    <Compile Include="Primitives\Grid.cs" />
    134135    <Compile Include="Properties\Resources.Designer.cs">
  • branches/HeuristicLab.Visualization/HeuristicLab.Visualization/3.3/Interfaces/IChart.cs

    r13045 r13105  
    2828  public interface IChart {
    2929    bool Enabled { get; set; }
     30    Color BackgroundColor { get; set; }
    3031
    3132    PointD LowerLeft { get; }
Note: See TracChangeset for help on using the changeset viewer.