Back to Devexpress

NumberingListBullet Class

officefileapi-devexpress-dot-docs-dot-presentation-7802871e.md

latest4.9 KB
Original Source

NumberingListBullet Class

A bullet that allows you to create a numbered list.

Namespace : DevExpress.Docs.Presentation

Assembly : DevExpress.Docs.Presentation.v25.2.dll

NuGet Package : DevExpress.Docs.Presentation

Declaration

csharp
public class NumberingListBullet :
    ListBullet
vb
Public Class NumberingListBullet
    Inherits ListBullet

The following members return NumberingListBullet objects:

Remarks

The following code snippet configures numbering bullets for three text paragraphs:

csharp
using DevExpress.Docs.Presentation;
using System.Drawing;

namespace PresentationApiSample;

public class Program {
    public static void Main(string[] _) {

        Presentation presentation = new Presentation();
        presentation.Slides.Clear();

        Slide slide = new Slide(SlideLayoutType.Blank);
        presentation.Slides.Add(slide);

        Shape shape = new Shape(ShapeType.Rectangle, 0, 0, presentation.SlideSize.Width, presentation.SlideSize.Height);
        slide.Shapes.Add(shape);
        shape.Fill = new SolidFill(Color.White);
        shape.Outline.Fill = new SolidFill(Color.White);
        shape.TextArea.Level1ParagraphProperties.TextProperties.Fill = new SolidFill(Color.Black);
        shape.TextArea.Paragraphs.Clear();

        NumberingListBullet n_bullet = new NumberingListBullet(NumberingListBulletFormat.WideBlackCircledNumber, 1);

        TextParagraph paragraph1 = new TextParagraph();
        paragraph1.Properties.ListBullet = n_bullet;
        paragraph1.Text = "Paragraph 1";
        shape.TextArea.Paragraphs.Add(paragraph1);

        TextParagraph paragraph2 = new TextParagraph();
        paragraph2.Properties.ListBullet = n_bullet;
        paragraph2.Text = "Paragraph 2";
        shape.TextArea.Paragraphs.Add(paragraph2);

        NumberingListBullet n_bullet2 = new NumberingListBullet(NumberingListBulletFormat.DoubleByteNumberPlain, 1);

        TextParagraph paragraph3 = new TextParagraph();
        paragraph3.Properties.ListBullet = n_bullet2;
        paragraph3.Text = "Paragraph 3";
        shape.TextArea.Paragraphs.Add(paragraph3);

    }
}
vb
Imports DevExpress.Docs.Presentation
Imports System.Drawing

Namespace PresentationApiSample

    Public Class Program
        Public Shared Sub Main(__ As String())

            Dim presentation As Presentation = New Presentation()
            presentation.Slides.Clear()

            Dim slide As Slide = New Slide(SlideLayoutType.Blank)
            presentation.Slides.Add(slide)

            Dim shape As Shape = New Shape(ShapeType.Rectangle, 0, 0, presentation.SlideSize.Width, presentation.SlideSize.Height)
            slide.Shapes.Add(shape)
            shape.Fill = New SolidFill(Color.White)
            shape.Outline.Fill = New SolidFill(Color.White)
            shape.TextArea.Level1ParagraphProperties.TextProperties.Fill = New SolidFill(Color.Black)
            shape.TextArea.Paragraphs.Clear()

            Dim n_bullet As NumberingListBullet = New NumberingListBullet(NumberingListBulletFormat.WideBlackCircledNumber, 1)

            Dim paragraph1 As TextParagraph = New TextParagraph()
            paragraph1.Properties.ListBullet = n_bullet
            paragraph1.Text = "Paragraph 1"
            shape.TextArea.Paragraphs.Add(paragraph1)

            Dim paragraph2 As TextParagraph = New TextParagraph()
            paragraph2.Properties.ListBullet = n_bullet
            paragraph2.Text = "Paragraph 2"
            shape.TextArea.Paragraphs.Add(paragraph2)

            Dim n_bullet2 As NumberingListBullet = New NumberingListBullet(NumberingListBulletFormat.DoubleByteNumberPlain, 1)

            Dim paragraph3 As TextParagraph = New TextParagraph()
            paragraph3.Properties.ListBullet = n_bullet2
            paragraph3.Text = "Paragraph 3"
            shape.TextArea.Paragraphs.Add(paragraph3)

        End Sub
    End Class
End Namespace

Implements

ICloneable

Inheritance

Object PresentationObject ListBullet NumberingListBullet

See Also

NumberingListBullet Members

DevExpress.Docs.Presentation Namespace