Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

ppt picture add

zmworm edited this page Apr 17, 2026 · 53 revisions

PowerPoint: Picture - Add

Insert images on a slide with positioning and alt text.

Path: /slide[N] (parent)

Properties

Property Default Description
path (required) Image source: local file path, data:image/png;base64,... data URI, or https://... HTTP URL
name Picture {N} Picture name
alt filename Alt text for accessibility
width 6in Width (EMU or units). If only width is supplied, height is auto-computed from the image's native aspect ratio.
height 4in Height (EMU or units). If only height is supplied, width is auto-computed from the image's native aspect ratio.
x / left centered Left position (EMU or units)
y / top centered Top position (EMU or units)
geometry / shape rect Clip shape geometry (e.g., roundRect, ellipse, heart)
fallback ×ばつ1 transparent PNG Raster fallback image for SVG (used by older Office versions)

Examples

# Add a picture with size
officecli add slides.pptx /slide[1] --type picture --prop src=photo.jpg --prop width=8in --prop height=5in --prop alt="Team photo"
# Add logo at specific position
officecli add slides.pptx /slide[1] --type picture --prop src=logo.png --prop x=20cm --prop y=16cm --prop width=3cm --prop height=1cm
# Add named picture
officecli add slides.pptx /slide[1] --type picture --prop src=/tmp/chart.png --prop name="Chart Screenshot" --prop x=2cm --prop y=4cm --prop width=20cm --prop height=12cm
# Add picture clipped to a circle
officecli add slides.pptx /slide[1] --type picture --prop src=avatar.jpg --prop geometry=ellipse --prop width=5cm --prop height=5cm
# Add picture clipped to rounded rectangle
officecli add slides.pptx /slide[1] --type picture --prop src=photo.jpg --prop shape=roundRect --prop width=10cm --prop height=8cm
# Add picture from base64 data URI
officecli add slides.pptx /slide[1] --type picture --prop "path=data:image/png;base64,iVBORw0KGgo..." --prop width=10cm --prop height=8cm
# Add picture from HTTP URL
officecli add slides.pptx /slide[1] --type picture --prop src=https://example.com/logo.png --prop width=5cm --prop height=5cm

Add SVG image (dual representation: SVG + PNG fallback)

officecli add slides.pptx /slide[1] --type picture --prop src=diagram.svg --prop width=10cm --prop height=8cm

Add SVG with custom raster fallback for older Office versions

officecli add slides.pptx /slide[1] --type picture --prop src=icon.svg --prop fallback=icon.png --prop width=3cm --prop height=3cm

×ばつ1 transparent pixel unless `fallback` is specified). --- *Based on OfficeCLI v1.0.50*">

> **Note:** Supported image formats: png, jpg, gif, bmp, tiff, emf, wmf, svg. HTTP URLs have a 30s timeout. SVG images use OOXML dual representation: modern Office (2016+) renders the SVG; older versions fall back to a PNG (auto-generated ×ばつ1 transparent pixel unless `fallback` is specified).
---
*Based on OfficeCLI v1.0.50*

Clone this wiki locally

AltStyle によって変換されたページ (->オリジナル) /