ios - Change border width of label in custom UICollectionCell -


i have custom uicollectionviewcell , have placed 2 uilabels in it. want change borderradius , borderwidth of labels in it. can tell me how this? doing in way, nothing happening:

    self.titlelabel.layer.borderwidth = 2.0;     self.titlelabel.layer.bordercolor = [uicolor blackcolor].cgcolor; 

i putting these 2 lines in initwithframe method.

if want set borderwidth of uilabel inside means why using

self.titlelabel.layer.borderwidth = 2.0; 

instead of can directly use label name like,

yourlabel1.layer.borderwidth = 2.0; yourlabel2.layer.borderwidth = 2.0; 

like wise can change borderradius also.


Comments

Popular posts from this blog

node.js - StackOverflow API not returning JSON -

python - Subclassed QStyledItemDelegate ignores Stylesheet -

php - Laravel 4.1 to Heroku: SQLSTATE[HY000] [2002] No such file or directory -