SlideCollection

SlideCollection

Overview

SlideCollection is a class in Aspose.Slides FOSS for C++.

Manages the collection of slides in a presentation.

This class provides 35 methods for working with SlideCollection objects in C++ programs. Available methods include: SlideCollection, add_clone, add_empty_slide, add_empty_slide_internal, as_i_collection, as_i_enumerable, begin, clone_master_chain_for_slide, clone_slide_internal, const_iterator, end, find_layout_by_type, and 13 additional methods. All public members are accessible to any C++ application after installing the Aspose.Slides FOSS for C++ package. Properties: SlideCollection, const_iterator, iterator.

Properties

NameTypeAccessDescription
SlideCollectionSlideCollectionReadGets the slide collection.
iteratoriteratorReadGets the iterator.
const_iteratorconst_iteratorReadGets the const iterator.

Methods

SignatureDescription
SlideCollection()SlideCollectionConstructs a slide collection for the given presentation.
iterator()iteratorReturns an iterator to the beginning of the slide collection
iterator()iterator
const_iterator()const_iteratorProperty gives a const iterator to the slide collection
const_iterator()const_iterator
SlideCollection()Constructs a slide collection for the given presentation.
as_i_collection()ISlideCollectionReturns this collection as a generic collection interface.
as_i_enumerable()ISlideCollectionReturns this collection as a generic enumerable interface.
size()std::size_tReturns the number of slides.
add_clone(source_slide: Slide)SlideAdds a clone of the given slide to the end of the collection.
add_clone(source_slide: Slide, dest_layout: ILayoutSlide)SlideAdds a clone of the given slide to the end of the collection.
add_clone(source_slide: Slide, dest_master: IMasterSlide, allow_clone_missing_layout: bool)SlideAdds a clone of the given slide to the end of the collection.
insert_clone(index: std::size_t, source_slide: Slide)SlideInserts a clone of the given slide at the specified index.
insert_clone(index: std::size_t, source_slide: Slide, dest_layout: ILayoutSlide)SlideInserts a clone of the given slide at the specified index.
insert_clone(index: std::size_t, source_slide: Slide, dest_master: IMasterSlide, allow_clone_missing_layout: bool)SlideInserts a clone of the given slide at the specified index.
to_array()std::vector<Slide*>Returns all slides as a vector of non-owning pointers.
to_array(start_index: std::size_t, count: std::size_t)std::vector<Slide*>Returns all slides as a vector of non-owning pointers.
add_empty_slide(layout: ILayoutSlide)SlideAdds an empty slide with the given layout to the end.
insert_empty_slide(index: std::size_t, layout: ILayoutSlide)SlideInserts an empty slide with the given layout at the specified index.
remove(slide: Slide)Removes the given slide from the collection.
remove_at(index: std::size_t)Removes the slide at the given index.
index_of(slide: Slide)std::ptrdiff_tReturns the zero-based index of a slide, or -1 if not found.
begin()iterator
end()iterator
begin()const_iterator
end()const_iterator
init_internal(presentation: Presentation, package: Internal::opc::OpcPackage, presentation_part_name: std::string_view, slide_references: std::vector<SlideReference>, layout_resolver: LayoutResolver)Internal initialization for OPC-based loading. Replaces the default slide list with slides resolved from the package.
add_empty_slide_internal(layout: ILayoutSlide, index: std::ptrdiff_t)SlideInternal implementation for adding/inserting an empty slide at OPC level.
clone_slide_internal(source_slide: Slide, index: std::ptrdiff_t, allow_clone_missing_layout: bool)SlideInternal implementation for cloning a slide at OPC level.
get_next_slide_file_number()intFind the next available slide file number in the package.
find_matching_layout(source_slide: Slide, dest_master: IMasterSlide, allow_clone: bool)std::optional<std::string>Find a matching layout in the destination master for the source slide.
find_layout_by_type(source_layout: ILayoutSlide)std::optional<std::string>Find a layout in the destination presentation matching the source layout type.
find_layout_from_layout_slides(source_layout: ILayoutSlide)std::optional<std::string>Find matching layout by name using layout_slides.
get_first_layout_part_name()std::optional<std::string>Get the first available layout part name in the destination presentation.
clone_master_chain_for_slide(source_slide: Slide, source_layout: ILayoutSlide)std::optional<std::string>Clone the master slide chain for a slide being cloned from another presentation.

See Also