Class PdfViewerShapeLabelSettings
Represents the settings for shape label customization in the PDF viewer component.
Inheritance
Inherited Members
Namespace: Syncfusion.Blazor.SfPdfViewer
Assembly: Syncfusion.Blazor.SfPdfViewer.dll
Syntax
public class PdfViewerShapeLabelSettings : SfBaseComponent, IComponent, IHandleEvent, IHandleAfterRender, IDisposable
Remarks
This class handles the configuration of properties related to the appearance and behavior of labels for shapes in the PDF Viewer, such as font color, font family, label content, and opacity.
Examples
Below is an example of how to configure PdfViewerShapeLabelSettings in a Blazor component:
Constructors
PdfViewerShapeLabelSettings()
Declaration
public PdfViewerShapeLabelSettings()
Properties
ChildContent
Gets or sets the child content to be rendered inside the shape label settings component.
Declaration
[Parameter]
[JsonIgnore]
public RenderFragment ChildContent { get; set; }
Property Value
| Type |
|---|
| RenderFragment |
FillColor
specifies the fill color of the label.
Declaration
[Parameter]
[JsonPropertyName("fillColor")]
public string FillColor { get; set; }
Property Value
| Type |
|---|
| string |
FontColor
specifies the border color of the label.
Declaration
[Parameter]
[JsonPropertyName("fontColor")]
public string FontColor { get; set; }
Property Value
| Type |
|---|
| string |
FontFamily
specifies the max-width of the label.
Declaration
[Parameter]
[JsonPropertyName("fontFamily")]
public string FontFamily { get; set; }
Property Value
| Type |
|---|
| string |
FontSize
specifies the font size of the label.
Declaration
[Parameter]
[JsonPropertyName("fontSize")]
public int FontSize { get; set; }
Property Value
| Type |
|---|
| int |
LabelContent
specifies the default content of the label.
Declaration
[Parameter]
[JsonPropertyName("labelContent")]
public string LabelContent { get; set; }
Property Value
| Type |
|---|
| string |
Notes
specifies the default content of the label.
Declaration
[Parameter]
[JsonPropertyName("notes")]
public string Notes { get; set; }
Property Value
| Type |
|---|
| string |
Opacity
specifies the opacity of the label.
Declaration
[Parameter]
[JsonPropertyName("opacity")]
public double Opacity { get; set; }
Property Value
| Type |
|---|
| double |
jsProperty
The JS interop property name used internally.
Declaration
protected string jsProperty { get; set; }
Property Value
| Type |
|---|
| string |
mainParent
Reference to the parent base component in the hierarchy.
Declaration
protected SfBaseComponent mainParent { get; set; }
Property Value
| Type |
|---|
| SfBaseComponent |
Methods
BuildRenderTree(RenderTreeBuilder)
Declaration
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
| Type | Name | Description |
|---|---|---|
| RenderTreeBuilder | __builder |
Overrides
OnInitializedAsync()
Performs asynchronous initialization for the component and registers settings with the parent viewer. Initializes backing fields from the current parameter values.
Declaration
protected override Task OnInitializedAsync()
Returns
| Type | Description |
|---|---|
| Task | A task that represents the asynchronous initialization operation. |
Overrides
OnParametersSetAsync()
Applies parameter changes and updates child properties when needed. Synchronizes backing fields and notifies property changes.
Declaration
protected override Task OnParametersSetAsync()
Returns
| Type | Description |
|---|---|
| Task | A task that represents the asynchronous parameter-set operation. |