ShapeCollection
Genel Bakış
ShapeCollection C++ için Aspose.Slides FOSS’de bir sınıf.
Bir slaytta şekillerin toplanmasını yönetir. İki modda çalışır: - Basit mod (varsayılan): şekiller sadece bellekte yönetilir. - XML Destekli Mod (init_internal’den sonra): şekiller, tembel önbelleğe alındığında slaytın spTree XML’inden yüklenir ve süreklendirilir.
Bu sınıf, C ++ programlarında ShapeCollection nesnelerle çalışmak için 49 yöntem sağlar. Kullanılabilir yöntemler şunlardır: ShapeCollection, Table, add_auto_shape, add_auto_shape_impl, add_connector, add_connector_impl, add_picture_frame, add_picture_frame_impl, add_table, add_table_impl, as_i_collection, as_i_enumerable, ve 25 ek yöntem. C ++ için FOSS paketini yükledikten sonra tüm kamu üyeleri herhangi bir C++ uygulamasına erişilebilir. Özellikleri: ShapeCollection, Table.
Özellikler
| Adı: | Tip: | Access | Açıklama: |
|---|---|---|---|
ShapeCollection | ShapeCollection | Oku . | Şekil koleksiyonunu alır. |
Table | Table | Oku . | Tabloyu alır. |
Yöntemler
| Signature | Açıklama: |
|---|---|
ShapeCollection() → ShapeCollection | Mülkiyet koleksiyonun kendisini açar. |
Table() → Table | Özellik, koleksiyonla ilişkili tablo şekline erişim sağlar. |
Table() → Table | |
ShapeCollection() | |
ShapeCollection() | |
init_internal(slide_part: Internal::pptx::SlidePart, parent_slide: IBaseSlide) | XML destekli moduna girerek bir slayt bölümünden başlatın. |
parent_group() → IGroupShape | Ana grup şeklini veya üst düzeyde ise nullptr’i gönderir. |
as_i_collection() → IShapeCollection | Bu koleksiyonu genel bir koleksion arayüzü olarak gönderir. |
as_i_enumerable() → IShapeCollection | Bu koleksiyonu genel bir sayılabilir arayüz olarak gönderir. |
size() → std::size_t | Şekil sayısını gönderir. |
to_array() → std::vector<Shape*> | Tüm şekilleri sahip olmayan işaretler olarak gönderir. |
to_array(start_index: std::size_t, count: std::size_t) → std::vector<Shape*> | Tüm şekilleri sahip olmayan işaretler olarak gönderir. |
reorder(new_index: std::size_t, shape: Shape) | Bir şekli belirtilen konuma (z sırası) taşır. |
reorder(index: std::size_t, shapes: std::span<Shape*>) | Bir şekli belirtilen konuma (z sırası) taşır. |
add_auto_shape(type: ShapeType, x: double, y: double, width: double, height: double) → AutoShape | Koleksiyona bir AutoShape ekler. |
add_auto_shape(type: ShapeType, x: double, y: double, width: double, height: double, create_from_template: bool) → AutoShape | Koleksiyona bir AutoShape ekler. |
insert_auto_shape(index: std::size_t, type: ShapeType, x: double, y: double, width: double, height: double) → AutoShape | Belirtilen indeksde AutoShape ekler. |
insert_auto_shape(index: std::size_t, type: ShapeType, x: double, y: double, width: double, height: double, create_from_template: bool) → AutoShape | Belirtilen indeksde AutoShape ekler. |
add_connector(type: ShapeType, x: double, y: double, width: double, height: double) → Connector | Koleksiyona bir bağlantı ekler. |
add_connector(type: ShapeType, x: double, y: double, width: double, height: double, create_from_template: bool) → Connector | Koleksiyona bir bağlantı ekler. |
insert_connector(index: std::size_t, type: ShapeType, x: double, y: double, width: double, height: double) → Connector | Belirtilen indeksde bir bağlantı ekler. |
insert_connector(index: std::size_t, type: ShapeType, x: double, y: double, width: double, height: double, create_from_template: bool) → Connector | Belirtilen indeksde bir bağlantı ekler. |
index_of(shape: Shape) → std::ptrdiff_t | Bir şeklin sıfır tabanlı indeksini veya -1’i bulunmazsa gönderir. |
add_picture_frame(type: ShapeType, x: double, y: double, width: double, height: double, image: PPImage) → PictureFrame | Koleksiyona bir PictureFrame ekler. |
insert_picture_frame(index: std::size_t, type: ShapeType, x: double, y: double, width: double, height: double, image: PPImage) → PictureFrame | Belirtilen indeksde PictureFrame ekler. |
add_table(x: double, y: double, column_widths: std::span<const double>, row_heights: std::span<const double>) → Table | Koleksiyona bir masa ekler. |
insert_table(index: std::size_t, x: double, y: double, column_widths: std::span<const double>, row_heights: std::span<const double>) → Table | Belirtilen indeksde bir tablo ekler. |
remove(shape: Shape) | Referans yoluyla koleksiyondan bir şekli kaldırır. |
remove_at(index: std::size_t) | Verilen indeksdeki şekli kaldırır. |
clear() | Tüm şekilleri ortadan kaldırır. |
table_count() → std::size_t | Koleksiyonun tablo sayısını gönderir. |
table_at(index: std::size_t) → Table | Tabloyu verilen indeksde gönderir. |
table_at(index: std::size_t) → Table | Tabloyu verilen indeksde gönderir. |
begin() → iterator | Bir iteratörü ilk şekle döndürür. |
end() → iterator | Son şeklin ötesinde bir iteratör döndürür. |
begin() → const_iterator | |
end() → const_iterator | |
get_sp_tree() → pugi::xml_node | Slayt XML içinden spTree öğesini alın. |
load_shapes() | XML’den tüm şekilleri yükle ve iç önbellekleri doldur. Önbelleği geçerli ise işlem yok. |
invalidate_cache() | Şekil önbelleğini iptal et, bir sonraki erişimde yeniden yüklenmeye zorla. |
save_to_part() | Değişiklikleri slayt bölümüne kaydet. |
next_shape_id() → int | SpTree’de bir sonraki mevcut şekil kimliğini bulun. |
build_auto_shape_xml(sp: pugi::xml_node, shape_id: int, name: std::string_view, type: ShapeType, x: double, y: double, w: double, h: double, create_from_template: bool) | Yeni bir AutoShape elemanı için XML içeriği oluşturun. |
build_connector_xml(cxn_sp: pugi::xml_node, shape_id: int, name: std::string_view, type: ShapeType, x: double, y: double, w: double, h: double, create_from_template: bool) | Yeni bir bağlantı elemanı (cxnSp) için XML içeriği oluşturun. |
add_auto_shape_impl(index: std::optional<std::size_t>, type: ShapeType, x: double, y: double, w: double, h: double, create_from_template: bool) → AutoShape | add_auto_shape ve insert_ auto_ shape için temel uygulama. |
add_connector_impl(index: std::optional<std::size_t>, type: ShapeType, x: double, y: double, w: double, h: double, create_from_template: bool) → Connector | add_connector ve insert_ connector için temel uygulama. |
add_picture_frame_impl(index: std::optional<std::size_t>, type: ShapeType, x: double, y: double, w: double, h: double, image: PPImage) → PictureFrame | add_picture_frame ve insert_image_frames için temel uygulama. |
add_table_impl(index: std::optional<std::size_t>, x: double, y: double, column_widths: std::span<const double>, row_heights: std::span<const double>) → Table | Add_table ve insert_ table için temel uygulama. |
reorder_single(new_index: std::size_t, shape: Shape) | Tek bir şekli XML ve önbelleğinde yeni bir konuma yeniden düzenleyin. |