我找不到示例如何在文本框中设置文本的垂直方向
我找到了如何在单元格中旋转文本,但是我需要在文本框中旋转文本
文本框代码
text = 'Some text in a textbox'
options = {
'font': {'color': 'white'},
'align': {'vertical': 'middle',
'horizontal': 'center',
},
'gradient': {'colors': ['red', 'blue']},
}
worksheet.insert_textbox(row, col, text, options)
单元格中带有旋转文本的代码
cell_format = workbook.add_format()
cell_format.set_rotation(90)
worksheet.write(1, 1, 'This text is rotated')
worksheet.set_column(col, col, None, cell_format)