本文整理汇总了C#中ZedGraph.Border类的典型用法代码示例。如果您正苦于以下问题:C# Border类的具体用法?C# Border怎么用?C# Border使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Border类属于ZedGraph命名空间,在下文中一共展示了Border类的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Legend
/// <summary>
/// Default constructor that sets all <see cref="Legend"/> properties to default
/// values as defined in the <see cref="Default"/> class.
/// </summary>
public Legend()
{
_position = Default.Position;
_isHStack = Default.IsHStack;
_isVisible = Default.IsVisible;
this.Location = new Location( 0, 0, CoordType.PaneFraction );
_fontSpec = new FontSpec( Default.FontFamily, Default.FontSize,
Default.FontColor, Default.FontBold,
Default.FontItalic, Default.FontUnderline,
Default.FontFillColor, Default.FontFillBrush,
Default.FontFillType );
_fontSpec.Border.IsVisible = false;
_border = new Border( Default.IsBorderVisible, Default.BorderColor, Default.BorderWidth );
_fill = new Fill( Default.FillColor, Default.FillBrush, Default.FillType );
_gap = Default.Gap;
_isReverse = Default.IsReverse;
_isShowLegendSymbols = Default.IsShowLegendSymbols;
}
示例2: BoxObj
/// <summary>
/// The Copy Constructor
/// </summary>
/// <param name="rhs">The <see cref="BoxObj"/> object from which to copy</param>
public BoxObj( BoxObj rhs ) : base( rhs )
{
this.Border = rhs.Border.Clone();
this.Fill = rhs.Fill.Clone();
}
示例3: Bar
/// <summary>
/// Default constructor that sets the
/// <see cref="Color"/> as specified, and the remaining
/// <see cref="Bar"/> properties to default
/// values as defined in the <see cref="Default"/> class.
/// The specified color is only applied to the
/// <see cref="ZedGraph.Fill.Color"/>, and the <see cref="ZedGraph.Border.Color"/>
/// will be defaulted.
/// </summary>
/// <param name="color">A <see cref="Color"/> value indicating
/// the <see cref="ZedGraph.Fill.Color"/>
/// of the Bar.
/// </param>
public Bar( Color color )
{
this.border = new Border( Default.IsBorderVisible, Default.BorderColor, Default.BorderWidth );
this.fill = new Fill( color.IsEmpty ? Default.FillColor : color,
Default.FillBrush, Default.FillType );
}
示例4: PieItem
/// <summary>
/// Create a new <see cref="PieItem"/>.
/// </summary>
/// <param name="pieValue">The value associated with this <see cref="PieItem"/> instance.</param>
/// <param name="color">The display color for this <see cref="PieItem"/> instance.</param>
/// <param name="displacement">The amount this <see cref="PieItem"/> instance will be
/// displaced from the center point.</param>
/// <param name="label">Text label for this <see cref="PieItem"/> instance.</param>
public PieItem( double pieValue, Color color, double displacement, string label )
: base(label)
{
_pieValue = pieValue;
_fill = new Fill( color.IsEmpty ? _rotator.NextColor : color );
_displacement = displacement;
_border = new Border( Default.BorderColor, Default.BorderWidth );
_labelDetail = new TextObj();
_labelDetail.FontSpec.Size = Default.FontSize;
_labelType = Default.LabelType;
_valueDecimalDigits = Default.ValueDecimalDigits;
_percentDecimalDigits = Default.PercentDecimalDigits;
_slicePath = null;
}
示例5: FontSpec
/// <summary>
/// Constructor for deserializing objects
/// </summary>
/// <param name="info">A <see cref="SerializationInfo"/> instance that defines the serialized data
/// </param>
/// <param name="context">A <see cref="StreamingContext"/> instance that contains the serialized data
/// </param>
protected FontSpec( SerializationInfo info, StreamingContext context )
{
// The schema value is just a file version parameter. You can use it to make future versions
// backwards compatible as new member variables are added to classes
int sch = info.GetInt32( "schema" );
_fontColor = (Color)info.GetValue( "fontColor", typeof( Color ) );
_family = info.GetString( "family" );
_isBold = info.GetBoolean( "isBold" );
_isItalic = info.GetBoolean( "isItalic" );
_isUnderline = info.GetBoolean( "isUnderline" );
_isAntiAlias = info.GetBoolean( "isAntiAlias" );
_fill = (Fill)info.GetValue( "fill", typeof( Fill ) );
_border = (Border)info.GetValue( "border", typeof( Border ) );
_angle = info.GetSingle( "angle" );
_stringAlignment = (StringAlignment)info.GetValue( "stringAlignment", typeof( StringAlignment ) );
_size = info.GetSingle( "size" );
_isDropShadow = info.GetBoolean( "isDropShadow" );
_dropShadowColor = (Color)info.GetValue( "dropShadowColor", typeof( Color ) );
_dropShadowAngle = info.GetSingle( "dropShadowAngle" );
_dropShadowOffset = info.GetSingle( "dropShadowOffset" );
_scaleFactor = info.GetSingle("scaleFactor");
_scaledSize = -1;
Remake( 1.0F, _size, ref _scaledSize, ref _font );
}
示例6: Symbol
/// <summary>
/// Default constructor that sets the <see cref="SymbolType"/> and
/// <see cref="Color"/> as specified, and the remaining
/// <see cref="Symbol"/> properties to default
/// values as defined in the <see cref="Default"/> class.
/// </summary>
/// <param name="type">A <see cref="SymbolType"/> enum value
/// indicating the shape of the symbol</param>
/// <param name="color">A <see cref="Color"/> value indicating
/// the color of the symbol
/// </param>
public Symbol( SymbolType type, Color color )
{
_size = Default.Size;
_type = type;
_isAntiAlias = Default.IsAntiAlias;
_isVisible = Default.IsVisible;
_border = new Border( Default.IsBorderVisible, color, Default.PenWidth );
_fill = new Fill( color, Default.FillBrush, Default.FillType );
_userSymbol = null;
}
示例7: Init
private void Init( string family, float size, Color color, bool isBold,
bool isItalic, bool isUnderline, Color fillColor, Brush fillBrush,
FillType fillType )
{
_fontColor = color;
_family = family;
_isBold = isBold;
_isItalic = isItalic;
_isUnderline = isUnderline;
_size = size;
_angle = 0F;
_isAntiAlias = Default.IsAntiAlias;
_stringAlignment = Default.StringAlignment;
_isDropShadow = Default.IsDropShadow;
_dropShadowColor = Default.DropShadowColor;
_dropShadowAngle = Default.DropShadowAngle;
_dropShadowOffset = Default.DropShadowOffset;
_scaleFactor = Default.ScaleFactor;
_fill = new Fill( fillColor, fillBrush, fillType );
_border = new Border( true, Color.Black, 1.0F );
_scaledSize = -1;
Remake( 1.0F, _size, ref _scaledSize, ref _font );
}
示例8: CreateGraph_Clone
private void CreateGraph_Clone( ZedGraphControl z1 )
{
MasterPane master = z1.MasterPane;
Border myBorder = new Border();
myBorder.IsVisible = false;
master.Border = myBorder;
master.PaneList.Clear();
master.Title.Text = "First try";
master.Margin.All = 10;
master.InnerPaneGap = 10;
// Enable the master pane legend
master.Legend.IsVisible = true;
master.Legend.Position = ZedGraph.LegendPos.TopCenter;
GraphPane[] myPane = new GraphPane[3];
for ( int j = 0; j < 3; j++ )
{
if ( j < 2 )
myPane[j] = new GraphPane( new RectangleF( 40, 40, 150, 100 ), "", "", "" );
else
myPane[j] = new GraphPane( new RectangleF( 40, 40, 300, 100 ), "", "", "" );
myPane[j].Fill = new Fill( Color.BlanchedAlmond );
// myPane(j).AxisFill = New ZedGraph.Fill(Color.SeaGreen)
myPane[j].BaseDimension = 6.0F;
myPane[j].XAxis.Title.IsVisible = true;
myPane[j].XAxis.Scale.IsVisible = true;
myPane[j].Legend.IsVisible = false;
myPane[j].Border.IsVisible = false;
myPane[j].Title.IsVisible = true;
myPane[j].Margin.All = 0;
// This sets the minimum amount of space for the left and right side, respectively
// The reason for this is so that the AxisRects all end up being the same size.
myPane[j].YAxis.MinSpace = 50;
myPane[j].Y2Axis.MinSpace = 20;
master.Add( myPane[j] );
}
using ( Graphics g = CreateGraphics() )
master.SetLayout( g, PaneLayout.ExplicitCol21 );
//Call GetMonthlist()
//myPane[0] = zgHistogram.GraphPane.Clone;
//myPane[1] = zgProbability.GraphPane.Clone;
//myPane[2] = zgTimeSeries.GraphPane.Clone;
// instead of
// Call CreateGraph_TimeSeries(zgM, myPane(2))
// Call CreateGraph_Probability(zgM, myPane(1))
// Call CreateGraph_Histogram(zgM, myPane(0))
z1.AxisChange();
z1.Refresh();
}
示例9: GasGaugeNeedle
/// <summary>
/// The Copy Constructor
/// </summary>
/// <param name="ggn">The <see cref="GasGaugeNeedle"/> object from which to copy</param>
public GasGaugeNeedle(GasGaugeNeedle ggn)
: base(ggn)
{
NeedleValue = ggn.NeedleValue;
NeedleColor = ggn.NeedleColor;
NeedleWidth = ggn.NeedleWidth;
SweepAngle = ggn.SweepAngle;
_border = ggn.Border.Clone();
_labelDetail = ggn.LabelDetail.Clone();
_labelDetail.FontSpec.Size = ggn.LabelDetail.FontSpec.Size;
}
示例10: GasGaugeRegion
/// <summary>
/// Create a new <see cref="GasGaugeRegion"/>
/// </summary>
/// <param name="label">The value associated with this <see cref="GasGaugeRegion"/> instance.</param>
/// <param name="color">The display color for this <see cref="GasGaugeRegion"/> instance.</param>
/// <param name="minVal">The minimum value of this <see cref="GasGaugeNeedle"/>.</param>
/// <param name="maxVal">The maximum value of this <see cref="GasGaugeNeedle"/>.</param>
public GasGaugeRegion(string label, double minVal, double maxVal, Color color)
: base(label)
{
MinValue = minVal;
MaxValue = maxVal;
RegionColor = color;
StartAngle = 0f;
SweepAngle = 0f;
_border = new Border(Default.BorderColor, Default.BorderWidth);
_labelDetail = new TextObj();
_labelDetail.FontSpec.Size = Default.FontSize;
_slicePath = null;
}
示例11: Bar
/// <summary>
/// The Copy Constructor
/// </summary>
/// <param name="rhs">The Bar object from which to copy</param>
public Bar(Bar rhs)
{
_border = rhs.Border.Clone();
_fill = rhs.Fill.Clone();
}
示例12: Border
/// <summary>
/// The Copy Constructor
/// </summary>
/// <param name="rhs">The Border object from which to copy</param>
public Border( Border rhs )
: base(rhs)
{
_inflateFactor = rhs._inflateFactor;
}
示例13: Chart
/// <summary>
/// Copy constructor
/// </summary>
/// <param name="rhs">The source <see cref="Chart" /> to be copied.</param>
public Chart( Chart rhs )
{
_border = rhs._border.Clone();
_fill = rhs._fill.Clone();
_rect = rhs._rect;
_isRectAuto = rhs._isRectAuto;
}
示例14: PaneBase
/// <summary>
/// The Copy Constructor
/// </summary>
/// <param name="rhs">The <see cref="PaneBase"/> object from which to copy</param>
public PaneBase( PaneBase rhs )
{
// copy over all the value types
_isFontsScaled = rhs._isFontsScaled;
_isPenWidthScaled = rhs._isPenWidthScaled;
_titleGap = rhs._titleGap;
_baseDimension = rhs._baseDimension;
_margin = rhs._margin.Clone();
_rect = rhs._rect;
// Copy the reference types by cloning
_fill = rhs._fill.Clone();
_border = rhs._border.Clone();
_title = rhs._title.Clone();
_legend = rhs.Legend.Clone();
_title = rhs._title.Clone();
_graphObjList = rhs._graphObjList.Clone();
if ( rhs._tag is ICloneable )
_tag = ((ICloneable) rhs._tag).Clone();
else
_tag = rhs._tag;
}