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

python - Subclassed QStyledItemDelegate ignores Stylesheet -

java - HttpClient 3.1 Connection pooling vs HttpClient 4.3.2 -

SQL: Divide the sum of values in one table with the count of rows in another -