Class HeaderFooterBase
The HeaderFooterBase class implements the base functionality for the header and footer classes used by the Essential Diagram printing system. Header Footer
Implements
Inherited Members
Namespace: Syncfusion.Windows.Forms.Diagram
Assembly: Syncfusion.Diagram.Base.dll
Syntax
public class HeaderFooterBase : ISerializable, ICloneable
Constructors
HeaderFooterBase()
Initializes a new instance of the HeaderFooterBase class.
Declaration
public HeaderFooterBase()
HeaderFooterBase(SerializationInfo, StreamingContext)
Initializes a new instance of the HeaderFooterBase class.
Declaration
public HeaderFooterBase(SerializationInfo info, StreamingContext context)
Parameters
Type | Name | Description |
---|---|---|
System.Runtime.Serialization.SerializationInfo | info | Serialization state information. |
System.Runtime.Serialization.StreamingContext | context | Streaming context information. |
Properties
AutoBounds
Gets or sets a value indicating whether auto layout calculation is enabled for the header and footer.
Declaration
public bool AutoBounds { get; set; }
Property Value
Type |
---|
System.Boolean |
BorderStyle
Gets style options for drawing the header/footer border.
Declaration
public HeaderFooterBorder BorderStyle { get; }
Property Value
Type | Description |
---|---|
HeaderFooterBorder | A HeaderFooterBorder value. |
Bounds
Gets a HFPosition value describing the header or footer bounds.
Declaration
public HFPosition Bounds { get; }
Property Value
Type |
---|
HFPosition |
Center
Gets or sets text describing the center header/footer value.
Declaration
public string Center { get; set; }
Property Value
Type |
---|
System.String |
ComposedCenter
Gets the header/footer center output text.
Declaration
public string ComposedCenter { get; }
Property Value
Type |
---|
System.String |
ComposedLeft
Gets the header/footer left output text.
Declaration
public string ComposedLeft { get; }
Property Value
Type |
---|
System.String |
ComposedRight
Gets the header/footer right output text.
Declaration
public string ComposedRight { get; }
Property Value
Type |
---|
System.String |
Culture
Gets or sets the description culture.
Declaration
public CultureInfo Culture { get; set; }
Property Value
Type | Description |
---|---|
System.Globalization.CultureInfo | The culture. |
CurrentPage
Gets or sets the current page number. Used during printing.
Declaration
public int CurrentPage { get; set; }
Property Value
Type |
---|
System.Int32 |
Font
Gets or sets the font used to draw the text.
Declaration
public Font Font { get; set; }
Property Value
Type |
---|
System.Drawing.Font |
ForeColor
Gets or sets the color value used for the text.
Declaration
public Color ForeColor { get; set; }
Property Value
Type |
---|
System.Drawing.Color |
Image
Gets or sets the image to set as background.
Declaration
public Image Image { get; set; }
Property Value
Type |
---|
System.Drawing.Image |
ImageLayout
Gets or sets a ImageLayout value describing the image layout.
Declaration
public ImageLayout ImageLayout { get; set; }
Property Value
Type |
---|
ImageLayout |
ImagePath
Gets or sets the file path of the background image.
Declaration
public string ImagePath { get; set; }
Property Value
Type |
---|
System.String |
Left
Gets or sets text describing the left header or footer value.
Declaration
public string Left { get; set; }
Property Value
Type |
---|
System.String |
MarginLeft
Gets or sets the position of the left margin.
Declaration
public float MarginLeft { get; set; }
Property Value
Type |
---|
System.Single |
MarginRight
Gets or sets the position of the right margin.
Declaration
public float MarginRight { get; set; }
Property Value
Type |
---|
System.Single |
Right
Gets or sets text describing the right header or footer value.
Declaration
public string Right { get; set; }
Property Value
Type |
---|
System.String |
TotalPages
Gets or sets the total number of pages. Used during printing.
Declaration
public int TotalPages { get; set; }
Property Value
Type |
---|
System.Int32 |
Visible
Gets or sets a value indicating whether the header or footer is visible.
Declaration
public bool Visible { get; set; }
Property Value
Type |
---|
System.Boolean |
Methods
Clone()
Creates a new object that is a copy of the current instance.
Declaration
public object Clone()
Returns
Type | Description |
---|---|
System.Object | A new object that is a copy of this instance. |
GetDefaultValue(String)
Gets the default value.
Declaration
protected object GetDefaultValue(string name)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name. |
Returns
Type | Description |
---|---|
System.Object | The object. |
GetHeight(Graphics, Single, Single, RectangleF)
Gets the height.
Declaration
public virtual float GetHeight(Graphics g, float pagewidth, float pageheight, RectangleF marginBounds)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | The graphics. |
System.Single | pagewidth | The pagewidth. |
System.Single | pageheight | The pageheight. |
System.Drawing.RectangleF | marginBounds | The margin bounds. |
Returns
Type | Description |
---|---|
System.Single | The height. |
GetObjectData(SerializationInfo, StreamingContext)
Populates a System.Runtime.Serialization.SerializationInfo with the data needed to serialize the target object.
Declaration
protected virtual void GetObjectData(SerializationInfo info, StreamingContext context)
Parameters
Type | Name | Description |
---|---|---|
System.Runtime.Serialization.SerializationInfo | info | The System.Runtime.Serialization.SerializationInfo to populate with data. |
System.Runtime.Serialization.StreamingContext | context | The destination (see System.Runtime.Serialization.StreamingContext) for this serialization. |
Exceptions
Type | Condition |
---|---|
System.Security.SecurityException | The caller does not have the required permission. |
ResetBorderStyle()
Reset the border style.
Declaration
protected void ResetBorderStyle()
ResetCenter()
Reset the center header or footer descriptor.
Declaration
protected void ResetCenter()
ResetFont()
Resets the descriptionfont.
Declaration
protected void ResetFont()
ResetForeColor()
Resets the description fore color .
Declaration
protected void ResetForeColor()
ResetImagePath()
Resets the image path.
Declaration
protected void ResetImagePath()
ResetLeft()
Reset the left header/footer descriptor.
Declaration
protected void ResetLeft()
ResetRight()
Resets the right header/footer descriptor.
Declaration
protected void ResetRight()
SafelyGetValue(SerializationInfo, String, Type)
Get value from serialization info without exceptions.
Declaration
protected object SafelyGetValue(SerializationInfo info, string name, Type type)
Parameters
Type | Name | Description |
---|---|---|
System.Runtime.Serialization.SerializationInfo | info | The serialization info. |
System.String | name | The string. |
System.Type | type | The type. |
Returns
Type | Description |
---|---|
System.Object | The object. |
ShouldSerializeBorderStyle()
Check if should to serialize border style.
Declaration
protected bool ShouldSerializeBorderStyle()
Returns
Type | Description |
---|---|
System.Boolean | true, if serialize border style. |
ShouldSerializeCenter()
Check if should the serialize center header or footer descriptor.
Declaration
protected bool ShouldSerializeCenter()
Returns
Type | Description |
---|---|
System.Boolean | true, if serialize center. |
ShouldSerializeFont()
Serialize the description font.
Declaration
protected bool ShouldSerializeFont()
Returns
Type | Description |
---|---|
System.Boolean | true, if serialize font. |
ShouldSerializeForeColor()
Check if should serialize the description fore color.
Declaration
protected bool ShouldSerializeForeColor()
Returns
Type | Description |
---|---|
System.Boolean | true, if serialize forecolor. |
ShouldSerializeImagePath()
Serialize the image path.
Declaration
protected bool ShouldSerializeImagePath()
Returns
Type | Description |
---|---|
System.Boolean | true, if serialize image path. |
ShouldSerializeLeft()
Check if should the serialize left header or footer descriptor.
Declaration
protected bool ShouldSerializeLeft()
Returns
Type | Description |
---|---|
System.Boolean | true, if serialize left |
ShouldSerializeRight()
Serialize the right header and footer descriptor.
Declaration
protected bool ShouldSerializeRight()
Returns
Type | Description |
---|---|
System.Boolean | true, if serialize right. |
Explicit Interface Implementations
ISerializable.GetObjectData(SerializationInfo, StreamingContext)
Populates a System.Runtime.Serialization.SerializationInfo with the data needed to serialize the target object.
Declaration
void ISerializable.GetObjectData(SerializationInfo info, StreamingContext context)
Parameters
Type | Name | Description |
---|---|---|
System.Runtime.Serialization.SerializationInfo | info | The System.Runtime.Serialization.SerializationInfo to populate with data. |
System.Runtime.Serialization.StreamingContext | context | The destination (see System.Runtime.Serialization.StreamingContext) for this serialization. |
Exceptions
Type | Condition |
---|---|
System.Security.SecurityException | The caller does not have the required permission. |