Line | |
---|
1 | using System;
|
---|
2 | using System.Collections.Generic;
|
---|
3 | using System.Linq;
|
---|
4 | using System.Text;
|
---|
5 | using System.Windows.Media;
|
---|
6 |
|
---|
7 | namespace Microsoft.Research.DynamicDataDisplay.Charts
|
---|
8 | {
|
---|
9 | /// <summary>
|
---|
10 | /// Represents a vertical axis with values of System.Double type.
|
---|
11 | /// Can be placed only from left or right side of plotter.
|
---|
12 | /// By default is placed from the left side.
|
---|
13 | /// </summary>
|
---|
14 | public class VerticalAxis : NumericAxis
|
---|
15 | {
|
---|
16 | /// <summary>
|
---|
17 | /// Initializes a new instance of the <see cref="VerticalAxis"/> class.
|
---|
18 | /// </summary>
|
---|
19 | public VerticalAxis()
|
---|
20 | {
|
---|
21 | Placement = AxisPlacement.Left;
|
---|
22 | }
|
---|
23 |
|
---|
24 | /// <summary>
|
---|
25 | /// Validates the placement - e.g., vertical axis should not be placed from top or bottom, etc.
|
---|
26 | /// If proposed placement if wrong, throws an ArgumentException.
|
---|
27 | /// </summary>
|
---|
28 | /// <param name="newPlacement">The new placement.</param>
|
---|
29 | protected override void ValidatePlacement(AxisPlacement newPlacement)
|
---|
30 | {
|
---|
31 | if (newPlacement == AxisPlacement.Bottom || newPlacement == AxisPlacement.Top)
|
---|
32 | throw new ArgumentException(Strings.Exceptions.VerticalAxisCannotBeHorizontal);
|
---|
33 | }
|
---|
34 | }
|
---|
35 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.