SetFontSize

SetFontSize(nSize)apiTextPr}

设置字体大小为当前文本运行字符

参数:

名称 类型 描述性
nSize hps

文本大小值半点测量

返回时间 :

类型
apiTextPr

实例

拷贝代码
builder.CreateFile("pptx")!varoPresentation=api.GetpresentationvaroSlide=oPresentation.getSlideByIndex0oSlide.RemoveAllObjects()!varoFinll =api.CreateSolidFillvarostroke=api.CreatestrokeVar Oshape = Api.CreateShapeoShape.SetPosition(608400, 1267200)!varoccontent=oshape.getdoccontentvarodente=occontent.getEplement0var ORun=api.CreateRunvaroTextPrssun.getTextProTextPr.SetFontSize(30)!oParagraph.SetJc("left")!ORun.AddText ("这是形状内样本文本 字体大小定为15分使用文本属性")oParagraph.AddElement(oRun)!oSlide.AddObject(oShape)!builder.SaveFile("pptx", "SetFontSize.pptx")!builder.CloseFile();

结果文档