php - Auto fitting a cell to the size of the content? -
i'm new tcpdf, creating first document.
i wonder if there way fit width of cell automatically content. see options fixed size, or taking whole page width until end of line.
i'm aware of getstringwidth() having following problems it
why should 1 bother this? there way make cell fit automatically contents width?
getstringwidth() seems err time time, giving shorter results actual, causing text split next line. font set.
after learning tcpdf more, conclusion: cell() , multicell() not intended used outputting string , fitting it's length. instead, write() , writehtml() should used. cells exist case want control dimentions of field manually.
nevertheless, in cases 1 may want compute width of cell, such takes account sizes of text inside. purpose exists getstringwidth(). (unfortunately me err's time time. maybe i'm not aware of something)
Comments
Post a Comment