Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -105,10 +105,9 @@ if uploaded_file is not None:
|
|
| 105 |
# Create a slide
|
| 106 |
slide = prs.slides.add_slide(prs.slide_layouts[5])
|
| 107 |
|
| 108 |
-
# Add the image to the slide at the
|
| 109 |
-
left =
|
| 110 |
-
top =
|
| 111 |
-
width = height = Inches(3)
|
| 112 |
pic = slide.shapes.add_picture(temp_img_path, left, top, width, height)
|
| 113 |
|
| 114 |
# Add the paragraph to the slide at the top
|
|
|
|
| 105 |
# Create a slide
|
| 106 |
slide = prs.slides.add_slide(prs.slide_layouts[5])
|
| 107 |
|
| 108 |
+
# Add the image to the slide at the center (resized to 500x500 pixels)
|
| 109 |
+
left = (prs.slide_width - width) / 2
|
| 110 |
+
top = (prs.slide_height - height) / 2
|
|
|
|
| 111 |
pic = slide.shapes.add_picture(temp_img_path, left, top, width, height)
|
| 112 |
|
| 113 |
# Add the paragraph to the slide at the top
|