#import "labeltestviewcontroller.h"
@implementation labeltestviewcontroller
/*
accessing the text attributes
text property
font property
textcolor property
textalignment property
linebreakmode property
enabled property
sizing the label』s text
adjustsfontsizetofitwidth property
baselineadjustment property
minimumfontsize property 無例
numberoflines property
managing highlight values
highlightedtextcolor property
highlighted property
drawing a shadow
shadowcolor property
shadowoffset property
drawing and positioning overrides
– textrectforbounds:limitedtonumberoflines: 無例
– drawtextinrect: 無例
setting and getting attributes
userinteractionenabled property */
// implement viewdidload to do additional setup after loading the view, typically from a nib.
- (void)viewdidload uilinebreakmode;
//如果adjustsfontsizetofitwidth屬性設定為yes,這個屬性就來控制文字基線的行為
label4.
baselineadjustment
= uibaselineadjustmentnone;
// typedef enum uibaselineadjustment;
[self.view
addsubview:label1];
[self.view
addsubview:label2];
[self.view
addsubview:label3];
[self.view
addsubview:label4];
[self.view
addsubview:label5];
[self.view
addsubview:label6];
[self.view
addsubview:label7];
[label1 release];
[label2 release];
[label3 release];
[label4 release];
[label5 release];
[label6 release];
[label7 release];
[super
viewdidload];
}
/*
// override to allow orientations other than the default portrait orientation.
- (bool)shouldautorotatetointe***ceorientation:(uiinte***ceorientation)inte***ceorientation */
- (void)didreceivememorywarning
- (void)viewdidunload
- (void)dealloc
@end
uilabel的各種屬性與方法的使用***
#import "labeltestviewcontroller.h"
@implementation labeltestviewcontroller
/*
accessing the text attributes
text property
font property
textcolor property
textalignment property
linebreakmode property
enabled property
sizing the label』s text
adjustsfontsizetofitwidth property
baselineadjustment property
minimumfontsize property 無例
numberoflines property
managing highlight values
highlightedtextcolor property
highlighted property
drawing a shadow
shadowcolor property
shadowoffset property
drawing and positioning overrides
– textrectforbounds:limitedtonumberoflines: 無例
– drawtextinrect: 無例
setting and getting attributes
userinteractionenabled property */
// implement viewdidload to do additional setup after loading the view, typically from a nib.
- (void)viewdidload uilinebreakmode;
//如果adjustsfontsizetofitwidth屬性設定為yes,這個屬性就來控制文字基線的行為
label4.
baselineadjustment
= uibaselineadjustmentnone;
// typedef enum uibaselineadjustment;
[self.view
addsubview:label1];
[self.view
addsubview:label2];
[self.view
addsubview:label3];
[self.view
addsubview:label4];
[self.view
addsubview:label5];
[self.view
addsubview:label6];
[self.view
addsubview:label7];
[label1 release];
[label2 release];
[label3 release];
[label4 release];
[label5 release];
[label6 release];
[label7 release];
[super
viewdidload];
}
/*
// override to allow orientations other than the default portrait orientation.
- (bool)shouldautorotatetointe***ceorientation:(uiinte***ceorientation)inte***ceorientation */
- (void)didreceivememorywarning
- (void)viewdidunload
- (void)dealloc
@end
UILabel的各種屬性
uilable是iphone介面最基本的控制項,主要用來顯示文字資訊。常用屬性和方法有 1 建立 cgrect rect cgrectmake 100,200,50,50 uilabel label uilabel alloc initwithframe rect 2 text 設定和讀取文字內容,...
CSS的各種屬性
css的各種屬性 css的單位 a.絕對單位 1in 2.54cm 25.4mm 72pt 6pc pt是點或者磅,pc是派卡 b.相對單位 px,em 印刷單位相當於12個點 相對周圍的文字 字型設定 p 文字設定 p 背景設定 body 列表設定 ul li 盒子模型 border margin...
動畫的各種屬性
以下都是為了自己方便記憶所記錄的,沒有太多的時間去查閱,只能慢慢的充實。android interpolator android anim linear interpolator android fromdegrees 0 android todegrees 90 android pivotx 50...