Class PdfUnorderedMarker
Represents bullet for the list.
Inherited Members
Namespace: Syncfusion.Pdf.Lists
Assembly: Syncfusion.Pdf.Portable.dll
Syntax
public class PdfUnorderedMarker : PdfMarker
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
//Set the marker style
list.Marker.Style = PdfUnorderedMarkerStyle.Disk;
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
'Set the marker style
list.Marker.Style = PdfUnorderedMarkerStyle.Disk
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
Constructors
PdfUnorderedMarker(PdfImage)
Initializes a new instance of the PdfUnorderedMarker class.
Declaration
public PdfUnorderedMarker(PdfImage image)
Parameters
Type | Name | Description |
---|---|---|
PdfImage | image | The image of the marker. |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
list.Marker = new PdfUnorderedMarker(new PdfBitmap("Bullet.jpg"));
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
list.Marker = New PdfUnorderedMarker(New PdfBitmap("Bullet.jpg"))
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
See Also
PdfUnorderedMarker(PdfTemplate)
Initializes a new instance of the PdfUnorderedMarker class.
Declaration
public PdfUnorderedMarker(PdfTemplate template)
Parameters
Type | Name | Description |
---|---|---|
PdfTemplate | template | Template of the marker. |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
//Create a new PDF template instance.
PdfTemplate template = new PdfTemplate(100, 100);
template.Graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(0, 0, 100, 100));
//Set template to marker.
list.Marker = new PdfUnorderedMarker(template);
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
'Create a new PDF template instance.
Dim template As PdfTemplate = New PdfTemplate(100, 100)
template.Graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(0, 0, 100, 100))
'Set template to marker.
list.Marker = New PdfUnorderedMarker(template)
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
PdfUnorderedMarker(PdfUnorderedMarkerStyle)
Initializes a new instance of the PdfUnorderedMarker class.
Declaration
public PdfUnorderedMarker(PdfUnorderedMarkerStyle style)
Parameters
Type | Name | Description |
---|---|---|
PdfUnorderedMarkerStyle | style | The style of the marker. |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
list.Marker = new PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk);
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
list.Marker = New PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk)
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
See Also
PdfUnorderedMarker(String, PdfFont)
Initializes a new instance of the PdfUnorderedMarker class.
Declaration
public PdfUnorderedMarker(string text, PdfFont font)
Parameters
Type | Name | Description |
---|---|---|
System.String | text | The text of the marker. |
PdfFont | font | Marker font. |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
list.Marker = new PdfUnorderedMarker("list", font);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
list.Marker = New PdfUnorderedMarker("list", font)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
See Also
Properties
Image
Gets or sets image of the marker.
Declaration
public PdfImage Image { get; set; }
Property Value
Type |
---|
PdfImage |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
//Set the list image
list.Marker.Image = new PdfBitmap("Bullet.jpg");
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
'Set the list image
list.Marker.Image = new PdfBitmap("Bullet.jpg")
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
See Also
Style
Gets or sets the style.
Declaration
public PdfUnorderedMarkerStyle Style { get; set; }
Property Value
Type |
---|
PdfUnorderedMarkerStyle |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
//Set the marker style
list.Marker.Style = PdfUnorderedMarkerStyle.Disk;
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
'Set the marker style
list.Marker.Style = PdfUnorderedMarkerStyle.Disk
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
See Also
Template
Gets or sets template of the marker.
Declaration
public PdfTemplate Template { get; set; }
Property Value
Type |
---|
PdfTemplate |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
//Create a new PDF template instance.
PdfTemplate template = new PdfTemplate(100, 100);
template.Graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(0, 0, 100, 100));
//Set template to marker.
list.Marker.Template = template;
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
'Create a new PDF template instance.
Dim template As PdfTemplate = New PdfTemplate(100, 100)
template.Graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(0, 0, 100, 100))
'Set template to marker.
list.Marker.Template = template
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")
Text
Gets or sets marker text.
Declaration
public string Text { get; set; }
Property Value
Type |
---|
System.String |
Examples
//Create a new PDf document
PdfDocument document = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = document.Pages.Add();
PdfGraphics graphics = page.Graphics;
//Create a unordered list
PdfUnorderedList list = new PdfUnorderedList();
//Set the marker Text
list.Marker.Text = "List: ";
//Create a font and write title
PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold);
//Create string format
PdfStringFormat format = new PdfStringFormat();
format.LineSpacing = 20f;
font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold);
//Apply formattings to list
list.Font = font;
list.StringFormat = format;
//Set list indent
list.Indent = 10;
//Add items to the list
list.Items.Add("List of Essential Studio products");
list.Items.Add("IO products");
//Set text indent
list.TextIndent = 10;
//Draw list
list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height));
document.Save("UnOrderList.pdf");
'Create a new PDf document
Dim document As PdfDocument = New PdfDocument()
'Create a page
Dim page As PdfPage = document.Pages.Add()
Dim graphics As PdfGraphics = page.Graphics
'Create a unordered list
Dim list As PdfUnorderedList = New PdfUnorderedList()
'Set the marker Text
list.Marker.Text = "List: "
'Create a font and write title
Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)
'Create string format
Dim format As PdfStringFormat = New PdfStringFormat()
format.LineSpacing = 20f
font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold)
'Apply formattings to list
list.Font = font
list.StringFormat = format
'Set list indent
list.Indent = 10
'Add items to the list
list.Items.Add("List of Essential Studio products")
list.Items.Add("IO products")
'Set text indent
list.TextIndent = 10
'Draw list
list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height))
document.Save("UnOrderList.pdf")