ios - Unable to show all content of UILabel -


i have uilabel default showing 3 lines of text. want display text content in cases. have tried found, nothing works. here latest try:

cgrect labelsize = [contents.contentlanguage.description boundingrectwithsize:cgsizemake(self.view.frame.size.width * 0.97, cgfloat_max) options:nsstringdrawinguseslinefragmentorigin attributes:@{nsfontattributename:[uifont systemfontofsize:15]} context:nil];          cell.desclbl.frame = cgrectmake(labelsize.origin.x,                                                  labelsize.origin.y,                                                  ceil(labelsize.size.width),                                                  ceil(labelsize.size.height));          [cell.desclbl setnumberoflines:0];         [cell.desclbl setlinebreakmode:nslinebreakbywordwrapping];         [cell.desclbl sizetofit]; 

maybe should @ maybe using uitextview instead? it's better suited multiline text.

https://developer.apple.com/documentation/uikit/uitextview


Comments

Popular posts from this blog

Sort a complex associative array in PHP -

vb.net - How to ignore if a cell is empty nothing -

recursion - Can every recursive algorithm be improved with dynamic programming? -