Class PdfXfaRadialBrush
Represents the XFA Radial brush
Inherited Members
      System.Object.Equals(System.Object)
    
      System.Object.Equals(System.Object, System.Object)
    
      System.Object.GetHashCode()
    
      System.Object.GetType()
    
      System.Object.MemberwiseClone()
    
      System.Object.ReferenceEquals(System.Object, System.Object)
    
      System.Object.ToString()
    
Namespace: Syncfusion.Pdf.Xfa
Assembly: Syncfusion.Pdf.Base.dll
Syntax
public class PdfXfaRadialBrush : PdfXfaBrush
  Examples
//Create a new PDF XFA document.
PdfXfaDocument document = new PdfXfaDocument();
//Create a form.
PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595);
parentForm.Margins.All = 10;
//Create new XFA rectangle instance.
PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100));
//Create new XFA brush.
PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow);
//Set the start color.
brush.StartColor = Color.Black;
//Set the end color.
brush.EndColor = Color.HotPink;
//Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge;
//Set the linear brush
rect.Border.FillColor = brush;
//Add the field to form.
parentForm.Fields.Add(rect);            
document.XfaForm = parentForm;
//Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic);
//Close the document
document.Close(); 
'Create a new PDF XFA document.
Dim document As New PdfXfaDocument()
'Create a form.
Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595)
parentForm.Margins.All = 10
'Create new XFA rectangle instance.
Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100))
'Create new XFA brush.
Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow)
'Set the start color.
brush.StartColor = Color.Black
'Set the end color.
brush.EndColor = Color.HotPink
'Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge
'Set the linear brush
rect.Border.FillColor = brush
'Add the field to form.
parentForm.Fields.Add(rect)
document.XfaForm = parentForm
'Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic)
'Close the document
document.Close()
  Constructors
PdfXfaRadialBrush(PdfColor, PdfColor)
initialize the new instance of the PdfXfaRadialBrush class.
Declaration
public PdfXfaRadialBrush(PdfColor startColor, PdfColor endColor)
  Parameters
| Type | Name | Description | 
|---|---|---|
| PdfColor | startColor | The start color of the radial brush.  | 
      
| PdfColor | endColor | The end color of the radial brush.  | 
      
Examples
//Create a new PDF XFA document.
PdfXfaDocument document = new PdfXfaDocument();
//Create a form.
PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595);
parentForm.Margins.All = 10;
//Create new XFA rectangle instance.
PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100));
//Create new XFA brush.
PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow);
//Set the start color.
brush.StartColor = Color.Black;
//Set the end color.
brush.EndColor = Color.HotPink;
//Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge;
//Set the linear brush
rect.Border.FillColor = brush;
//Add the field to form.
parentForm.Fields.Add(rect);            
document.XfaForm = parentForm;
//Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic);
//Close the document
document.Close(); 
'Create a new PDF XFA document.
Dim document As New PdfXfaDocument()
'Create a form.
Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595)
parentForm.Margins.All = 10
'Create new XFA rectangle instance.
Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100))
'Create new XFA brush.
Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow)
'Set the start color.
brush.StartColor = Color.Black
'Set the end color.
brush.EndColor = Color.HotPink
'Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge
'Set the linear brush
rect.Border.FillColor = brush
'Add the field to form.
parentForm.Fields.Add(rect)
document.XfaForm = parentForm
'Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic)
'Close the document
document.Close()
  
  
  
  PdfXfaRadialBrush(PdfColor, PdfColor, PdfXfaRadialType)
initialize the new instance of the PdfXfaRadialBrush class.
Declaration
public PdfXfaRadialBrush(PdfColor startColor, PdfColor endColor, PdfXfaRadialType type)
  Parameters
| Type | Name | Description | 
|---|---|---|
| PdfColor | startColor | The start color of the radial brush.  | 
      
| PdfColor | endColor | The end color of the radial brush.  | 
      
| PdfXfaRadialType | type | The radial type.  | 
      
Examples
//Create a new PDF XFA document.
PdfXfaDocument document = new PdfXfaDocument();
//Create a form.
PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595);
parentForm.Margins.All = 10;
//Create new XFA rectangle instance.
PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100));
//Create new XFA brush.
PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow, PdfXfaRadialType.CenterToEdge);
//Set the start color.
brush.StartColor = Color.Black;
//Set the end color.
brush.EndColor = Color.HotPink;      
//Set the linear brush
rect.Border.FillColor = brush;
//Add the field to form.
parentForm.Fields.Add(rect);            
document.XfaForm = parentForm;
//Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic);
//Close the document
document.Close(); 
'Create a new PDF XFA document.
Dim document As New PdfXfaDocument()
'Create a form.
Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595)
parentForm.Margins.All = 10
'Create new XFA rectangle instance.
Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100))
'Create new XFA brush.
Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow, PdfXfaRadialType.CenterToEdge)
'Set the start color.
brush.StartColor = Color.Black
'Set the end color.
brush.EndColor = Color.HotPink     
'Set the linear brush
rect.Border.FillColor = brush
'Add the field to form.
parentForm.Fields.Add(rect)
document.XfaForm = parentForm
'Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic)
'Close the document
document.Close()
  Properties
