2022-06-23

How can I read the color of autoshape in python-pptx?

enter image description here

Colorful circles are the autoshape type in python-pptx, Now I want to read the color(RGB or whatever) of them

What I got in documentation is use

shape.fill.solid() 
shape.fill.fore_color.rgb

But It pops

AttributeError: no .rgb property on color type '_NoneColor'

Any idea to access the color of autoshape?

(BTW, Best to post the color change method cause I read color for change it by HSV adjustment)



No comments:

Post a Comment