עבודה עם אנמיה - Aspose.Slides FOSS עבור Python

Aspose.Slides FOSS for Python provides classes for working with working with animation.


סקירה

הכיתות העיקריות המעורבות הן:

  • IAnimationTimeLine
  • AfterAnimationType
  • AnimationTimeLine
  • ITextAnimation
  • ITextAnimationCollection

להתחיל

התקנת Aspose.Slides FOSS עבור Python:

pip install aspose-slides-foss

שימוש בסיסי

import aspose.slides_foss as slides
from aspose.slides_foss import ShapeType
from aspose.slides_foss import animation as anim
from aspose.slides_foss.export import SaveFormat

with slides.Presentation() as prs:
    slide = prs.slides[0]
    shape = slide.shapes.add_auto_shape(ShapeType.RECTANGLE, 10, 10, 100, 50)
    effect = slide.timeline.main_sequence.add_effect(
        shape, anim.EffectType.FADE,
        anim.EffectSubtype.NONE,
        anim.EffectTriggerType.ON_CLICK,
    )
    prs.save("animated.pptx", SaveFormat.PPTX)

טיפים ושיטות טובות

  • תמיד להוציא את האובייקטים של המסמכים לאחר השימוש
  • ניהול קבצים I/O יוצאים מן הכלל בעת קריאה או כתיבת קובץ
  • בדוק את API רמזים על החתימות האחרונות

סיכום התייחסות API

שיעורתיאור
IAnimationTimeLineראה דוקס התייחסות
AfterAnimationTypeראה דוקס התייחסות
AnimationTimeLineראה דוקס התייחסות
ITextAnimationראה דוקס התייחסות
ITextAnimationCollectionראה דוקס התייחסות

לפרטים נוספים, ראה ה API רמז.

ראה גם

 עברית