Created
January 23, 2022 06:38
-
-
Save ygkn/fddca2defe33362c7d13ab71f3d0cd56 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pptx import Presentation | |
from pptx.shapes.autoshape import Shape | |
from pptx.enum.dml import MSO_LINE | |
from os import listdir, path | |
source = path.join(".", "source") | |
dist = path.join(".", "dist") | |
for file in listdir(source): | |
prs = Presentation(path.join(source, file)) | |
for slide in prs.slides: | |
for shape in slide.shapes: | |
if isinstance(shape, Shape): | |
shape.fill.background() | |
prs.save(path.join(dist, file)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment