स्मार्टआर्ट
Contents
[
Hide
]
यह लेख बताता है कि Aspose.Slides for C++ का उपयोग करके SmartArt ग्राफ़िक्स को कैसे जोड़ें, उन तक कैसे पहुँचें, उन्हें कैसे हटाएँ, और लेआउट कैसे बदलें।
SmartArt जोड़ें
static void AddSmartArt()
{
auto presentation = MakeObject<Presentation>();
auto slide = presentation->get_Slide(0);
auto smartArt = slide->get_Shapes()->AddSmartArt(50, 50, 400, 300, SmartArtLayoutType::BasicProcess);
presentation->Dispose();
}
SmartArt तक पहुँचें
स्लाइड पर पहला SmartArt ऑब्जेक्ट प्राप्त करें।
static void AccessSmartArt()
{
auto presentation = MakeObject<Presentation>();
auto slide = presentation->get_Slide(0);
auto smartArt = slide->get_Shapes()->AddSmartArt(50, 50, 400, 300, SmartArtLayoutType::BasicProcess);
auto firstSmartArt = SharedPtr<ISmartArt>();
for (auto&& shape : slide->get_Shapes())
{
if (ObjectExt::Is<ISmartArt>(shape))
{
firstSmartArt = ExplicitCast<ISmartArt>(shape);
break;
}
}
presentation->Dispose();
}
SmartArt हटाएँ
स्लाइड से एक SmartArt आकार हटाएँ।
static void RemoveSmartArt()
{
auto presentation = MakeObject<Presentation>();
auto slide = presentation->get_Slide(0);
auto smartArt = slide->get_Shapes()->AddSmartArt(50, 50, 400, 300, SmartArtLayoutType::BasicProcess);
slide->get_Shapes()->Remove(smartArt);
presentation->Dispose();
}
SmartArt लेआउट बदलें
मौजूदा SmartArt ग्राफ़िक के लेआउट प्रकार को अपडेट करें।
static void ChangeSmartArtLayout()
{
auto presentation = MakeObject<Presentation>();
auto slide = presentation->get_Slide(0);
auto smartArt = slide->get_Shapes()->AddSmartArt(50, 50, 400, 300, SmartArtLayoutType::BasicBlockList);
smartArt->set_Layout(SmartArtLayoutType::VerticalPictureList);
presentation->Dispose();
}