天天看點

[控件] LabelView

labelview

[控件] LabelView
[控件] LabelView

此labelview是用來将label顯示在固定的view上的,需要計算label的高度與寬度.

源碼:

nsstring+stringheight.h 與 nsstring+stringheight.m

labelview.h 與 labelview.m

使用時候的源碼:

    labelview *labelview = [labelview createwithtext:@"youxianming" atorigin:cgpointmake(10, 90)];

    [self.view addsubview:labelview];