Moved file from gitlab to github
|
@ -0,0 +1,3 @@
|
|||
WindowsForms-coverTemplate.docx
|
||||
WindowsForms-logFile.txt
|
||||
~$verTemplate.docx
|
|
@ -0,0 +1,141 @@
|
|||
---
|
||||
layout: post
|
||||
title: Array and Table Formulas in Essential Calculate
|
||||
description: Explains about the support of array and table formulas in Essential Calculate
|
||||
platform: windowsforms
|
||||
control: Calculate
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Array and Table Formulas
|
||||
|
||||
This section explains about the Array and Table formulas support in Essential Calculate
|
||||
|
||||
## Array Formulas
|
||||
|
||||
Array formula contains two or more range of values. These array arguments can be cell ranges or array constants.
|
||||
|
||||
For Example:
|
||||
|
||||
The SUM formula "=SUM(C2 * D2,C3 * D3,C4 * D4,C5 * D5,C6 * D6,C7 * D7,C8 * D8,C9 * D9,C10 * D10,C11 * D11)" can be written simply in
|
||||
Array formula as "{SUM(C2:C11 * D2:D11)}".
|
||||
|
||||
Each argument must have the same number of cell ranges. The formulas will be defined within {} braces. A series of data will be returned from the array formula.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
CalcData calcData = new CalcData();
|
||||
|
||||
calcData.SetValueRowCol(10, 1, 1);
|
||||
calcData.SetValueRowCol(20, 2, 1);
|
||||
calcData.SetValueRowCol(30, 3, 1);
|
||||
calcData.SetValueRowCol(40, 4, 1);
|
||||
|
||||
calcData.SetValueRowCol(2, 1, 2);
|
||||
calcData.SetValueRowCol(3, 2, 2);
|
||||
calcData.SetValueRowCol(4, 3, 2);
|
||||
calcData.SetValueRowCol(5, 4, 2);
|
||||
|
||||
CalcEngine engine = new CalcEngine(calcData);
|
||||
|
||||
string formula = "{=SUM(A1:A4*B1:B4)}";
|
||||
|
||||
string result = engine.ParseAndComputeFormula(formula);
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
### Array constants
|
||||
|
||||
Array constants are a component of array formula.A bunch of values or constants which are associated within {} braces.
|
||||
Array constants can contain numbers, text, logical values or error strings.
|
||||
|
||||
For Example:
|
||||
= { 3, 6, 80; 5, TRUE, FALSE }
|
||||
|
||||
Cell references cannot be included in array constants. Also, equal range of row values should be included. If you separate the items by using commas, you create
|
||||
a horizontal array (a row). If you separate the items by using semicolons, you create a vertical array (a column). To create a two-dimensional array, you delimit
|
||||
the items in each row by using commas and delimit each row by using semicolons.
|
||||
|
||||
For Example:
|
||||
|
||||
Single row: {1,2,3,4}
|
||||
Single column: {1;2;3;4}
|
||||
Array of two rows and four columns: {1,2,3,4;5,6,7,8}
|
||||
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
calcData.SetValueRowCol(10, 1, 1);
|
||||
calcData.SetValueRowCol(20, 2, 1);
|
||||
calcData.SetValueRowCol(30, 3, 1);
|
||||
calcData.SetValueRowCol(40, 4, 1);
|
||||
CalcEngine engine = new CalcEngine(calcData);
|
||||
|
||||
string formula = "MIN(A1:A4, {1,2,3})";
|
||||
|
||||
string result = engine.ParseAndComputeFormula(formula);
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
## Table Formulas
|
||||
|
||||
A table is a collection of data about a specific topic that is stored in rows and columns. These tables are defined with a name and `CalcEngine` supports these table format.
|
||||
|
||||
For Example: =SUM(Table1[[#All],[Column1]:[Column2]])
|
||||
|
||||
A table needs to be defined with the following protocols,
|
||||
|
||||
* All table, column, and special item specifiers must be enclosed in matching brackets [ ]
|
||||
* Expression cannot be used with these brackets. Column headers should be a text strings.
|
||||
* The special characters such as comma ,, colon :, period ., left bracket [ , right bracket ], pound sign #, single quotation mark ', double quotation mark ",
|
||||
left brace {, right brace }, dollar sign $, caret ^, ampersand &, asterisk *, plus sign +, equal sign =, minus sign -, greater than symbol >, less than symbol <, and division sign / can be used.
|
||||
|
||||
These table are converted into cell ranges and then it will be evaluated. The data from one row can also be taken with this table structure.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
//Creates a new instance for ExcelEngine,
|
||||
|
||||
ExcelEngine excelEngine = new ExcelEngine();
|
||||
|
||||
//Loads or open an existing workbook through Open method of IWorkbook,
|
||||
|
||||
IWorkbook workbook = excelEngine.Excel.Workbooks.Open(@"..\..\Data\Sample.xlsx");
|
||||
|
||||
//Accessing the worksheet,
|
||||
IWorksheet sheet = workbook.Worksheets[0];
|
||||
|
||||
//Formula calculation is enabled for the sheet,
|
||||
sheet.EnableSheetCalculations();
|
||||
|
||||
//Create Table,
|
||||
IListObject table1 = sheet.ListObjects.Create("Table1", sheet["A1:F6"]);
|
||||
|
||||
// Fill table data
|
||||
sheet[1, 1].Text = "Column1";
|
||||
sheet[1, 2].Text = "Column2";
|
||||
sheet[1, 3].Text = "Column3";
|
||||
|
||||
sheet[2, 1].Number = 3;
|
||||
sheet[2, 2].Number = 2;
|
||||
sheet[2, 3].Number = 16.80;
|
||||
|
||||
sheet[3, 1].Number = 5;
|
||||
sheet[3, 2].Number = 3;
|
||||
sheet[3, 3].Number = 15.60;
|
||||
|
||||
sheet[4, 1].Number = 8;
|
||||
sheet[4, 2].Number = 2;
|
||||
sheet[4, 3].Number = 20.10;
|
||||
|
||||
string result1 = sheet.CalcEngine.ParseAndComputeFormula("=SUM(Table1[Column1])");
|
||||
|
||||
string result2 = sheet.CalcEngine.ParseAndComputeFormula("=MIN(Table1[#All])");
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
|
@ -0,0 +1,87 @@
|
|||
node('content')
|
||||
{
|
||||
timestamps
|
||||
{
|
||||
|
||||
def Content="";
|
||||
env.PATH = "${ProgramFiles}"+"\\Git\\mingw64\\bin;${env.PATH}"
|
||||
|
||||
timeout(time: 7200000, unit: 'MILLISECONDS') {
|
||||
String platform='Windows Forms';
|
||||
try
|
||||
{
|
||||
//Clone scm repository in Workspace source directory
|
||||
stage ('Checkout')
|
||||
{
|
||||
dir('Spell-Checker')
|
||||
{
|
||||
checkout scm
|
||||
|
||||
def branchCommit = '"' + 'https://gitlab.syncfusion.com/api/v4/projects/' + env.projectId + '/merge_requests/' + env.MergeRequestId + '/changes'
|
||||
String branchCommitDetails = bat returnStdout: true, script: 'curl -s --request GET --header PRIVATE-TOKEN:' + env.BuildAutomation_PrivateToken + " " + branchCommit
|
||||
|
||||
def ChangeFiles= branchCommitDetails.split('\n')[2];
|
||||
ChangeFiles = ChangeFiles.split('"new_path":')
|
||||
|
||||
for (int i= 1; i < ChangeFiles.size();i++)
|
||||
{
|
||||
def ChangeFile= ChangeFiles[i].split(',')[0].replace('"', '')
|
||||
Content += env.WORKSPACE + "\\Spell-Checker\\" + ChangeFile + "\r\n";
|
||||
}
|
||||
|
||||
if (Content) {
|
||||
writeFile file: env.WORKSPACE+"/cireports/content.txt", text: Content
|
||||
}
|
||||
else {
|
||||
writeFile file: env.WORKSPACE+"/cireports/content.txt", text: "There are no filepaths found for this commit."
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//Checkout the ug_spellchecker from development Source
|
||||
checkout([$class: 'GitSCM', branches: [[name: '*/development']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'RelativeTargetDirectory', relativeTargetDir: 'ug_spellchecker']], submoduleCfg: [], userRemoteConfigs: [[credentialsId: env.gitlabCredentialId, url: 'https://gitlab.syncfusion.com/content/ug_spellchecker.git']]])
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
catch(Exception e)
|
||||
{
|
||||
currentBuild.result = 'FAILURE'
|
||||
}
|
||||
|
||||
if(currentBuild.result != 'FAILURE')
|
||||
{
|
||||
stage 'Build Source'
|
||||
try
|
||||
{
|
||||
gitlabCommitStatus("Build")
|
||||
{
|
||||
bat 'powershell.exe -ExecutionPolicy ByPass -File '+env.WORKSPACE+"/ug_spellchecker/build.ps1 -Script "+env.WORKSPACE+"/ug_spellchecker/build.cake -Target build -Platform \""+platform+"\" -Targetbranch "+env.gitlabTargetBranch+" -Branch "+'"'+env.gitlabSourceBranch+'"'
|
||||
}
|
||||
|
||||
def files = findFiles(glob: '**/cireports/errorlogs/*.txt')
|
||||
|
||||
if(files.size() > 0)
|
||||
{
|
||||
currentBuild.result = 'FAILURE'
|
||||
}
|
||||
|
||||
}
|
||||
catch(Exception e)
|
||||
{
|
||||
currentBuild.result = 'FAILURE'
|
||||
}
|
||||
}
|
||||
|
||||
stage 'Delete Workspace'
|
||||
|
||||
def files = findFiles(glob: '**/cireports/spellcheck/*.*')
|
||||
|
||||
if(files.size() > 0)
|
||||
{
|
||||
archiveArtifacts artifacts: 'cireports/', excludes: null
|
||||
}
|
||||
step([$class: 'WsCleanup']) }
|
||||
}
|
||||
}
|
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/AddSyncfusionControls_img1.jpeg
Normal file
После Ширина: | Высота: | Размер: 7.3 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/AddSyncfusionControls_img2.jpeg
Normal file
После Ширина: | Высота: | Размер: 4.5 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/AddSyncfusionControls_img3.jpeg
Normal file
После Ширина: | Высота: | Размер: 4.7 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Add-New-Item-1.png
Normal file
После Ширина: | Высота: | Размер: 48 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Add-New-Item-2.png
Normal file
После Ширина: | Высота: | Размер: 55 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Add-New-Item-3.png
Normal file
После Ширина: | Высота: | Размер: 19 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Add-New-Item-4.png
Normal file
После Ширина: | Высота: | Размер: 6.8 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Item-Template-Gallery-1.png
Normal file
После Ширина: | Высота: | Размер: 27 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Item-Template-Gallery-2.png
Normal file
После Ширина: | Высота: | Размер: 33 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Item-Template-Gallery-3.png
Normal file
После Ширина: | Высота: | Размер: 4.6 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Item-Template-Gallery-4.png
Normal file
После Ширина: | Высота: | Размер: 1.6 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Item-Template-Gallery-5.png
Normal file
После Ширина: | Высота: | Размер: 15 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-1.png
Normal file
После Ширина: | Высота: | Размер: 46 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-2.png
Normal file
После Ширина: | Высота: | Размер: 31 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-3.png
Normal file
После Ширина: | Высота: | Размер: 5.4 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-4.png
Normal file
После Ширина: | Высота: | Размер: 2.9 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-5.png
Normal file
После Ширина: | Высота: | Размер: 25 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-6.png
Normal file
После Ширина: | Высота: | Размер: 10 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-7.png
Normal file
После Ширина: | Высота: | Размер: 14 KiB |
Двоичные данные
WindowsForms/Add-Syncfusion-Control_images/Syncfusion-Project-Template-Gallery-8.png
Normal file
После Ширина: | Высота: | Размер: 12 KiB |
После Ширина: | Высота: | Размер: 15 KiB |
После Ширина: | Высота: | Размер: 40 KiB |
|
@ -0,0 +1,217 @@
|
|||
---
|
||||
layout: post
|
||||
title: Steps to add Syncfusion Essential Windows Forms controls
|
||||
description: Steps to Add syncfusion controls
|
||||
platform: windowsforms
|
||||
control: Introduction
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Add Syncfusion Controls
|
||||
|
||||
The Syncfusion Windows Forms controls can be added in a Visual Studio projects by using either of the following ways,
|
||||
|
||||
* Through Designer
|
||||
* Through Code-Behind
|
||||
* Through Project Template
|
||||
* Through Item Template
|
||||
|
||||
## Through Designer
|
||||
|
||||
Syncfusion UI for Windows Forms are added automatically to the Visual Studio Toolbox during installation. The following steps helps to add required Essential Windows Forms control through drag and drop from Toolbox. For example: **TextBoxExt**
|
||||
|
||||
1.Create a Windows Forms project in Visual Studio.
|
||||
|
||||
2.Find **TextBoxExt** by typing the name of the “TextBoxExt” in the search box.
|
||||
|
||||
![](Add-Syncfusion-Control_images/AddSyncfusionControls_img1.jpeg)
|
||||
|
||||
3.Drag **TextBoxExt** and drop it in the designer.
|
||||
|
||||
![](Add-Syncfusion-Control_images/AddSyncfusionControls_img2.jpeg)
|
||||
|
||||
## Through Code-Behind
|
||||
|
||||
Syncfusion UI for Windows Forms can added at runtime using C# / VB. The following steps helps to add required Essential Windows Forms control through code. For example: **TextBoxExt**.
|
||||
|
||||
1.Create a Windows Forms project in Visual Studio and refer to the following assemblies.
|
||||
|
||||
* Syncfusion.Tools.Base.dll
|
||||
* Syncfusion.Tools.Windows.dll
|
||||
* Syncfusion.Shared.Base.dll
|
||||
* Syncfusion.Shared.Windows.dll
|
||||
|
||||
2.Create an instance of **TextBoxExt** using it namespace
|
||||
|
||||
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
Syncfusion.Windows.Forms.Tools.TextBoxExt textBoxExt1 = new Syncfusion.Windows.Forms.Tools.TextBoxExt();
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
Dim textBoxExt1 As New Syncfusion.Windows.Forms.Tools.TextBoxExt()
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
3.Set Location and Size of the control with require value. Here, set its location as (100,100) and Size as (200,25) through its `Location` and ‘Size’ property respectively.
|
||||
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
this.textBoxExt1.Location = new System.Drawing.Point(100, 100);
|
||||
|
||||
this.textBoxExt1.Size = new System.Drawing.Size(200, 25);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
Me.textBoxExt1.Location = New System.Drawing.Point(100, 100)
|
||||
|
||||
Me.textBoxExt1.Size = New System.Drawing.Size(200, 25)
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
4.Add the created instance to the parent form (or the needed layout panels) through its child collection property that named as `Controls`.
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
//here this denotes parent main form
|
||||
|
||||
this.Controls.Add(this.textBoxExt1);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
'here this denotes parent main form
|
||||
|
||||
Me.Controls.Add(Me.textBoxExt1)
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
![](Add-Syncfusion-Control_images/AddSyncfusionControls_img3.jpeg)
|
||||
|
||||
## Through Project Template
|
||||
|
||||
Syncfusion provides the Visual Studio Project Templates for the Syncfusion Windows Forms platform to create Syncfusion Windows Forms Application.
|
||||
|
||||
I> The Syncfusion Windows Forms templates are available from v14.3.0.49.
|
||||
|
||||
### Create Syncfusion Windows Forms Project
|
||||
|
||||
The following steps direct you to create the Syncfusion Windows Forms project through the Visual Studio Project Template.
|
||||
|
||||
1. To create a Syncfusion Windows Forms project, choose New Project-> Syncfusion->Windows->Syncfusion Windows Forms Application from Visual Studio
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-1.png)
|
||||
|
||||
2. Name the Project, choose the destination location when required and set the Framework of the project, then click OK.
|
||||
|
||||
N> Minimum target Framework is 3.5 for Syncfusion Windows Forms project templates.
|
||||
|
||||
3. Choose the options to configure the Syncfusion Windows Forms Application by using the following Project Configuration Wizard.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-2.png)
|
||||
|
||||
### Project configurations:
|
||||
|
||||
**Language:** Select the language, either C# or VB.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-3.png)
|
||||
|
||||
**Assemblies From:** Choose the assembly location from where it is going to be added to the project.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-4.png)
|
||||
|
||||
**Select Control:** Choose the control based on your need.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-5.png)
|
||||
|
||||
4. Once the Project Configuration Wizard is done, the Syncfusion Windows Forms project is created with required references and forms.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-6.png)
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-7.png)
|
||||
|
||||
5. Then, Syncfusion licensing registration required message box will be shown as follow, if you are installed the trial setup or NuGet packages since Syncfusion introduced the licensing system from 2018 Volume 2 (v16.2.0.41) Essential Studio release. Please navigate to the [help topic](https://help.syncfusion.com/common/essential-studio/licensing/license-key#how-to-generate-syncfusion-license-key) which is shown in the licensing message box to generate and register the Syncfusion license key to your project. Refer to this [blog](https://blog.syncfusion.com/post/Whats-New-in-2018-Volume-2-Licensing-Changes-in-the-1620x-Version-of-Essential-Studio.aspx) post for understanding the licensing changes introduced in Essential Studio.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-8.png)
|
||||
|
||||
## Through Item Template
|
||||
|
||||
The Syncfusion Item Templates Add new item feature provides support to Windows Forms platform. To add the Syncfusion item files in Visual Studio, install Syncfusion Essential Studio for Windows Forms platform.The item template available from Syncfusion Essential Studio v13.1.0.21.
|
||||
|
||||
### Using Syncfusion Item Template Gallery
|
||||
|
||||
Follow the given steps to add the Syncfusion item in Visual Studio.
|
||||
|
||||
1. Open a new or existing Windows Forms application.
|
||||
|
||||
2. Right-click on the Windows Forms Project from the Solution Explorer. Select the Add Syncfusion Item New Item... option. Refer to the following screenshot
|
||||
for more information.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Item-Template-Gallery-1.png)
|
||||
|
||||
3. Now the Syncfusion Item Template Gallery window will open.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Item-Template-Gallery-2.png)
|
||||
|
||||
4. Select the required version and themes or Form from the Syncfusion Item Template Gallery.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Item-Template-Gallery-3.png)
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Item-Template-Gallery-4.png)
|
||||
|
||||
#### Platform
|
||||
|
||||
This is a combo box where you can choose the application’s platform. For now it contains Windows Forms Platform alone.
|
||||
|
||||
#### Version
|
||||
|
||||
Syncfusion’s Installed Build Versions are listed for Syncfusion Essential Studio v13.1.0.21 and later, for the installed Windows Forms platform.
|
||||
|
||||
#### Template Gallery
|
||||
|
||||
This part contains a set of Syncfusion Item Templates, and you can choose the Item Templates based on your need.
|
||||
|
||||
When Add button is clicked, then the selected item template is added to the project.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Item-Template-Gallery-5.png)
|
||||
|
||||
5.Then, Syncfusion licensing registration required message box will be shown as follow, if you are installed the trial setup or NuGet packages since Syncfusion introduced the licensing system from 2018 Volume 2 (v16.2.0.41) Essential Studio release. Please navigate to the [help topic](https://help.syncfusion.com/common/essential-studio/licensing/license-key#how-to-generate-syncfusion-license-key) which is shown in the licensing message box to generate and register the Syncfusion license key to your project. Refer to this [blog](https://blog.syncfusion.com/post/Whats-New-in-2018-Volume-2-Licensing-Changes-in-the-1620x-Version-of-Essential-Studio.aspx) post for understanding the licensing changes introduced in Essential Studio.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-8.png)
|
||||
|
||||
### Using Visual Studio Add new Item
|
||||
|
||||
Syncfusion Project Template can be also add from the Visual Studio Item Template. Right-click on the Windows Forms Project Add ->New Item. You can refer to the following screenshot for more information.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Add-New-Item-1.png)
|
||||
|
||||
1. The Syncfusion Item Templates are available under the Syncfusion tab. It is available for both C# Items and VB Items.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Add-New-Item-2.png)
|
||||
|
||||
2. Now the selected template is added to the project along with Syncfusion references.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Add-New-Item-3.png)
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Add-New-Item-4.png)
|
||||
|
||||
3. Then, Syncfusion licensing registration required message box will be shown as follow, if you are installed the trial setup or NuGet packages since Syncfusion introduced the licensing system from 2018 Volume 2 (v16.2.0.41) Essential Studio release. Please navigate to the [help topic](https://help.syncfusion.com/common/essential-studio/licensing/license-key#how-to-generate-syncfusion-license-key) which is shown in the licensing message box to generate and register the Syncfusion license key to your project. Refer to this [blog](https://blog.syncfusion.com/post/Whats-New-in-2018-Volume-2-Licensing-Changes-in-the-1620x-Version-of-Essential-Studio.aspx) post for understanding the licensing changes introduced in Essential Studio.
|
||||
|
||||
![](Add-Syncfusion-Control_images\Syncfusion-Project-Template-Gallery-8.png)
|
|
@ -0,0 +1,42 @@
|
|||
---
|
||||
layout: post
|
||||
title: Barcode Customization | SfBarcode | wpf | Syncfusion
|
||||
description: barcode customization
|
||||
platform: wpf
|
||||
control: SfBarcode
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Barcode Customization
|
||||
|
||||
The color of the barcode can be customized by modifying the DarkBarBrush and LightBarBrush properties of the barcode control.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
this.sfBarcode1.DarkBarColor = System.Drawing.Color.FromArgb(255, 0, 0);
|
||||
this.sfBarcode1.LightBarColor = System.Drawing.Color.FromArgb(255, 0, 0);
|
||||
|
||||
{% endhighlight %}
|
||||
{% highlight vb %}
|
||||
|
||||
Me.SfBarcode1.DarkBarColor = System.Drawing.Color.FromArgb(255, 0, 0)
|
||||
Me.SfBarcode1.LightBarColor = System.Drawing.Color.FromArgb(255, 0, 0)
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
The DarkBarBrush represents the color of the dark bar (Black color usually) and the LightBarBrush represents the color of the gap between two adjacent black bars (White color usually).
|
||||
|
||||
![](Barcode-Customization_images/Barcode-Customization_img1.png)
|
||||
|
||||
Barcode color combinations- Red
|
||||
{:.caption}
|
||||
|
||||
|
||||
![](Barcode-Customization_images/Barcode-Customization_img2.png)
|
||||
|
||||
Barcode color combinations- Blue
|
||||
{:.caption}
|
||||
|
||||
N> The DarkBarBrush and LightBarBrush customizations are applicable only for one dimensional barcodes. In order for a barcode symbol to be recognized by a scanner, there must be an adequate contrast between the dark bars and the light spaces and not all the barcode scanners have support for colored barcodes.
|
Двоичные данные
WindowsForms/Barcode/Barcode-Customization_images/Barcode-Customization_img1.png
Normal file
После Ширина: | Высота: | Размер: 2.2 KiB |
Двоичные данные
WindowsForms/Barcode/Barcode-Customization_images/Barcode-Customization_img2.png
Normal file
После Ширина: | Высота: | Размер: 4.5 KiB |
После Ширина: | Высота: | Размер: 1.9 KiB |
После Ширина: | Высота: | Размер: 1.1 KiB |
После Ширина: | Высота: | Размер: 1.3 KiB |
После Ширина: | Высота: | Размер: 3.6 KiB |
После Ширина: | Высота: | Размер: 2.8 KiB |
После Ширина: | Высота: | Размер: 6.3 KiB |
После Ширина: | Высота: | Размер: 5.0 KiB |
После Ширина: | Высота: | Размер: 4.5 KiB |
|
@ -0,0 +1,75 @@
|
|||
---
|
||||
layout: post
|
||||
title: Syncfusion Essential Windows Forms
|
||||
description: This section explains about the SfBarcode.
|
||||
platform: windowsforms
|
||||
control: SfBarcode
|
||||
documentation: ug
|
||||
---
|
||||
# Getting Started
|
||||
This section provides a quick overview for working with the barcode for WinForms.
|
||||
|
||||
## Assembly deployment
|
||||
The following assembly reference is required for deploying Barcode.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
Namespace: Syncfusion.Windows.Forms.Barcode
|
||||
|
||||
Assembly: Syncfusion.SfBarcode.Windows
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
## Creating application with SfBarcode
|
||||
In this walk through, users will create WinForms application that contains SfBarcode control.
|
||||
|
||||
### Creating the project
|
||||
Create new Windows Forms Project in Visual Studio to display SfBarcode.
|
||||
|
||||
### Adding control via Designer
|
||||
SfBarcode control can be added to the application by dragging it from Toolbox and dropping it in Designer. The required assembly references will be added automatically.
|
||||
![](Getting-Started_images/Getting-Started_img1.png)
|
||||
|
||||
### Adding control in Code
|
||||
In order to add control manually, do the below steps,
|
||||
|
||||
1) Add the below required assembly references to the project,
|
||||
|
||||
* Syncfusion.SfBarcode.Windows
|
||||
|
||||
2) Create the SfBarcode control instance and add it to the Form
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
using Syncfusion.Windows.Forms.Barcode;
|
||||
|
||||
namespace WindowsFormsApplication1
|
||||
{
|
||||
public partial class Form1 : Form
|
||||
{
|
||||
public Form1()
|
||||
{
|
||||
InitializeComponent();
|
||||
SfBarcode sfDataGrid1 = new SfBarcode();
|
||||
sfBarcode1.Text = "http://www.google.com";
|
||||
this.Controls.Add(this.sfBarcode1);
|
||||
}
|
||||
}
|
||||
}
|
||||
{% endhighlight %}
|
||||
{% highlight vb %}
|
||||
Imports Syncfusion.Windows.Forms.Barcode
|
||||
|
||||
Namespace WindowsFormsApplication1
|
||||
Partial Public Class Form1
|
||||
Inherits Form
|
||||
Public Sub New()
|
||||
InitializeComponent()
|
||||
Dim sfBarcode1 As New SfBarcode()
|
||||
sfBarcode1.Text = "http://www.google.com"
|
||||
Me.Controls.Add(Me.SfBarcode1)
|
||||
End Sub
|
||||
End Class
|
||||
End Namespace
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
После Ширина: | Высота: | Размер: 12 KiB |
|
@ -0,0 +1,31 @@
|
|||
---
|
||||
layout: post
|
||||
title: Overview | Barcode | Syncfusion
|
||||
description: WinForms Barcode control or generator helps user to embed the barcodes into their .NET application. It is easily customizable and support all barcode formats.
|
||||
platform: windowsforms
|
||||
control: SfBarcode
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Overview
|
||||
|
||||
The Barcode control helps rendering bar codes in desktop (Windows Forms) application. The control can be merged with into any desktop application and easy to encode text using the supported symbol types. The basic structure of a bar code consists of a leading and trailing quiet zone, a start pattern, one or more data characters, optionally one or two check characters, and a stop pattern.
|
||||
|
||||
![Barcode control rendering one dimensional bar code](Overview_images/Overview_img1.png)
|
||||
|
||||
Barcode control rendering 1D bar code
|
||||
{:.caption}
|
||||
|
||||
|
||||
![Barcode control rendering two dimensional bar code](Overview_images/Overview_img2.png)
|
||||
|
||||
|
||||
Barcode control rendering 2D bar code
|
||||
{:.caption}
|
||||
|
||||
## Structure of the Control
|
||||
|
||||
![Structure of BarCode](Overview_images/Overview_img3.png)
|
||||
|
||||
Structure of Barcode control
|
||||
{:.caption}
|
После Ширина: | Высота: | Размер: 6.3 KiB |
После Ширина: | Высота: | Размер: 5.5 KiB |
После Ширина: | Высота: | Размер: 11 KiB |
|
@ -0,0 +1,93 @@
|
|||
---
|
||||
layout: post
|
||||
title: Supported-Barcode-types | SfBarcode | wpf | Syncfusion
|
||||
description: Supported Barcode types
|
||||
platform: wpf
|
||||
control: SfBarcode
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Supported Barcode types
|
||||
|
||||
The following table contains the supported types and associated valid characters.
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>Symbol</th>
|
||||
<th>Enum Value</th>
|
||||
<th>Supported characters</th>
|
||||
<th>Length</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[QR Code](https://en.wikipedia.org/wiki/QR_code)'| markdownify }}</td><td>
|
||||
QRBarcode</td><td>
|
||||
[0–9]; [A–Z (upper-case only)]; [space $ % * + - . / , :]; [Shift JIS characters]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[DataMatrix](https://en.wikipedia.org/wiki/Data_Matrix)'| markdownify }}</td><td>
|
||||
DataMatrix</td><td>
|
||||
All ASCII characters</td><td>
|
||||
</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 39](https://en.wikipedia.org/wiki/Code_39)'| markdownify }}</td><td>
|
||||
Code39</td><td>
|
||||
[0-9]; [A-Z]; [- . $ / + % SPACE]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 39 Extended](https://en.wikipedia.org/wiki/Code_39#Full_ASCII_Code_39)'| markdownify }}</td><td>
|
||||
Code39Extended</td><td>
|
||||
[0-9]; [A-Z]; [a-z]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 11](https://en.wikipedia.org/wiki/Code_11)'| markdownify }}</td><td>
|
||||
Code11</td><td>
|
||||
[0-9]; [-]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Codabar](https://en.wikipedia.org/wiki/Codabar)'| markdownify }}</td><td>
|
||||
Codabar</td><td>
|
||||
[0-9]; [- $ : / . +]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Code 32</td><td>
|
||||
Code32</td><td>
|
||||
[0-9]</td><td>
|
||||
8</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 93](https://en.wikipedia.org/wiki/Code_93)'| markdownify }}</td><td>
|
||||
Code93</td><td>
|
||||
[0-9]; [A-Z]; [- . $ / + % SPACE]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 93 Extended](https://en.wikipedia.org/wiki/Code_93#Full_ASCII_Code_93)'| markdownify }}</td><td>
|
||||
Code93Extended</td><td>
|
||||
All 128 ASCII characters</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 128A](https://en.wikipedia.org/wiki/Code_128)'| markdownify }}</td><td>
|
||||
Code128A</td><td>
|
||||
[0-9]; [A-Z]; [NUL (0x00) SOH (0x01) STX (0x02) ETX (0x03) EOT(0x04) ENQ (0x05) ACK (0x06) BEL (0x07) BS (0x08) HT (0x09) LF (0x0A) VT(0x0B) FF (0x0C) CR (0x0D) SO (0x0E) SI (0x0F) DLE (0x10) DC1 (0x11) DC2(0x12) DC3 (0x13) DC4 (0x14) NAK (0x15) SYN (0x16) ETB (0x17) CAN(0x18) EM (0x19) SUB (0x1A) ESC (0x1B) FS (0x1C) GS (0x1D) RS (0x1E) US(0x1F) SPACE (0x20)]; [" ! # $ % & ' ( ) * + , - . / ; < = > ? @ [ / ]^ _ ]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 128B](https://en.wikipedia.org/wiki/Code_128)'| markdownify }}</td><td>
|
||||
Code128B</td><td>
|
||||
[0-9]; [A-Z]; [a-z]; [SPACE (0x20) ! " # $ % & ' ( ) * + , - . / :; < = > ? @ [ / ]^ _ ` { | } ~ DEL (•) ]</td><td>
|
||||
variable</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{'[Code 128C](https://en.wikipedia.org/wiki/Code_128)'| markdownify }}</td><td>
|
||||
Code128C</td><td>
|
||||
ASCII 00-99(encodes each two digit with one code)</td><td>
|
||||
variable</td></tr>
|
||||
</table>
|
|
@ -0,0 +1,339 @@
|
|||
---
|
||||
layout: post
|
||||
title: Symbology Settings | SfBarcode | wpf | Syncfusion
|
||||
description: symbology settings
|
||||
platform: wpf
|
||||
control: SfBarcode
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Symbology Settings
|
||||
|
||||
Each Barcode symbol can be associated with optional settings that may affect that specific bar code. The code sample below shows the settings of a code39 Barcode.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
Code39Setting code39Settings = new Code39Setting();
|
||||
code39Settings.BarHeight = 100;
|
||||
this.sfBarcode1.SymbologySettings = code39Settings;
|
||||
|
||||
{% endhighlight %}
|
||||
{% highlight vb %}
|
||||
|
||||
Dim code39Settings As New Code39Setting()
|
||||
code39Settings.BarHeight = 100
|
||||
sfBarcode1.SymbologySettings = code39Settings
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
## 1D Barcode settings
|
||||
|
||||
The one dimensional barcodes have some of the settings in common, such as BarHeight which modifies the height of the bars and NarrowBarWidth which modifies the width ratio of the wide and narrow bars.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
Code39Setting code39Settings = new Code39Setting();
|
||||
code39Settings.BarHeight = 100;
|
||||
code39Settings.NarrowBarWidth = 1;
|
||||
this.sfBarcode1.SymbologySettings = code39Settings;
|
||||
|
||||
{% endhighlight %}
|
||||
{% highlight vb %}
|
||||
|
||||
Dim code39Settings As New Code39Setting()
|
||||
code39Settings.BarHeight = 100
|
||||
code39Settings.NarrowBarWidth = 1
|
||||
sfBarcode1.SymbologySettings = code39Settings
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
The one dimensional barcodes also has the error detection settings. The EnableCheckDigit property enables the redundancy check using a check digit, the decimal equivalent of a binary parity bit. It consists of a single digit computed from the other digits in the message. The check digit can be shown in the barcode or kept hidden by using the ShowCheckDigit property.
|
||||
|
||||
The EncodeStartStopSymbols property adds Start and Stop symbols to signal a bar code reader that a bar code has been scanned.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
Code39Setting code39Settings = new Code39Setting();
|
||||
code39Settings.EnableCheckDigit = false;
|
||||
code39Settings.ShowCheckDigit = false;
|
||||
code39Settings.EncodeStartStopSymbols = true;
|
||||
this.sfBarcode1.SymbologySettings = code39Settings;
|
||||
|
||||
{% endhighlight %}
|
||||
{% highlight vb %}
|
||||
|
||||
Dim code39Settings As New Code39Setting()
|
||||
code39Settings.EnableCheckDigit = false
|
||||
code39Settings.ShowCheckDigit = false
|
||||
code39Settings.EncodeStartStopSymbols = true
|
||||
sfBarcode1.SymbologySettings = code39Settings
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
## 2D Barcode Settings
|
||||
|
||||
The two dimensional barcodes have a common XDimension property which modifies the block size of a two dimensional barcode.
|
||||
|
||||
### DataMatrix Barcode settings
|
||||
|
||||
The DataMatrix barcode settings has the properties to modify the encoding and size of the DataMatrix barcode.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
DataMatrixSetting barcodeSettings = new DataMatrixSetting();
|
||||
barcodeSettings.XDimension = 8;
|
||||
barcodeSettings.Encoding = DataMatrixEncoding.ASCII;
|
||||
barcodeSettings.Size = DataMatrixSize.Size10x10;
|
||||
this.sfBarcode1.SymbologySettings = barcodeSettings;
|
||||
|
||||
{% endhighlight %}
|
||||
{% highlight vb %}
|
||||
|
||||
Dim barcodeSettings As New DataMatrixSetting()
|
||||
barcodeSettings.XDimension = 8
|
||||
barcodeSettings.Encoding = DataMatrixEncoding.ASCII
|
||||
barcodeSettings.Size = DataMatrixSize.Size10x10
|
||||
sfBarcode1.SymbologySettings = barcodeSettings
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
### Encoding
|
||||
|
||||
The encoding of the DataMatrix barcode can be modified using the ‘Encoding’ property. The DataMatrixEncoding enumeration has the following four encoding schemes.
|
||||
|
||||
* ASCII
|
||||
* ASCIINumeric
|
||||
* Auto
|
||||
* Base256
|
||||
|
||||
### Size
|
||||
|
||||
The DataMatrix Barcode settings allow the user to specify the size of the barcode from a set of predefined sizes available in the DataMatrixSize enumeration.
|
||||
|
||||
Data Matrix size Table
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>
|
||||
Data Matrix Size</th><th>
|
||||
Description</th></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Auto</td><td>
|
||||
Size is chosen based on the input data</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size10x10</td><td>
|
||||
Square matrix with 10 rows and 10 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size12x12</td><td>
|
||||
Square matrix with 12 rows and 12 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size14x14</td><td>
|
||||
Square matrix with 14 rows and 14 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size16x16</td><td>
|
||||
Square matrix with 16 rows and 16 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size18x18</td><td>
|
||||
Square matrix with 18 rows and 18 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size20x20</td><td>
|
||||
Square matrix with 20 rows and 20 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size22x22</td><td>
|
||||
Square matrix with 22 rows and 22 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size24x24</td><td>
|
||||
Square matrix with 24 rows and 24 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size26x26</td><td>
|
||||
Square matrix with 26 rows and 26 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size32x32</td><td>
|
||||
Square matrix with 32 rows and 32 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size36x36</td><td>
|
||||
Square matrix with 36 rows and 36 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size40x40</td><td>
|
||||
Square matrix with 40 rows and 40 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size44x44</td><td>
|
||||
Square matrix with 44 rows and 44 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size48x48</td><td>
|
||||
Square matrix with 48 rows and 48 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size52x52</td><td>
|
||||
Square matrix with 52 rows and 52 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size64x64</td><td>
|
||||
Square matrix with 64 rows and 64 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size72x72</td><td>
|
||||
Square matrix with 72 rows and 72 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size80x80</td><td>
|
||||
Square matrix with 80 rows and 80 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size88x88</td><td>
|
||||
Square matrix with 88 rows and 88 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size96x96</td><td>
|
||||
Square matrix with 96 rows and 96 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size104x104</td><td>
|
||||
Square matrix with 104 rows and 104 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size120x120</td><td>
|
||||
Square matrix with 120 rows and 120 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size132x132</td><td>
|
||||
Square matrix with 132 rows and 132 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size144x144</td><td>
|
||||
Square matrix with 144 rows and 144 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size8x18</td><td>
|
||||
Rectangular matrix with 8 rows and 18 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size8x32</td><td>
|
||||
Rectangular matrix with 8 rows and 32 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size12x26</td><td>
|
||||
Rectangular matrix with 12 rows and 26 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size12x36</td><td>
|
||||
Rectangular matrix with 12 rows and 36 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size16x36</td><td>
|
||||
Rectangular matrix with 16 rows and 36 columns.</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Size16x48</td><td>
|
||||
Rectangular matrix with 16 rows and 48 columns.</td></tr>
|
||||
</table>
|
||||
|
||||
|
||||
### QRBarcode settings
|
||||
|
||||
The QRBarcode settings has properties to modify the version, error correction level and Input mode of the QRBarcode.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
QRBarcodeSetting qrSettings = new QRBarcodeSetting();
|
||||
qrSettings.XDimension = 8;
|
||||
qrSettings.ErrorCorrectionLevel = ErrorCorrectionLevel.High;
|
||||
qrSettings.InputMode = QRInputMode.BinaryMode;
|
||||
qrSettings.Version = QRBarcodeVersion.Version04;
|
||||
this.sfBarcode1.SymbologySettings = qrSettings;
|
||||
|
||||
{% endhighlight %}
|
||||
{% highlight vb %}
|
||||
|
||||
Dim qrSettings As New QRBarcodeSetting()
|
||||
qrSettings.XDimension = 8
|
||||
qrSettings.ErrorCorrectionLevel = ErrorCorrectionLevel.High
|
||||
qrSettings.InputMode = QRInputMode.BinaryMode
|
||||
qrSettings.Version = QRBarcodeVersion.Version04
|
||||
sfBarcode1.SymbologySettings = qrSettings
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
|
||||
## Version
|
||||
|
||||
The QR Barcode uses version from 1 to 40.Version 1 measures 21 modules x 21 modules, Version 2 measures 25 modules x 25 modules and so on increasing in steps of 4 modules per side up to Version 40 which measures 177 modules x 177 modules. Each version has its own capacity. By default the QR Version is Auto, which will automatically set the version according to the input text length.
|
||||
|
||||
## Error correction level
|
||||
|
||||
The QR Barcode employs error correction to generate a series of error correction codewords which are added to the data code word sequence in order to enable the symbol to withstand damage without loss of data. There are four user–selectable levels of error correction, as shown in the table, offering the capability of recovery from the following amounts of damage. By default the Error correction level is Low.
|
||||
|
||||
Error Correction Level Table
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>
|
||||
Error Correction Level</th><th>
|
||||
Recovery Capacity % (approx.)</th></tr>
|
||||
<tr>
|
||||
<td>
|
||||
L</td><td>
|
||||
7</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
M</td><td>
|
||||
15</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Q</td><td>
|
||||
25</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
H</td><td>
|
||||
30</td></tr>
|
||||
</table>
|
||||
|
||||
## Input mode
|
||||
|
||||
There are three modes for the input as defined in the table. Each mode supports the specific set of Input characters. User may select the most suitable input mode. By default the Input mode is Binary Mode.
|
||||
|
||||
Input Mode Table
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>
|
||||
Input Mode</th><th>
|
||||
Possible characters</th></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Numeric Mode</td><td>
|
||||
0,1,2,3,4,5,6,7,8,9</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Alphanumeric Mode</td><td>
|
||||
0–9, A–Z (upper-case only), space, $, %, *, +, -,., /, :</td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
Binary Mode</td><td>
|
||||
Shift JIS characters</td></tr>
|
||||
</table>
|
|
@ -0,0 +1,60 @@
|
|||
---
|
||||
layout: post
|
||||
title: Features | Windows Forms | Syncfusion
|
||||
description: features
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
|
||||
# Caption Settings
|
||||
|
||||
The Caption for a Bullet Graph specifies a unique label describing the value represented in the BulletGraph.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.Caption = " Revenue YTD \n $ in thousands";
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 3, RangeStroke = Color.LightGray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeStroke = Color.Gray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeStroke = Color.DarkGray });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![](Features_images/Features_img3.png)
|
||||
|
||||
### Caption Position
|
||||
|
||||
The caption in the Bullet Graph is placed at the start or end of the quantitative scale by choosing from one of the two options available in the CaptionPosition property. They are:
|
||||
|
||||
* Near (Default)
|
||||
* Far
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.Caption = " Revenue YTD \n $ in thousands";
|
||||
|
||||
bullet.CaptionPosition = BulletGraphCaptionPosition.Far; bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 3, RangeStroke = Color.LightGray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeStroke = Color.Gray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeStroke = Color.DarkGray });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![](Features_images/Features_img4.png)
|
После Ширина: | Высота: | Размер: 1.8 KiB |
После Ширина: | Высота: | Размер: 2.9 KiB |
После Ширина: | Высота: | Размер: 3.6 KiB |
После Ширина: | Высота: | Размер: 2.8 KiB |
После Ширина: | Высота: | Размер: 1.4 KiB |
После Ширина: | Высота: | Размер: 4.7 KiB |
После Ширина: | Высота: | Размер: 4.7 KiB |
После Ширина: | Высота: | Размер: 4.3 KiB |
После Ширина: | Высота: | Размер: 4.9 KiB |
После Ширина: | Высота: | Размер: 6.3 KiB |
После Ширина: | Высота: | Размер: 2.7 KiB |
После Ширина: | Высота: | Размер: 2.8 KiB |
|
@ -0,0 +1,161 @@
|
|||
---
|
||||
layout: post
|
||||
title: Getting-Started | Windows Forms | Syncfusion
|
||||
description: getting started
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Getting Started
|
||||
|
||||
The Bullet Graph is composed of quantitative scale, qualitative ranges, featured measure and Comparative Measure. The main purpose of the Bullet Graph is described by making use of the Caption. The quantitative scale of the Bullet Graph includes ticks and labels. The view of the Bullet Graph is changed by setting the Orientation property.
|
||||
|
||||
## Assembly deployment
|
||||
|
||||
Refer [control dependencies](https://help.syncfusion.com/windowsforms/control-dependencies#bulletgraph) section to get the list of assemblies or NuGet package needs to be added as reference to use the control in any application.
|
||||
|
||||
Please find more details regarding how to install the nuget packages in windows form application in the below link:
|
||||
|
||||
[How to install nuget packages](https://help.syncfusion.com/windowsforms/nuget-packages)
|
||||
|
||||
## Create the Bullet Graph Programmatically
|
||||
|
||||
* Assembly Information
|
||||
|
||||
Bullet Graph is available in the following assembly.
|
||||
|
||||
Assembly: Syncfusion.BulletGraph.Windows
|
||||
|
||||
* NameSpace
|
||||
|
||||
Bullet Graph is available in the following namespace.
|
||||
|
||||
Namespace: Syncfusion.Windows.Forms.BulletGraph
|
||||
|
||||
### Steps to create a simple Bullet Graph control:
|
||||
|
||||
1. Create a new Windows Forms application project in Visual Studio.
|
||||
|
||||
![](Getting-Started_images/Getting-Started_img1.png)
|
||||
|
||||
2. Add references to Syncfusion.BulletGraph.Windows.
|
||||
3. Add the Bullet Graph control in code behind as follows.
|
||||
|
||||
~~~ cs
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FlowDirection = BulletGraphFlowDirection.Forward;
|
||||
|
||||
bullet.Orientation = Orientation.Horizontal;
|
||||
|
||||
bullet.FeaturedMeasure = 4.5;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.LabelFontSize = 10;
|
||||
|
||||
bullet.LabelStroke = Color.Black;
|
||||
|
||||
bullet.MajorTickStroke = Color.Black;
|
||||
|
||||
bullet.Minimum = 0;
|
||||
|
||||
bullet.Maximum = 10;
|
||||
|
||||
bullet.Interval = 2;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
~~~
|
||||
{:.prettyprint }
|
||||
|
||||
4. Run the application to view the Bullet Graph.
|
||||
|
||||
![D:/Help UGs/BulletGraph/WF/BG_Elements.png](Getting-Started_images/Getting-Started_img2.png)
|
||||
|
||||
## Create the Bullet Graph using Syncfusion Reference Manager
|
||||
|
||||
Syncfusion Reference Manager is used to add Syncfusion Tools.
|
||||
|
||||
To add a Bullet Graph Control, refer the following steps:
|
||||
|
||||
1. Create a simple Windows Forms application using Visual Studio.
|
||||
|
||||
![](Getting-Started_images/Getting-Started_img3.png)
|
||||
|
||||
2. Right-Click on the Project and select SyncfusionReferenceManager.
|
||||
|
||||
![](Getting-Started_images/Getting-Started_img4.png)
|
||||
|
||||
3. The Syncfusion Reference Manager Wizard is opened as shown in the following screenshot.
|
||||
|
||||
![D:/Help UGs/BulletGraph/WF/Ref_Manager.bmp](Getting-Started_images/Getting-Started_img5.png)
|
||||
|
||||
4. Search for Bullet Graph using SearchBox and select Bullet Graph Control. Click on Done to add selected Bullet Graph Control.
|
||||
|
||||
![](Getting-Started_images/Getting-Started_img6.png)
|
||||
|
||||
5. The Bullet Graph assemblies are automatically added to the Project after Clicking OK
|
||||
|
||||
![](Getting-Started_images/Getting-Started_img7.png)
|
||||
|
||||
6. Add the following code example in code behind to create a simple Bullet Graph control.
|
||||
|
||||
~~~ cs
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FlowDirection = BulletGraphFlowDirection.Forward;
|
||||
|
||||
bullet.Orientation = Orientation.Horizontal;
|
||||
|
||||
bullet.FeaturedMeasure = 4.5;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.LabelFontSize = 10;
|
||||
|
||||
bullet.LabelStroke = Color.Black;
|
||||
|
||||
bullet.MajorTickStroke = Color.Black;
|
||||
|
||||
bullet.Minimum = 0;
|
||||
|
||||
bullet.Maximum = 10;
|
||||
|
||||
bullet.Interval = 2;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
~~~
|
||||
{:.prettyprint }
|
||||
|
||||
7. The simple Bullet Graph control is created as shown in the following screenshot.
|
||||
|
||||
![](Getting-Started_images/Getting-Started_img8.png)
|
||||
|
||||
N> 1. The Syncfusion Reference Manager is available in versions 11.3.0.30 and later. It supports referencing assemblies from version 10.4.0.71 version to the current version.
|
||||
N>
|
||||
N> 2. The Syncfusion Reference Manager is used only in Visual Studio 2010, 2012, and 2013.
|
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img1.png
Normal file
После Ширина: | Высота: | Размер: 74 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img2.png
Normal file
После Ширина: | Высота: | Размер: 6.3 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img3.png
Normal file
После Ширина: | Высота: | Размер: 74 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img4.png
Normal file
После Ширина: | Высота: | Размер: 160 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img5.png
Normal file
После Ширина: | Высота: | Размер: 115 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img6.png
Normal file
После Ширина: | Высота: | Размер: 86 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img7.png
Normal file
После Ширина: | Высота: | Размер: 97 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img8.png
Normal file
После Ширина: | Высота: | Размер: 6.3 KiB |
Двоичные данные
WindowsForms/Bullet-Graph/Getting-Started_images/Getting-Started_img9.png
Normal file
После Ширина: | Высота: | Размер: 1.0 KiB |
|
@ -0,0 +1,72 @@
|
|||
---
|
||||
layout: post
|
||||
title: Features | Windows Forms | Syncfusion
|
||||
description: features
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
|
||||
# Measure Settings (Featured / Comparative Measure)
|
||||
|
||||
### Featured Measure:
|
||||
|
||||
Featured Measure displays the primary data, or the current value of the data that you are measuring. It should usually be encoded as a bar, like the bar on a bar graph, and be prominent.
|
||||
|
||||
#### Customizing Featured Measure:
|
||||
|
||||
The value of the Featured Measure of the BulletGraph is set by the FeaturedMeasure property. By setting the FeaturedMeasureBarStroke property, the stroke of the FeatureMeasure bar is customized. The thickness of the Featured Measure bar is modified by using FeaturedMeasureBarStrokeThickness.
|
||||
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FeaturedMeasure = 5;
|
||||
|
||||
bullet.FeaturedMeasureBarStroke = Color.Red;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 3, RangeStroke = Color.LightGray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeStroke = Color.Gray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeStroke = Color.DarkGray });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![](Features_images/Features_img5.png)
|
||||
|
||||
### Comparative Measure:
|
||||
|
||||
Comparative Measure should be less visually dominant than the Featured Measure. It should always be encoded as a short line that runs perpendicular to the orientation of the graph. A good example is a target for YTD revenue. Whenever the Featured Measure intersects a Comparative Measure, the Comparative Measure appears behind the Featured Measure.
|
||||
|
||||
#### Customizing Comparative Measure:
|
||||
|
||||
The value of the Comparative Measure is set by using the ComparativeMeasure property. By setting the ComparativeMeasureSymbolStroke property, the stroke of the Comparative Measure symbol is customized. The thickness of the Comparative Measure symbol is modified by using ComparativeMeasureSymbolStrokeThickness.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.ComparativeMeasure = 5;
|
||||
|
||||
bullet.ComparativeMeasureSymbolStroke = Color.Red;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 3, RangeStroke = Color.LightGray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeStroke = Color.Gray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeStroke = Color.DarkGray });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![](Features_images/Features_img6.png)
|
|
@ -0,0 +1,43 @@
|
|||
---
|
||||
layout: post
|
||||
title: Features | Windows Forms | Syncfusion
|
||||
description: features
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Orientation
|
||||
|
||||
The view of the Bullet Graph is changed by setting the Orientation property. Quantitative scale contains two major components: Ticks and Labels. The length of the quantitative scale is customized by using the QuantitativeScaleLength property. The direction of the quantitative scale is personalized by making use of the FlowDirection property it’s either Forward or Backward.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FlowDirection = BulletGraphFlowDirection.Forward;
|
||||
|
||||
bullet.Orientation = Orientation.Horizontal;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 3, RangeStroke = Color.LightGray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeStroke = Color.Gray });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeStroke = Color.DarkGray });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
{{' ![D:/Help UGs/BulletGraph/WF/BG_Ver.bmp](Features_images/Features_img1.png)' | markdownify }}
|
||||
|
||||
</td><td>
|
||||
{{' ![D:/Help UGs/BulletGraph/WF/BG_Hor.bmp](Features_images/Features_img2.png)' | markdownify }}
|
||||
|
||||
</td></tr>
|
||||
</table>
|
|
@ -0,0 +1,19 @@
|
|||
---
|
||||
layout: post
|
||||
title: Overview of Syncfusion BulletGraph control for WindowsForms
|
||||
description: This section explains the key features and quick overview about Syncfusion Bullet Graph control for WindowsForms
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Overview
|
||||
|
||||
Bullet Graph is a variation of the bar graph that is developed as a replacement for the dashboard gauges and meters. The Bullet Graph features a single, primary measure (for example, current year-to-date revenue), and compares that measure to one or more other measures to enrich its meaning (for example, compared to a target). It displays the measures in the context of the qualitative range of performance, such as poor, satisfactory, and good.
|
||||
|
||||
### Use Cases:
|
||||
|
||||
* It is used in the dashboard environment where the screen real-estate really counts.
|
||||
* Bullet Graph shows a ton of data in a very compact space.
|
||||
* It is handy to visualize data.
|
||||
* It is used in the revenue analysis and expense analysis.
|
|
@ -0,0 +1,74 @@
|
|||
---
|
||||
layout: post
|
||||
title: Features | Windows Forms | Syncfusion
|
||||
description: Learn how to customize the range and to set range stroke to ticks and labels in Bullet Graph Windows Forms
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Qualitative Range of the Bullet Graph
|
||||
|
||||
Ranges for a Bullet Graph are a collection of qualitative ranges. A qualitative range is a visual element that ends at a specified RangeEnd at the start of the previous range’s RangeEnd. The qualitative ranges are arranged according to each RangeEnd value.
|
||||
|
||||
### Customizing Range:
|
||||
|
||||
The width of the ranges are customized by setting the QualitativeRangesSize property. By changing RangeStroke of the qualitative range, the stroke of the range is personalized. By setting the RangeOpacity of the qualitative range, the opacity of the range is modified.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FeaturedMeasure = 4.5;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![Range customization image](Features_images/Features_img7.png)
|
||||
|
||||
### Binding RangeStroke to Ticks and Labels:
|
||||
|
||||
By setting BindRangeStrokeToLabels, the stroke of the labels is set related to the stroke of the specified ranges. Similarly, by setting BindRangeStrokeToTicks, the stroke of the ticks is set related to the stroke of the specified ranges.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FeaturedMeasure = 4.5;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.MajorTickStroke = Color.Black;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
bullet.BindRangeStrokeToTicks = true;
|
||||
|
||||
bullet.BindRangeStrokeToLabels = true;
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![Range stroke to ticks and labels image](Features_images/Features_img8.png)
|
|
@ -0,0 +1,84 @@
|
|||
---
|
||||
layout: post
|
||||
title: Features | Windows Forms | Syncfusion
|
||||
description: Learn how to customize the scale label and position the scale label in Syncfusion Bullet Graph Windows Forms
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
|
||||
# Scale Label settings
|
||||
|
||||
### Labels:
|
||||
|
||||
A quantitative scale label specifies the numeric value according to the major ticks in the range of the scale.
|
||||
|
||||
### Customizing Labels:
|
||||
|
||||
The label’s offset is changed by using the LabelOffset property. The foreground of the label is customized by setting LabelStroke. By setting LabelFontSize property, the font size of the labels is modified.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FeaturedMeasure = 5;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.LabelOffset = 5;
|
||||
|
||||
bullet.LabelFontSize = 10;
|
||||
|
||||
bullet.LabelFormat = "#0 K";
|
||||
|
||||
bullet.LabelStroke =Color.Red;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![Label customization Image](Features_images/Features_img11.png)
|
||||
|
||||
### Label Position
|
||||
|
||||
The labels in the scale are placed above or below the qualitative ranges by choosing the following options available in the LabelPosition property.
|
||||
|
||||
* Below (Default)
|
||||
* Above
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FeaturedMeasure = 5;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.LabelPosition = BulletGraphLabelsPosition.Above;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![Label Position Image](Features_images/Features_img12.png)
|
|
@ -0,0 +1,92 @@
|
|||
---
|
||||
layout: post
|
||||
title: Features | Windows Forms | Syncfusion
|
||||
description: features
|
||||
platform: windowsforms
|
||||
control: Bullet Graph
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Scale Tick Mark Settings
|
||||
|
||||
Quantitative scale is displayed with two types of ticks:
|
||||
|
||||
Major ticks, the primary scale indicators.
|
||||
|
||||
Minor ticks, the secondary scale indicators that fall in between the major ticks.
|
||||
|
||||
### Customizing Ticks:
|
||||
|
||||
The stroke of the major and minor ticks is customized by setting the MajorTickStroke and MinorTickStroke properties. The size is modified by using the MajorTickSize and MinorTickSize properties. By setting MajorTickStrokeThickness and MinorTickStrokeThickness, the stroke’s thickness is customized.
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.FeaturedMeasure = 4.5;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.MajorTickStroke = Color.Black;
|
||||
|
||||
bullet.MajorTickSize = 15;
|
||||
|
||||
bullet.MinorTickSize = 10;
|
||||
|
||||
bullet.MajorTickStroke = Color.Red;
|
||||
|
||||
bullet.MinorTickStroke = Color.Green;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![](Features_images/Features_img9.png)
|
||||
|
||||
### TickPosition:
|
||||
|
||||
The ticks in the scale are placed above or below the ranges of the quantitative scale by choosing the options available in the TickPosition property.
|
||||
|
||||
They are:
|
||||
|
||||
* Below (Default)
|
||||
* Above
|
||||
* Cross
|
||||
|
||||
{% highlight c# %}
|
||||
|
||||
BulletGraph bullet = new BulletGraph();
|
||||
|
||||
bullet.Dock = DockStyle.Fill;
|
||||
|
||||
bullet.ComparativeMeasure = 7;
|
||||
|
||||
bullet.TickPosition = BulletGraphTicksPosition.Cross;
|
||||
|
||||
bullet.MajorTickSize = 30;
|
||||
|
||||
bullet.MinorTickSize = 30;
|
||||
|
||||
bullet.MinorTicksPerInterval = 3;
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 4, RangeCaption = "Bad", RangeStroke = Color.Red });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 7, RangeCaption = "Satisfactory", RangeStroke = Color.Yellow });
|
||||
|
||||
bullet.QualitativeRanges.Add(new QualitativeRange() { RangeEnd = 10, RangeCaption = "Good", RangeStroke = Color.Green });
|
||||
|
||||
this.Controls.Add(bullet);
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
![](Features_images/Features_img10.png)
|
|
@ -0,0 +1,383 @@
|
|||
---
|
||||
layout: post
|
||||
title: Appearance| WindowsForms | Syncfusion
|
||||
description: Appearance
|
||||
platform: WindowsForms
|
||||
control: SfButton
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Appearance
|
||||
|
||||
This section describes how to customize the appearance of the SfButton control.
|
||||
|
||||
## Background
|
||||
|
||||
The background of the SfButton can be filled with solid color, gradient colors, or image.
|
||||
|
||||
### BackColor
|
||||
|
||||
The background of the SfButton can be filled with solid color by initializing the [BackColor](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_BackColor) property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initialize the Gray color to the background of SfButton
|
||||
sfButton1.BackColor = Color.Gray;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
### Gradient BackColor
|
||||
|
||||
The background of the SfButton can be filled with gradient colors by initializing the GradientBrush property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initialize the gradient background brush to SfButton.
|
||||
sfButton1.Style.GradientBrush = new BrushInfo(GradientStyle.ForwardDiagonal, Color.Green, Color.Yellow);
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img9.jpeg)
|
||||
|
||||
### Background Image
|
||||
|
||||
The background of the SfButton can be filled with image by initialize the BackgroundImage property. The background image layout can be changed by initializing any one of ImageLayout enumeration value to BackgroundImageLayout property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
|
||||
//Initializing the image value to BackgroundImage property.
|
||||
this.sfButton1.BackgroundImage = Image.FromFile(@"..\..\Data\BackgroundImage.png");
|
||||
|
||||
//Sets the center image layout to the Background image.
|
||||
this.sfButton1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img10.jpeg)
|
||||
|
||||
## Customizing Appearance based on Button State
|
||||
|
||||
The SfButton provide options to customize the appearance based on the button state.
|
||||
|
||||
### Backcolor and Fore Color
|
||||
|
||||
The backcolor and fore color of the SfButton in hover state can be changed by using the [HoverBackColor](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_HoverBackColor) and [HoverForeColor](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_HoverForeColor) properties. Like the hover state, you can customize in pressed state, focused state, normal state, and disable state of the SfButton.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initializing the back color.
|
||||
sfButton1.Style.BackColor = Color.Gray;
|
||||
|
||||
//Initializing the fore color.
|
||||
sfButton1.Style.ForeColor = Color.Black;
|
||||
|
||||
//Initializing the hover back color.
|
||||
sfButton1.Style.HoverBackColor = Color.Gray;
|
||||
|
||||
//Initializing the hover fore color.
|
||||
sfButton1.Style.HoverForeColor = Color.White;
|
||||
|
||||
//Initializing the focused back color.
|
||||
sfButton1.Style.FocusedBackColor = Color.LightGray;
|
||||
|
||||
//Initializing the focused fore color.
|
||||
sfButton1.Style.FocusedForeColor = Color.Black;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img11.jpeg)
|
||||
|
||||
### Image
|
||||
|
||||
The SfButton allows changing the image in hover state by using the [HoverImage](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_HoverImage) property. Like hover state, you can change the image in focused, disabled, and pressed states by using the [FocusedImage](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_FocusedImage), [DisabledImage](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_DisabledImage), and [PressedImage](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_PressedImage) properties.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initializing the image for SfButton default state
|
||||
sfButton1.Style.Image = Image.FromFile(@"..\..\Data\DefaultImage.png");
|
||||
|
||||
//Initializing the hover image for SfButton.
|
||||
sfButton1.Style.HoverImage = Image.FromFile(@"..\..\Data\HoverImage.png");
|
||||
|
||||
//Initializing the pressed image for SfButton.
|
||||
sfButton1.Style.PressedImage = Image.FromFile(@"..\..\Data\PressedImage.png");
|
||||
|
||||
//Initializing the Focused image for SfButton.
|
||||
sfButton1.Style.FocusedImage = Image.FromFile(@"..\..\Data\FocusedImage.png");
|
||||
|
||||
//Initializing the disabled image for SfButton.
|
||||
sfButton1.Style.DisabledImage = Image.FromFile(@"..\..\Data\DisabledImage.png");
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img12.jpeg)
|
||||
|
||||
![](SfButton_images/SfButton_img13.jpeg)
|
||||
|
||||
### Border
|
||||
|
||||
The border can be changed based on the button state by using the [Border](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_Border), [HoverBorder](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_HoverBorder), [FocusedBorder](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_FocusedBorder), [PressedBorder](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_PressedBorder), and [DisabledBorder](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.Styles.ButtonVisualStyle.html#Syncfusion_WinForms_Controls_Styles_ButtonVisualStyle_DisabledBorder) properties.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initialize the hover border
|
||||
sfButton6.Style.HoverBorder = new Pen(Color.DarkGray, 2);
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img14.jpeg)
|
||||
|
||||
## Animating the Image
|
||||
|
||||
The animation image (.gif image) can be displayed in the SfButton by enabling the [AllowImageAnimation](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_AllowImageAnimation) property and initialize the animation image to the [Image](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Image) property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Enable the Image animation
|
||||
sfButton1.AllowImageAnimation = true;
|
||||
|
||||
//Initialize the animation image to SfButton.
|
||||
sfButton1.Style.Image = Image.FromFile(@"..\..\Data\animationImage.gif");
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
|
||||
![](SfButton_images/SfButton_img15.jpeg)
|
||||
|
||||
**Note**: The SfButton does not allow you to animate the image, if the animated image set as FocusedImage, HoverImage, or PressedImage so, to show the animation image inside the button, initialize the animation image (gif image) using the Image property.
|
||||
|
||||
## Show or Hide Focus Rectangle
|
||||
|
||||
A thin dotted rectangular frame can be drawn inside the SfButton when it got focus. This feature can be enabled by setting the [FocusRectangleVisible](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_FocusRectangleVisible) property to true.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Enable the focus rectangle for SfButton
|
||||
sfButton1.FocusRectangleVisible = true;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
|
||||
![](SfButton_images/SfButton_img16.jpeg)
|
||||
|
||||
## Rounded Rectangle Button
|
||||
|
||||
The SfButton with rounded rectangle shape can be implemented programmatically by drawing the border using Paint event.
|
||||
|
||||
To draw the rounded rectangle shape for the SfButton follow the steps:
|
||||
|
||||
1. Raise the Paint event of the SfButton.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Raises the paint event of the SfButton
|
||||
sfButton1.Paint += sfButton1_Paint;
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
2. Calculate the rounded rectangle area for the client area of the button, and set to the region of the SfButton. Draw the border with calculated rounded rectangle area. The Paint event method is as follows.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
private void sfButton1_Paint(object sender, PaintEventArgs e)
|
||||
{
|
||||
//Rounded rectangle corder radius. The radius must be less than 10.
|
||||
int radius = 5;
|
||||
e.Graphics.SmoothingMode = SmoothingMode.AntiAlias;
|
||||
Rectangle rect = new Rectangle(this.sfButton1.ClientRectangle.X + 1,
|
||||
this.sfButton1.ClientRectangle.Y + 1,
|
||||
this.sfButton1.ClientRectangle.Width - 2,
|
||||
this.sfButton1.ClientRectangle.Height - 2);
|
||||
sfButton1.Region = new Region(GetRoundedRect(rect, radius));
|
||||
rect = new Rectangle(rect.X + 1, rect.Y + 1, rect.Width - 2, rect.Height - 2);
|
||||
e.Graphics.DrawPath(new Pen(Color.Red), GetRoundedRect(rect, radius));
|
||||
}
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img17.jpeg)
|
||||
|
||||
Refer to the following sample shows how to implement the rounded rectangle in the SfButton control.
|
||||
|
||||
[Sample](http://www.syncfusion.com/downloads/support/directtrac/general/SFBUTT~1449710690.ZIP#)
|
||||
|
||||
**Note**: When using the previous implementation to draw the rounded rectangle, the border customization properties like Border, HoverBorder, PressedBorder, FocusedBorder, and DisabledBorder does not work.
|
||||
|
||||
## Themes
|
||||
|
||||
The SfButton offers four built-in themes for professional representation as follows:
|
||||
|
||||
* Office2016Colorful
|
||||
* Office2016White
|
||||
* Office2016DarkGray
|
||||
* Office2016Black
|
||||
|
||||
Themes can be applied to the SfButton by using the following steps:
|
||||
|
||||
1. [Load theme assembly](#load-theme-assembly)
|
||||
2. [Apply theme](#apply-theme)
|
||||
|
||||
### Load theme assembly
|
||||
|
||||
The Syncfusion.Office2016Theme.WinForms assembly should be added as reference to set theme for the SfButton in any application.
|
||||
|
||||
Before applying theme to the SfButton, required theme assembly should be loaded.
|
||||
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
using Syncfusion.WinForms.Controls;
|
||||
|
||||
static class Program
|
||||
{
|
||||
/// <summary>
|
||||
/// The main entry point for the application.
|
||||
/// </summary>
|
||||
|
||||
static void Main()
|
||||
{
|
||||
SfSkinManager.LoadAssembly(typeof(Office2016Theme).Assembly);
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
Application.Run(new Form1());
|
||||
}
|
||||
}
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
Imports Syncfusion.WinForms.Controls
|
||||
|
||||
Friend Module Program
|
||||
''' <summary>
|
||||
''' The main entry point for the application.
|
||||
''' </summary>
|
||||
Sub Main()
|
||||
SfSkinManager.LoadAssembly(GetType(Office2016Theme).Assembly)
|
||||
Application.EnableVisualStyles()
|
||||
Application.SetCompatibleTextRenderingDefault(False)
|
||||
Application.Run(New Form1())
|
||||
End Sub
|
||||
End Module
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
### Apply theme
|
||||
|
||||
Appearance of the SfButton can be changed by using the [ThemeName](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_ThemeName).
|
||||
|
||||
#### Office2016Colorful
|
||||
|
||||
This option helps to set the Office2016Colorful Theme.
|
||||
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
// Office2016Colorful
|
||||
|
||||
this.sfButton.ThemeName = "Office2016Colorful";
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
' Office2016Colorful
|
||||
|
||||
Me.sfButton.ThemeName = "Office2016Colorful"
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_o16_colorful.jpg)
|
||||
|
||||
#### Office2016White
|
||||
|
||||
This option helps to set the Office2016White Theme.
|
||||
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
// Office2016White
|
||||
|
||||
this.sfButton.ThemeName = "Office2016White";
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
' Office2016White
|
||||
|
||||
Me.sfButton.ThemeName = "Office2016White"
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_o16_white.jpg)
|
||||
|
||||
#### Office2016DarkGray
|
||||
|
||||
This option helps to set the Office2016DarkGray Theme.
|
||||
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
// Office2016DarkGray
|
||||
|
||||
this.sfButton.ThemeName = "Office2016DarkGray";
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
' Office2016DarkGray
|
||||
|
||||
Me.sfButton.ThemeName = "Office2016DarkGray"
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_o16_darkGray.jpg)
|
||||
|
||||
#### Office2016Black
|
||||
|
||||
This option helps to set the Office2016Black Theme.
|
||||
|
||||
{% tabs %}
|
||||
|
||||
{% highlight C# %}
|
||||
|
||||
// Office2016Black
|
||||
|
||||
this.sfButton.ThemeName = "Office2016Black";
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% highlight VB %}
|
||||
|
||||
' Office2016Black
|
||||
|
||||
Me.sfButton.ThemeName = "Office2016Black"
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_o16_black.jpg)
|
|
@ -0,0 +1,104 @@
|
|||
---
|
||||
layout: post
|
||||
title: Button Content| WindowsForms | Syncfusion
|
||||
description: Button Content
|
||||
platform: WindowsForms
|
||||
control: SfButton
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Button Content
|
||||
|
||||
## Adding Rich Text
|
||||
|
||||
The rich text can be displayed inside the SfButton by enabling the [AllowRichText](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_AllowRichText) property and the proper rich text can be added in the [Text](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Text) property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Enable the rich text support
|
||||
this.sfButton1.AllowRichText = true
|
||||
|
||||
//Adding the rich text value.
|
||||
this.sfButton1.Text = "{\\rtf1\\ansi\\deff0{\\colortbl;\\red0\\green0\\blue0;\\red255\\green0\\blue0;}" +
|
||||
"{\\fonttbl{\\f0 Monotype Corsiva;\r\n}}\\qc\\f0\\fs30 {\\i Italic} {\\b Bold} \\cf2 Red}";
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img6.jpeg)
|
||||
|
||||
**Note**: When the AllowRichText property is false, even if you add the rich text to the Text property, it will draw as normal text inside the button.
|
||||
|
||||
## Wrapping the Text
|
||||
|
||||
The text can be wrapped in the SfButton by setting the [AllowWrapText](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_AllowWrapText) property to true.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initialize the text to SfButton
|
||||
sfButton1.Text = "SfButton with wrap text";
|
||||
|
||||
//Enable the text wrapping
|
||||
sfButton1.AllowWrapText = true;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img7.jpeg)
|
||||
|
||||
**Note**: If the AutoSize property is enabled, the SfButton does not allow you to wrap the text.
|
||||
|
||||
## Trimming and Showing Ellipsis Character
|
||||
|
||||
The ellipsis character can be shown inside the SfButton by enabling the [AllowEllipsis](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_AutoEllipsis) property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Enable AutoEllipsis property to show the ellipsis character.
|
||||
sfButton1.AutoEllipsis = true;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img8.jpeg)
|
||||
|
||||
**Note**: The SfButton will trim the characters only when disabling the AutoSize property and text length should be greater than the button width.
|
||||
|
||||
## Auto Fit the SfButton
|
||||
|
||||
The SfButton allows auto fitting the size based on the content by setting the [AutoSize](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_AutoSize) property to true.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Auto fit the content of SfButton
|
||||
sfButton1.AutoSize = true;
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
## Content Alignment
|
||||
|
||||
This section describes how to change the text and image alignment inside the SfButton.
|
||||
|
||||
### Text
|
||||
|
||||
The text alignment can be changed by initializing any one of the ContentAlignment enumeration value to the TextAlign property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initialize the Top Center alignment to text.
|
||||
sfButton1.TextAlign = ContentAlignment.TopCenter;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
### Image
|
||||
|
||||
The image alignment can be changed by initializing any one of the ContentAlignment enumeration value to the ImageAlign property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initialize the Top Center alignment to Image.
|
||||
sfButton1.ImageAlign = ContentAlignment.TopCenter;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
|
@ -0,0 +1,87 @@
|
|||
---
|
||||
layout: post
|
||||
title: Button Types| WindowsForms | Syncfusion
|
||||
description: Button Types
|
||||
platform: WindowsForms
|
||||
control: SfButton
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Button Types
|
||||
|
||||
This section describes various types of button supported by the SfButton.
|
||||
|
||||
## Text and Image Button
|
||||
|
||||
The text and image can be displayed inside the SfButton by initializing the [Text](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Text) and [Image](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Image) properties.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Adding the text value.
|
||||
this.sfButton1.Text = Print;
|
||||
|
||||
//Adding the image value to SfButton
|
||||
this.sfButton1.Image = Image.FromFile(@"..\..\Data\Image1.png");
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img2.jpeg)
|
||||
|
||||
### Positioning Text and Image
|
||||
|
||||
The text and image positions can be adjusted by using the [TextImageRelation](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_TextImageRelation) property.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Initializing the text and image positions.
|
||||
sfButton1.TextImageRelation = TextImageRelation.ImageBeforeText;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
![](SfButton_images/SfButton_img3.jpeg)
|
||||
|
||||
### Spacing between Text and Image
|
||||
|
||||
The space between the text and image can be adjusted by using the [TextMargin](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_TextMargin) and [ImageMargin](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_ImageMargin) properties.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Adjust the text margin of the SfButton
|
||||
sfButton1.TextMargin = new Padding(3, 3, 3, 3);
|
||||
|
||||
//Adjust the image margin of the SfButton
|
||||
sfButton1.ImageMargin = new Padding(3, 3, 3, 3);
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
## Image Button
|
||||
|
||||
The SfButton can be displayed only with the image by setting the empty string value to the [Text](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Text) property and initialize the image value to the [Image](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Image) property. The size of the image can be changed by using the ImageSize property.
|
||||
|
||||
![](SfButton_images/SfButton_img4.jpeg)
|
||||
|
||||
## Icon Button
|
||||
|
||||
The SfButton can be displayed only with an icon by setting the empty string value to the Text property and initialize the icon value to [Image](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Image) property. You can show the icon button alone by setting the borders to null, and setting the back color of the button same as the background area.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//To show the icon button, initialize the background color same as the screen or background area color.
|
||||
this.IconButton2.Style.BackColor = System.Drawing.Color.White;
|
||||
this.IconButton2.Style.DisabledBackColor = System.Drawing.Color.White;
|
||||
this.IconButton2.Style.FocusedBackColor = System.Drawing.Color.White;
|
||||
this.IconButton2.Style.HoverBackColor = System.Drawing.Color.White;
|
||||
this.IconButton2.Style.HoverBackColor = System.Drawing.Color.White;
|
||||
|
||||
//Sets the border to null for all button states.
|
||||
IconButton2.Style.Border = null;
|
||||
IconButton2.Style.HoverBorder = null;
|
||||
IconButton2.Style.FocusedBorder = null;
|
||||
IconButton2.Style.PressedBorder = null;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
![](SfButton_images/SfButton_img5.jpeg)
|
|
@ -0,0 +1,67 @@
|
|||
---
|
||||
layout: post
|
||||
title: Getting Started| WindowsForms | Syncfusion
|
||||
description: Getting Started
|
||||
platform: WindowsForms
|
||||
control: SfButton
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Getting Started
|
||||
|
||||
## Assembly Deployment
|
||||
|
||||
Refer [control dependencies](https://help.syncfusion.com/windowsforms/control-dependencies#sfbutton) section to get the list of assemblies or NuGet package needs to be added as reference to use the control in any application.
|
||||
|
||||
## Adding SfButton into a Form
|
||||
|
||||
This section describes how to add the SfButton to a form.
|
||||
|
||||
### Through Designer
|
||||
|
||||
To add the SfButton to form, drag and drop the SfButton from the toolbox to the surface of the form designer.
|
||||
|
||||
![](SfButton_images/SfButton_img1.jpeg)
|
||||
|
||||
### Through Code
|
||||
|
||||
To programmatically add the SfButton to form, create a new instance of the SfButton and add it to the form the Controls collection.
|
||||
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Create a new instance of the SfButton control
|
||||
SfButton sfButton1 = new Syncfusion.WinForms.Buttons.SfButton();
|
||||
|
||||
//Initialize the font, location, name, size and text for the SfButton.
|
||||
sfButton1.Font = new System.Drawing.Font("Segoe UI Semibold", 9F);
|
||||
sfButton1.Location = new System.Drawing.Point(60, 62);
|
||||
sfButton1.Name = "sfButton1";
|
||||
sfButton1.Size = new System.Drawing.Size(96, 28);
|
||||
sfButton1.Text = "sfButton1";
|
||||
|
||||
//Add the SfButton into the form.
|
||||
this.Controls.Add(sfButton1);
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
## Performing Action on the SfButton Click
|
||||
|
||||
The SfButton allows adding the click event in two ways:
|
||||
|
||||
1. Adding the click event by double clicking the SfButton in designer.
|
||||
2. Programmatically raises the clicking event of the SfButton.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Raises the click event of SfButton
|
||||
sfButton1.Click += sfButton1_Click;
|
||||
|
||||
//Perform any action on click action method
|
||||
private void sfButton1_Click(object sender, EventArgs e)
|
||||
{
|
||||
MessageBox.Show("SfButton was clicked");
|
||||
}
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
|
@ -0,0 +1,62 @@
|
|||
---
|
||||
layout: post
|
||||
title: How To | WindowsForms | Syncfusion
|
||||
description: How To
|
||||
platform: WindowsForms
|
||||
control: SfButton
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# How To
|
||||
|
||||
## Set the SfButton as Accept or Cancel Button to the Form
|
||||
|
||||
This section describes how to set the SfButton as Accept or Cancel button to the form.
|
||||
|
||||
### Accept Button
|
||||
|
||||
The SfButton can be set as Accept button to a form by setting the AcceptButton property of the form.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Sets the SfButton to the Accept button of form
|
||||
this.AcceptButton = sfButton1;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
**Note**: The Accept button might not be activated if the currently selected control on the form intercepts the ENTER key and processes it.
|
||||
|
||||
### Cancel Button
|
||||
|
||||
The SfButton can be set as Cancel button to a form by setting the CancelButton property of the form.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Sets the SfButton to the Cancel button of form
|
||||
this.CancelButton = sfButton2;
|
||||
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
**Note**: The Cancel button may not work if another control on the form intercepts the ESC key.
|
||||
|
||||
## Show the Tooltip on Mouse Hover
|
||||
|
||||
The SfToolTip can be shown on the SfButton when the mouse hovering. Follow the steps to perform this feature:
|
||||
|
||||
1. Create a new instance of SfToolTip.
|
||||
2. Initialize the SfToolTip to the SfButton by using the SetToolTip method.
|
||||
|
||||
{% tabs %}
|
||||
{% highlight c# %}
|
||||
//Creating new instance for the SfToolTip.
|
||||
SfToolTip sfToolTip1 = new SfToolTip();
|
||||
|
||||
//Initialize the SfToolTip to the SfButton to show the information.
|
||||
sfToolTip1.SetToolTip(this.sfButton1, " The ToolTip information of the Button control.");
|
||||
{% endhighlight %}
|
||||
{% endtabs %}
|
||||
|
||||
|
||||
![](SfButton_images/SfButton_img18.jpeg)
|
|
@ -0,0 +1,245 @@
|
|||
---
|
||||
layout: post
|
||||
title: Overview | Button | Syncfusion
|
||||
description: This section explains about the advanced button control for windows forms and it's important key features
|
||||
platform: WindowsForms
|
||||
control: SfButton
|
||||
documentation: ug
|
||||
---
|
||||
|
||||
# Overview
|
||||
|
||||
The SfButton is an advanced button control capable of displaying text and image with various customizations. It provide options to customize the text, image, border, and appearance in all states of the button.
|
||||
|
||||
## Key Features
|
||||
|
||||
Following are the key features of the SfButton:
|
||||
|
||||
* Appearance: Supports customizing the appearance in all button states (hover, pressed, focused, and disabled states).
|
||||
|
||||
* Image: Supports customizing the image in all button states.
|
||||
|
||||
* Background image: Supports displaying the image in the background of the button.
|
||||
|
||||
* Rich text: Supports displaying the rich text inside the SfButton.
|
||||
|
||||
* Wrap text and trimming: Supports wrapping and trimming the button text.
|
||||
|
||||
* AutoSize: Supports adjusting the size of the button based on the content.
|
||||
|
||||
## Choose between different button controls
|
||||
|
||||
Syncfusion WinForms suite comes up with the following different buttons:
|
||||
|
||||
* [SfButton](https://www.syncfusion.com/winforms-ui-controls/button)
|
||||
* [ButtonAdv](https://help.syncfusion.com/wpf/buttonadv/overview)
|
||||
* [ButtonEdit](https://www.syncfusion.com/winforms-ui-controls/buttonedit)
|
||||
* [ToggleButton](https://www.syncfusion.com/winforms-ui-controls/toggle-button)
|
||||
* [SplitButton](https://www.syncfusion.com/winforms-ui-controls/split-button)
|
||||
|
||||
### SfButton
|
||||
|
||||
[SfButton](https://help.syncfusion.com/windowsforms/sfbutton/overview) is an advanced button control capable of displaying text and image with various customizations. This provides options to customize the text, image, border, and appearance in all states of the button.
|
||||
|
||||
### ButtonAdv
|
||||
|
||||
[ButtonAdv](https://help.syncfusion.com/windowsforms/buttonadv/overview) is an advanced button control capable of displaying images with different alignments and various border styles. This can be configured in any predefined [ButtonTypes](https://help.syncfusion.com/cr/windowsforms/Syncfusion.Windows.Forms.ButtonAdv.html#Syncfusion_Windows_Forms_ButtonAdv_ButtonType) such as Calculator, Up, Down, and so on. This can also afford XP or Office style.
|
||||
|
||||
### ButtonEdit
|
||||
|
||||
The [Button Edit](https://help.syncfusion.com/windowsforms/buttonedit/overview) control embeds a text box control with collection of button controls that can be customized to create many commonly used interfaces such as file or folder browser or drop-down text control. You can also implement file picker and folder browser.
|
||||
|
||||
### ToggleButton
|
||||
|
||||
The [ToggleButton](https://help.syncfusion.com/windowsforms/togglebutton/overview) control allows you to toggle between two states (active and inactive) opposite to each other in terms of behavior.
|
||||
|
||||
### SplitButton
|
||||
|
||||
The [SplitButton](https://help.syncfusion.com/windowsforms/splitbutton/overview) control allows you to create drop-down button-like interface that is a combination of regular button and drop-down list. You can use this control when you need a single control with multiple options. For example, you can use this control to create a button to set font and list available in the font family of drop-down list.
|
||||
|
||||
### SfButton vs ButtonAdv
|
||||
|
||||
Both SfButton and ButtonAdv controls are used for same purposes. But, the SfButton control offers rich set of features over ButtonAdv. To customize the appearance of all button states, use the SfButton control. To use the predefined button types such as Calculator, Up, Down, and so on, use the ButtonAdv control. Comparatively, the performance of SfButton control is better than ButtonAdv control.
|
||||
|
||||
You can see some of the specific API differences between ButtonAdv and SfButton as follows.
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
{{'**SfButton**'| markdownify }}
|
||||
</td>
|
||||
<td>
|
||||
{{'**ButtonAdv**'| markdownify }}
|
||||
</td>
|
||||
<td>
|
||||
{{'**Description**'| markdownify }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Text
|
||||
</td>
|
||||
<td>
|
||||
Text
|
||||
</td>
|
||||
<td>
|
||||
Displays the text in the button.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Image
|
||||
</td>
|
||||
<td>
|
||||
Image
|
||||
</td>
|
||||
<td>
|
||||
Displays the image in the button.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
BackgroundImage
|
||||
</td>
|
||||
<td>
|
||||
BackgroundImage
|
||||
</td>
|
||||
<td>
|
||||
Sets the background image to the button.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
TextImageRelation
|
||||
</td>
|
||||
<td>
|
||||
TextImageRelation
|
||||
</td>
|
||||
<td>
|
||||
Sets the position of image and text.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
TextAlign
|
||||
</td>
|
||||
<td>
|
||||
TextAlign
|
||||
</td>
|
||||
<td>
|
||||
Sets the alignment of text inside the button.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
ImageAlign
|
||||
</td>
|
||||
<td>
|
||||
ImageAlign
|
||||
</td>
|
||||
<td>
|
||||
Sets the alignment of image into the button.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
FocusRectangleVisible
|
||||
</td>
|
||||
<td>
|
||||
KeepFocusRectangle
|
||||
</td>
|
||||
<td>
|
||||
Draws a thin dotted rectangular frame inside the button when it got focus.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Border
|
||||
</td>
|
||||
<td>
|
||||
BorderStyleAdv
|
||||
</td>
|
||||
<td>
|
||||
Draws the border around the button.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
ThemeName
|
||||
</td>
|
||||
<td>
|
||||
Appearance
|
||||
</td>
|
||||
<td>
|
||||
Applies visual styles for button.
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
The following list of features are in SfButton over ButtonAdv.
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
{{'**Feature**'| markdownify }}
|
||||
</td>
|
||||
<td>
|
||||
{{'**Description**'| markdownify }}
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Appearance customization
|
||||
</td>
|
||||
<td>
|
||||
Changes the {{'[appearance](https://help.syncfusion.com/windowsforms/sfbutton/appearance#customizing-appearance-based-on-button-state)'| markdownify }} such as back color, fore color, border, and image in all button states (hover, pressed, focus and disable states).
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Animation image
|
||||
</td>
|
||||
<td>
|
||||
Loads the {{'[GIF](https://help.syncfusion.com/windowsforms/sfbutton/appearance#animating-the-image)'| markdownify }} image.
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Rich text
|
||||
</td>
|
||||
<td>
|
||||
Displays the rich text inside SfButton by enabling the {{'[AllowRichText](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_AllowRichText)'| markdownify }} property. This can be added to the {{'[Text](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.Controls.SfButton.html#Syncfusion_WinForms_Controls_SfButton_Text)'| markdownify }} property.
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Spacing between image and text
|
||||
|
||||
</td>
|
||||
<td>
|
||||
Adjusts space between image and text. Refer to {{'[here](https://help.syncfusion.com/windowsforms/sfbutton/button-types#spacing-between-text-and-image)'| markdownify }} for details.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Wrap Text
|
||||
</td>
|
||||
<td>
|
||||
Wraps the text by using the {{'[WrapText](https://help.syncfusion.com/windowsforms/sfbutton/button-content#wrapping-the-text)'| markdownify }} property in SfButton.
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Text Trimming
|
||||
</td>
|
||||
<td>
|
||||
Trims the text by using the {{'[AllowEllipse](https://help.syncfusion.com/windowsforms/sfbutton/button-content#trimming-and-showing-ellipsis-character)'| markdownify }} property.
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
После Ширина: | Высота: | Размер: 38 KiB |
После Ширина: | Высота: | Размер: 2.9 KiB |
После Ширина: | Высота: | Размер: 2.5 KiB |
После Ширина: | Высота: | Размер: 1.3 KiB |
После Ширина: | Высота: | Размер: 1.6 KiB |
После Ширина: | Высота: | Размер: 2.5 KiB |
После Ширина: | Высота: | Размер: 1.6 KiB |
После Ширина: | Высота: | Размер: 3.0 KiB |
После Ширина: | Высота: | Размер: 2.5 KiB |
После Ширина: | Высота: | Размер: 7.0 KiB |
После Ширина: | Высота: | Размер: 1.8 KiB |
После Ширина: | Высота: | Размер: 18 KiB |
После Ширина: | Высота: | Размер: 2.2 KiB |
После Ширина: | Высота: | Размер: 1.7 KiB |
После Ширина: | Высота: | Размер: 3.5 KiB |
После Ширина: | Высота: | Размер: 2.6 KiB |
После Ширина: | Высота: | Размер: 6.1 KiB |
После Ширина: | Высота: | Размер: 2.3 KiB |
После Ширина: | Высота: | Размер: 2.0 KiB |