EndColor
Gets or sets the ending color
Declaration
public PdfColor EndColor { get; set; }
  Property Value
| Type | 
|---|
| PdfColor | 
Examples
//Create a new PDF XFA document.
PdfXfaDocument document = new PdfXfaDocument();
//Create a form.
PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595);
parentForm.Margins.All = 10;
//Create new XFA rectangle instance.
PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100));
//Create new XFA brush.
PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow);
//Set the start color.
brush.StartColor = Color.Black;
//Set the end color.
brush.EndColor = Color.HotPink;
//Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge;
//Set the linear brush
rect.Border.FillColor = brush;
//Add the field to form.
parentForm.Fields.Add(rect);            
document.XfaForm = parentForm;
//Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic);
//Close the document
document.Close(); 
'Create a new PDF XFA document.
Dim document As New PdfXfaDocument()
'Create a form.
Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595)
parentForm.Margins.All = 10
'Create new XFA rectangle instance.
Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100))
'Create new XFA brush.
Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow)
'Set the start color.
brush.StartColor = Color.Black
'Set the end color.
brush.EndColor = Color.HotPink
'Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge
'Set the linear brush
rect.Border.FillColor = brush
'Add the field to form.
parentForm.Fields.Add(rect)
document.XfaForm = parentForm
'Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic)
'Close the document
document.Close()
  
  
  
  StartColor
Gets or sets the starting color
Declaration
public PdfColor StartColor { get; set; }
  Property Value
| Type | 
|---|
| PdfColor | 
Examples
//Create a new PDF XFA document.
PdfXfaDocument document = new PdfXfaDocument();
//Create a form.
PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595);
parentForm.Margins.All = 10;
//Create new XFA rectangle instance.
PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100));
//Create new XFA brush.
PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow);
//Set the start color.
brush.StartColor = Color.Black;
//Set the end color.
brush.EndColor = Color.HotPink;
//Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge;
//Set the linear brush
rect.Border.FillColor = brush;
//Add the field to form.
parentForm.Fields.Add(rect);            
document.XfaForm = parentForm;
//Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic);
//Close the document
document.Close(); 
'Create a new PDF XFA document.
Dim document As New PdfXfaDocument()
'Create a form.
Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595)
parentForm.Margins.All = 10
'Create new XFA rectangle instance.
Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100))
'Create new XFA brush.
Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow)
'Set the start color.
brush.StartColor = Color.Black
'Set the end color.
brush.EndColor = Color.HotPink
'Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge
'Set the linear brush
rect.Border.FillColor = brush
'Add the field to form.
parentForm.Fields.Add(rect)
document.XfaForm = parentForm
'Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic)
'Close the document
document.Close()
  
  
  
  Type
Gets or set the direction of the color transition
Declaration
public PdfXfaRadialType Type { get; set; }
  Property Value
| Type | 
|---|
| PdfXfaRadialType | 
Examples
//Create a new PDF XFA document.
PdfXfaDocument document = new PdfXfaDocument();
//Create a form.
PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595);
parentForm.Margins.All = 10;
//Create new XFA rectangle instance.
PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100));
//Create new XFA brush.
PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow);
//Set the start color.
brush.StartColor = Color.Black;
//Set the end color.
brush.EndColor = Color.HotPink;
//Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge;
//Set the linear brush
rect.Border.FillColor = brush;
//Add the field to form.
parentForm.Fields.Add(rect);            
document.XfaForm = parentForm;
//Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic);
//Close the document
document.Close(); 
'Create a new PDF XFA document.
Dim document As New PdfXfaDocument()
'Create a form.
Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595)
parentForm.Margins.All = 10
'Create new XFA rectangle instance.
Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100))
'Create new XFA brush.
Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow)
'Set the start color.
brush.StartColor = Color.Black
'Set the end color.
brush.EndColor = Color.HotPink
'Set the type.
brush.Type = PdfXfaRadialType.CenterToEdge
'Set the linear brush
rect.Border.FillColor = brush
'Add the field to form.
parentForm.Fields.Add(rect)
document.XfaForm = parentForm
'Save the document.
document.Save("output.pdf", PdfXfaType.Dynamic)
'Close the document
document.Close()