NPlot::VerticalLine Class Reference

Encapsulates functionality for drawing a vertical line on a plot surface. More...

Inheritance diagram for NPlot::VerticalLine:

NPlot::IPlot NPlot::IDrawable List of all members.

Public Member Functions

 VerticalLine (double abscissaValue)
 Constructor.
 VerticalLine (double abscissaValue, Color color)
 Constructor.
 VerticalLine (double abscissaValue, Pen pen)
 Constructor.
void DrawInLegend (System.Drawing.Graphics g, System.Drawing.Rectangle startEnd)
 Draws a representation of the line in the legend.
Axis SuggestXAxis ()
 Returns an x-axis that is suitable for drawing this plot.
Axis SuggestYAxis ()
 Returns null indicating that y extremities of the line are variable.
void WriteData (System.Text.StringBuilder sb, RectangleD region, bool onlyInRegion)
 Writes text data describing the vertical line object to the supplied string builder.
void Draw (System.Drawing.Graphics g, PhysicalAxis xAxis, PhysicalAxis yAxis)
 Draws the vertical line plot on a GDI+ surface against the provided x and y axes.

Properties

string Label
 A label to associate with the plot - used in the legend.
string label_ = ""
bool ShowInLegend
 Whether or not to include an entry for this plot in the legend if it exists.
bool showInLegend_ = false
double AbscissaValue
 abscissa (X) value to draw horizontal line at.
Pen Pen
 Pen to use to draw the horizontal line.
double value_
Pen pen_ = new Pen( Color.Black )
int PixelIndent
 Each end of the line is indented by this many pixels.
int pixelIndent_ = 0
float LengthScale
 The line length is multiplied by this amount.
float scale_ = 1.0f

Detailed Description

Encapsulates functionality for drawing a vertical line on a plot surface.

Definition at line 62 of file VerticalLine.cs.


Constructor & Destructor Documentation

NPlot::VerticalLine::VerticalLine double  abscissaValue  )  [inline]
 

Constructor.

Parameters:
abscissaValue abscissa (X) value of line.

Definition at line 69 of file VerticalLine.cs.

NPlot::VerticalLine::VerticalLine double  abscissaValue,
Color  color
[inline]
 

Constructor.

Parameters:
abscissaValue abscissa (X) value of line.
color draw the line using this color.

Definition at line 80 of file VerticalLine.cs.

References Pen.

NPlot::VerticalLine::VerticalLine double  abscissaValue,
Pen  pen
[inline]
 

Constructor.

Parameters:
abscissaValue abscissa (X) value of line.
pen Pen to use to draw the line.

Definition at line 92 of file VerticalLine.cs.


Member Function Documentation

void NPlot::VerticalLine::Draw System.Drawing.Graphics  g,
PhysicalAxis  xAxis,
PhysicalAxis  yAxis
[inline]
 

Draws the vertical line plot on a GDI+ surface against the provided x and y axes.

Parameters:
g The GDI+ surface on which to draw.
xAxis The X-Axis to draw against.
yAxis The Y-Axis to draw against.

Definition at line 199 of file VerticalLine.cs.

References AbscissaValue, pen_, NPlot::PhysicalAxis::PhysicalMax, NPlot::PhysicalAxis::PhysicalMin, pixelIndent_, scale_, value_, and NPlot::PhysicalAxis::WorldToPhysical().

void NPlot::VerticalLine::DrawInLegend System.Drawing.Graphics  g,
System.Drawing.Rectangle  startEnd
[inline]
 

Draws a representation of the line in the legend.

Parameters:
g The graphics surface on which to draw.
startEnd A rectangle specifying the bounds of the area in the legend set aside for drawing.

Definition at line 103 of file VerticalLine.cs.

References pen_.

Axis NPlot::VerticalLine::SuggestXAxis  )  [inline]
 

Returns an x-axis that is suitable for drawing this plot.

Returns:
A suitable x-axis.

Implements NPlot::IPlot.

Definition at line 148 of file VerticalLine.cs.

References value_.

Axis NPlot::VerticalLine::SuggestYAxis  )  [inline]
 

Returns null indicating that y extremities of the line are variable.

Returns:
null

Implements NPlot::IPlot.

Definition at line 158 of file VerticalLine.cs.

void NPlot::VerticalLine::WriteData System.Text.StringBuilder  sb,
RectangleD  region,
bool  onlyInRegion
[inline]
 

Writes text data describing the vertical line object to the supplied string builder.

It is possible to specify that the data will be written only if the line is in the specified region.

Parameters:
sb the StringBuilder object to write to.
region a region used if onlyInRegion is true.
onlyInRegion If true, data will be written only if the line is in the specified region.

Implements NPlot::IPlot.

Definition at line 172 of file VerticalLine.cs.

References Label, value_, NPlot::RectangleD::Width, and NPlot::RectangleD::X.


Property Documentation

double NPlot::VerticalLine::AbscissaValue [get, set]
 

abscissa (X) value to draw horizontal line at.

Definition at line 226 of file VerticalLine.cs.

Referenced by Draw(), and NPlot::FilledRegion::Draw().

string NPlot::VerticalLine::Label [get, set]
 

A label to associate with the plot - used in the legend.

Implements NPlot::IPlot.

Definition at line 114 of file VerticalLine.cs.

Referenced by WriteData().

string NPlot::VerticalLine::label_ = "" [private]
 

Definition at line 125 of file VerticalLine.cs.

float NPlot::VerticalLine::LengthScale [get, set]
 

The line length is multiplied by this amount.

Default corresponds to a value of 1.0.

Definition at line 279 of file VerticalLine.cs.

Pen NPlot::VerticalLine::Pen [get, set]
 

Pen to use to draw the horizontal line.

Definition at line 241 of file VerticalLine.cs.

Referenced by VerticalLine().

Pen NPlot::VerticalLine::pen_ = new Pen( Color.Black ) [private]
 

Definition at line 254 of file VerticalLine.cs.

Referenced by Draw(), and DrawInLegend().

int NPlot::VerticalLine::PixelIndent [get, set]
 

Each end of the line is indented by this many pixels.

Definition at line 261 of file VerticalLine.cs.

int NPlot::VerticalLine::pixelIndent_ = 0 [private]
 

Definition at line 271 of file VerticalLine.cs.

Referenced by Draw().

float NPlot::VerticalLine::scale_ = 1.0f [private]
 

Definition at line 289 of file VerticalLine.cs.

Referenced by Draw().

bool NPlot::VerticalLine::ShowInLegend [get, set]
 

Whether or not to include an entry for this plot in the legend if it exists.

Implements NPlot::IPlot.

Definition at line 132 of file VerticalLine.cs.

bool NPlot::VerticalLine::showInLegend_ = false [private]
 

Definition at line 142 of file VerticalLine.cs.

double NPlot::VerticalLine::value_ [private]
 

Definition at line 253 of file VerticalLine.cs.

Referenced by Draw(), SuggestXAxis(), and WriteData().


The documentation for this class was generated from the following file:
Generated on Sat Nov 5 01:04:09 2005 for NPlot by  doxygen 1.4.5