delete_picture_bullet method
delete_picture_bullet()
Deletes picture bullet for the current list level.
def delete_picture_bullet(self):
...
Remarks
Default bullet will be shown after deleting.
Examples
Shows how to set a custom image icon for list item labels.
doc = aw.Document()
list = doc.lists.add(aw.lists.ListTemplate.BULLET_CIRCLE)
# Create a picture bullet for the current list level, and set an image from a local file system
# as the icon that the bullets for this list level will display.
list.list_levels[0].create_picture_bullet()
list.list_levels[0].image_data.set_image(IMAGE_DIR + "Logo icon.ico")
self.assertTrue(list.list_levels[0].image_data.has_image)
builder = aw.DocumentBuilder(doc)
builder.list_format.list = list
builder.writeln("Hello world!")
builder.write("Hello again!")
doc.save(ARTIFACTS_DIR + "Lists.create_picture_bullet.docx")
list.list_levels[0].delete_picture_bullet()
self.assertIsNone(list.list_levels[0].image_data)
See Also
- module aspose.words.lists
- class ListLevel