title: How to create only bottom border for label?
body: <p>Hi I used the the following code to create a bottom border to my label</p>
  
  <pre><code>CALayer *border = [CALayer layer];
      CGFloat borderWidth = 2;
      border.borderColor = [UIColor darkGrayColor].CGColor;
      border.frame = CGRectMake(0, _label.frame.size.height - borderWidth, _label.frame.size.width, _label.frame.size.height);
      border.borderWidth = borderWidth;
      [_label.layer addSublayer:border];
      _label.layer.masksToBounds = YES;
  </code></pre>
  
  <p>But it the border is breaks at half of label. How can I fix it. Thanks in advance.</p>