Reputation: 61
I used python library tablib v0.10.0
. I have a document which has a column with each row containing large amount of text. But after I generated the document I found that it is not as beautified or formatted as I want it to be. I basically want to increase the column size and apply text wrap down to the entire sheet of the Dataset.
tab_data = tablib.Dataset(*dataList, headers=headers_list, title="Sample sheet")
Is there a way for me to set column size while initializing the Dataset in the above step?
Upvotes: 2
Views: 562
Reputation: 175
According to codebase there is solution. Once you have used \n
in value it will automatically add wrap to value. If you want to modify the behavior just extend XLSXFormat
, override dset_sheet method and register your format to registry
Upvotes: 0