-
Notifications
You must be signed in to change notification settings - Fork 8
/
industry_cell.m
46 lines (36 loc) · 1.39 KB
/
industry_cell.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
//
// industry_cell.m
// collection_master
//
// Created by 是 撒 on 5/18/15.
// Copyright (c) 2015 芳仔小脚丫. All rights reserved.
//
#import "industry_cell.h"
//获取设备的物理高度
#define ScreenHeight [UIScreen mainScreen].bounds.size.height
//获取设备的物理宽度
#define ScreenWidth [UIScreen mainScreen].bounds.size.width
@implementation industry_cell
- (id)initWithFrame:(CGRect)frame
{
self = [super initWithFrame:frame];
if (self) {
down = [[UILabel alloc] initWithFrame:CGRectMake(0, 44.5, ScreenWidth/3, 0.5)];
right = [[UILabel alloc] initWithFrame:CGRectMake((ScreenWidth/3)-0.5, 0, 0.5, 45)];
down.text = @"";
[down setBackgroundColor:[UIColor groupTableViewBackgroundColor]];
right.text = @"";
[right setBackgroundColor:[UIColor groupTableViewBackgroundColor]];
_industry = [[UILabel alloc] initWithFrame:CGRectMake(0.5, 0.3, (ScreenWidth/3)-1, 44)];
_industry.text = @"成都";
[_industry setTextColor:[UIColor blackColor]];
_industry.textAlignment = NSTextAlignmentCenter;
_industry.font = [UIFont systemFontOfSize:12];
_industry.backgroundColor = [UIColor clearColor];
[self addSubview:down];
[self addSubview:right];
[self addSubview:_industry];
}
return self;
}
@end