In the use of UIButton, you need to implement UIButton left picture, the picture behind the word effect is more troublesome, simple implementation of the specific code as follows:
-(void) Viewdidload {
[Super Viewdidload];
Self.view.backgroundColor = RGB (235, 235, 240);
UIButton *onebutton = [[UIButton alloc] Initwithframe:cgrectmake (0, Kheaderheight + 8, Kscreenwidth, 40)];
[Onebutton setimage:[uiimage imagenamed:@ "Icon_party_knowledge_rights_obligations"] ForState:UIControlStateNormal ];
[Onebutton settitle:@ "The first" forstate:uicontrolstatenormal];
OneButton.titleLabel.font = Font (12);
[Onebutton Settitlecolor:[uicolor Blackcolor] forstate:uicontrolstatenormal];
[Onebutton Setimageedgeinsets:uiedgeinsetsmake (2, 8, 0, kScreenWidth-50)];
[Onebutton settitleedgeinsets:uiedgeinsetsmake (0, 0, 0, kScreenWidth-100)];
Onebutton.backgroundcolor = [Uicolor Whitecolor];
[Onebutton addtarget:self Action: @selector (onebuttonaction:) forcontrolevents:uicontroleventtouchupinside];
[Self.view Addsubview:onebutton];
UIButton *twobutton = [[UIButton alloc] Initwithframe:cgrectmake (0, Onebutton.maxy + 8, Kscreenwidth, 40)];
[Twobutton setimage:[uiimage imagenamed:@ "Icon_party_knowledge_dues_collection_standard"] forState: UIControlStateNormal];
[Twobutton settitle:@ "The second" forstate:uicontrolstatenormal];
TwoButton.titleLabel.font = Font (12);
[Twobutton Settitlecolor:[uicolor Blackcolor] forstate:uicontrolstatenormal];
[Twobutton Setimageedgeinsets:uiedgeinsetsmake (2, 8, 0, kScreenWidth-50)];
[Twobutton settitleedgeinsets:uiedgeinsetsmake (0, 0, 0, kScreenWidth-100)];
Twobutton.backgroundcolor = [Uicolor Whitecolor];
[Twobutton addtarget:self Action: @selector (twobuttonaction:) forcontrolevents:uicontroleventtouchupinside];
[Self.view Addsubview:twobutton];
Right Arrow
for (int i = 0; i < 2; i++) {
Uiimageview *rightimgview = [[Uiimageview alloc] Initwithframe:cgrectmake (kScreenWidth-20, kheaderheight + + i * 48, 7, 12)];
Rightimgview.image = [UIImage imagenamed:@ "Icon_right"];
[Self.view Addsubview:rightimgview];
}
}
The effect looks like this