Reputation: 83
Do you know how to rotate text in the table cell? This is code sample:
shp = slide.shapes.add_table(rows+dop_rows, cols+dop_cols, left, top, width, height)
table = shp.table
table.cell(i,j).text ='something text'
But I didn't find anything about text rotation or text direction in the text frame objects.
I use python pptx release with last version 0.6.17
Upvotes: 1
Views: 1199
Reputation: 83
I worked a bit with the workaround functions and got the result. To rotate text in the table cell we have to do folowing:
the_cell = temp_table.cell(i,j)# get the cell instance object
tcpr = the_cell._tc.get_or_add_tcPr()
tcpr.set('vert','vert270')# setting 'vert' parameter to 'vert270'
prs.save('test.pptx')
Upvotes: 2