UILabel在某些情况下有边界

时间:2014-08-08 07:24:13

标签: ios iphone

标签末尾有一条线。不知道为什么会这样。一段时间在风景和一些时间在肖像。这是一贯的问题。可能是什么问题?在附加的图像中,如果我改变它消失的方向,则会显示一个边框。

enter image description here

以下是我的实施

                            @implementation MCLabel

- (id)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        btnSeeMore = [MCButton buttonWithType:UIButtonTypeCustom];
        [btnSeeMore setBackgroundColor:[UIColor clearColor]];
        [btnSeeMore setTitleColor:[UIColor blueColor] forState:UIControlStateNormal];
        [self addSubview:btnSeeMore];
        [btnSeeMore setHidden:YES];
    }
    return self;
}

这是我添加标签的方式

 MCLabel *lblRecord = [[MCLabel alloc] init];
                                [vwRow addSubview:lblRecord];
                                [lblRecord setLineBreakMode:NSLineBreakByTruncatingTail];
                                [lblRecord setTextAlignment:column.alignmentOfObject];
                                [lblRecord setFont:column.fontOfObject];
                                [lblRecord setStrObjID:column.linkName];
                                [lblRecord setBackgroundColor:column.clrBackground];
[lblRecord setFrame:column.frame];
                [lblRecord setText:column.strData];

0 个答案:

没有答案