est-il un moyen de créer des styles dans PowerPoint VSTO au format texte, quelque chose semblable à ce qui est possible avec document Word:Création de styles personnalisés
// document is of type Microsoft.Office.Interop.Word.Document
Style sectionHeadingExt = document.Styles.Add("myStyle");
sectionHeadingExt.set_BaseStyle(SectionHeadingInt);
sectionHeadingExt.Font.Size = 14;
sectionHeadingExt.Font.Color = WdColor.wdColorBlack;
sectionHeadingExt.Font.Bold = (int)MsoTriState.msoFalse;
sectionHeadingExt.ParagraphFormat.LineSpacingRule = WdLineSpacing.wdLineSpaceMultiple;
sectionHeadingExt.ParagraphFormat.LineSpacing = _application.LinesToPoints((float)1.11);
sectionHeadingExt.ParagraphFormat.SpaceBefore = 0;
sectionHeadingExt.ParagraphFormat.SpaceAfter = 0;
Je dois créer un onglet personnalisé, ajoutez un bouton là et quand ce bouton est cliqué, je dois formater le paragraphe sélectionné en conséquence:
GetCurrentParagraph().set_Style("myStyle");
Je l'ai fait dans Word AddIn, mais est-il possible avec PowerPoint? Aussi, je ne peux pas voir Styles/Changer les styles options dans PowerPoint (dans Word, ils apparaissent sur l'onglet Accueil).
Merci. Existe-t-il un moyen d'accéder à quelque chose comme le texte sélectionné ou le paragraphe actif dans la diapositive PowerPoint? Et aussi comment appliquer le style (comme gras, indentation etc) à ce texte? – dragonfly