-
Notifications
You must be signed in to change notification settings - Fork 465
ppt shape get
zmworm edited this page Apr 29, 2026
·
51 revisions
Returned attributes when getting a shape node.
Path: /slide[N]/shape[M]
| Key | Type | Description |
|---|---|---|
name |
string | Shape name |
isTitle |
boolean | Whether the shape is a title placeholder |
x |
integer | Horizontal position (EMU) |
y |
integer | Vertical position (EMU) |
width |
integer | Width (EMU) |
height |
integer | Height (EMU) |
fill |
string | Fill color (hex, e.g. #4472C4) or none
|
opacity |
number | Fill opacity (0-1) |
preset |
string | Preset shape type (e.g. rect, roundRect, ellipse, triangle) |
geometry |
string | Preset shape type (alias for preset) |
gradient |
string | Gradient definition (e.g., linear;C1;C2;angle, radial;C1;C2, path;C1;C2) |
image |
string | Has image fill (true if present) |
list |
string | Bullet character (e.g., •) or auto-number type (e.g., arabicPeriod) |
font |
string | Font name |
size |
number | Font size (pt) |
bold |
boolean | Bold text |
italic |
boolean | Italic text |
underline |
string | Underline style (e.g., sng, dbl) |
strike |
boolean | Strikethrough text |
color |
string | Font color (hex, e.g. #FF0000) |
link |
string | Hyperlink URL |
line |
string | Outline color (hex) |
lineWidth |
number | Outline width (pt) |
lineDash |
string | Outline dash style (solid, dash, dot, dashDot) |
lineOpacity |
number | Outline opacity (0-1) |
shadow |
string | Shadow (format: "color-blur-angle-dist-opacity") |
glow |
string | Glow (format: "color-radius-opacity") |
reflection |
string | Reflection style: tight, half, full
|
animation |
string | Animation effect (format: effectName-class-durationMs) |
rotation |
number | Rotation angle (degrees) |
margin |
string | Internal margins (e.g. 91440 91440 91440 91440) |
valign |
string | Vertical alignment (top, center, bottom) |
textWarp |
string | Text warp preset (e.g. wave1, archUp) |
autoFit |
string | Auto-fit mode (normal, shape, none) |
align |
string | Horizontal text alignment (left, center, right, justify; default left when textBody exists) |
spacing |
number | Character spacing (points) |
baseline |
string | Baseline shift (super, sub, none, or percentage) |
indent |
integer | Paragraph first-line indent (EMU) |
marginLeft |
integer | Paragraph left margin (EMU) |
marginRight |
integer | Paragraph right margin (EMU) |
textFill |
string | Text gradient fill definition |
flipH |
boolean | Flipped horizontally |
flipV |
boolean | Flipped vertically |
zorder |
integer | Z-order position |
rot3d |
string | 3D rotation ("rotX,rotY,rotZ") |
lighting |
string | Light rig type (e.g., threePt, balanced) |
depth |
number | Extrusion depth (points) |
material |
string | 3D material (e.g., warmMatte, plastic) |
bevel |
string | Top bevel preset |
bevelBottom |
string | Bottom bevel preset |
softEdge |
number | Soft edge radius (points) |
lineSpacing |
string | Line spacing: "1.5x" (percent) or "18pt" (fixed points) |
spaceBefore |
string | Space before paragraph (e.g. "12pt") |
spaceAfter |
string | Space after paragraph (e.g. "6pt") |
Note: When shape-level effects (
shadow,glow,reflection,softEdge) are empty (e.g., forfill=noneshapes), get reads text-level effects as a fallback.
A shape node may contain child elements:
-
paragraph- Text paragraphs -
run- Text runs within paragraphs
officecli get slides.pptx /slide[1]/shape[1]/slide[1]/shape[1] (Shape) (2 children)
name: Title 1
isTitle: true
x: 685800
y: 2286000
width: 7772400
height: 1325563
fill: #4472C4
opacity: 1
preset: roundRect
font: Calibri
size: 36
bold: true
color: #FFFFFF
align: center
valign: middle
shadow: #000000
Placeholders are special shapes tied to a slide layout slot.
Path: /slide[N]/placeholder[X]
| Key | Type | Description |
|---|---|---|
phType |
string | Placeholder type (title, body, ctrTitle, subTitle, dt, ftr, sldNum, pic, chart, tbl, dgm) |
phIndex |
integer | Placeholder index on the layout |
All shape attributes listed above are also available on placeholder nodes.
officecli get slides.pptx /slide[1]/placeholder[0]/slide[1]/placeholder[0] (Placeholder) (1 children)
phType: ctrTitle
phIndex: 0
name: Title 1
x: 685800
y: 2286000
width: 7772400
height: 1325563
font: Calibri
size: 44
bold: true
color: #000000
align: center
valign: middle
Based on OfficeCLI v1.0.64