NSDateFormatter and UIFont
Categories: others on Oct.11, 2009
Потерял свои закладки с этими данными. Для себя делаю заметку, но может кому то тоже понадобится.
| Format Character | Description | Example Return Values |
| Day | ||
| d | Day of the month, 2 digits without leading zeros | 1 through 31 |
| dd | Day of the month, 2 digits with leading zeros | 01 through 31 |
| D | The day of the year | 1 through 366 |
| F | The day of the week in a month | 1 through 5 (eg. 2nd Wed in July) |
| g | Julian day number (number of days since 4713 BC January 1) | Example: 2451334 |
| G | Era designator abbreviated | Example: AD |
| GGGG | The full era designator name | Example: Anno Domini |
| GGGGG | A narrow textual representation of the era designator | Example: A |
| Day of the Week | ||
| e
c |
ISO-8601 numeric representation of the day of the week | 1 (for Sunday) through 7 (for Saturday) |
| E
ccc |
A textual representation of a day, three letters | Mon through Sun |
| EEEE
cccc |
A full textual representation of the day of the week | Monday through Sunday |
| EEEEE
ccccc |
A narrow textual representation of the day of the week | Monday through Sunday |
| Week | ||
| w | ISO-8601 week number of year | 1 through 52 |
| W | ISO-8601 week number of month | 1 through 4 |
| Month | ||
| M
L |
Numeric representation of a month, without leading zeros | 1 through 12 |
| MM
LL |
Numeric representation of a month, with leading zeros | 01 through 12 |
| MMM
LLL |
A short textual representation of a month, three letters | Jan through Dec |
| MMMM
LLLL |
A full textual representation of a month | January through December |
| MMMMM
LLLLL |
A narrow textual representation of a month | Example: D |
| Year | ||
| y
yyyy |
A full numeric representation of a year, 4 digits | Example: 2009 |
| yy | A two digit representation of a year | Example: 09 |
| Y
YYYY |
A full numeric representation of a ISO year, 4 digits | Example: 2009 |
| YY | A two digit representation of a ISO year | Example: 09 |
| Time | ||
| a | Lowercase Ante meridiem and Post meridiem | AM or PM |
| h
K |
12-hour format of an hour without leading zeros | 1 through 12 |
| hh
KK |
12-hour format of an hour with leading zeros | 01 through 12 |
| H
k |
24-hour format of an hour without leading zeros | 0 through 23 |
| HH
kk |
24-hour format of an hour with leading zeros | 00 through 23 |
| m | Minutes without leading zeros | 0 through 59 |
| mm | Minutes with leading zeros | 00 through 59 |
| s | Seconds without leading zeros | 0 through 59 |
| ss | Seconds with leading zeros | 00 to 59 |
| A | Milliseconds in day | Example: 69540000 |
| Timezone | ||
| zzzz | A full textual representation of GMT timezone | Example: Central European Time |
| Z | Difference to Greenwich time (GMT) in hours in RFC 822 format | Example: +0200 |
| ZZZZ | Difference to Greenwich time (GMT) in hours in GMT format | Example: GMT+02:00 |
:
Family name: Hiragino Kaku Gothic ProN W3
Font name: HiraKakuProN-W3
Family name: Courier
Font name: Courier
Font name: Courier-BoldOblique
Font name: Courier-Oblique
Font name: Courier-Bold
Family name: Arial
Font name: ArialMT
Font name: Arial-BoldMT
Font name: Arial-BoldItalicMT
Font name: Arial-ItalicMT
Family name: STHeiti TC
Font name: STHeitiTC-Light
Font name: STHeitiTC-Medium
Family name: AppleGothic
Font name: AppleGothic
Family name: Courier New
Font name: CourierNewPS-BoldMT
Font name: CourierNewPS-ItalicMT
Font name: CourierNewPS-BoldItalicMT
Font name: CourierNewPSMT
Family name: Zapfino
Font name: Zapfino
Family name: Hiragino Kaku Gothic ProN W6
Font name: HiraKakuProN-W6
Family name: Arial Unicode MS
Font name: ArialUnicodeMS
Family name: STHeiti SC
Font name: STHeitiSC-Medium
Font name: STHeitiSC-Light
Family name: American Typewriter
Font name: AmericanTypewriter
Font name: AmericanTypewriter-Bold
Family name: Helvetica
Font name: Helvetica-Oblique
Font name: Helvetica-BoldOblique
Font name: Helvetica
Font name: Helvetica-Bold
Family name: Marker Felt
Font name: MarkerFelt-Thin
Family name: Helvetica Neue
Font name: HelveticaNeue
Font name: HelveticaNeue-Bold
Family name: DB LCD Temp
Font name: DBLCDTempBlack
Family name: Verdana
Font name: Verdana-Bold
Font name: Verdana-BoldItalic
Font name: Verdana
Font name: Verdana-Italic
Family name: Times New Roman
Font name: TimesNewRomanPSMT
Font name: TimesNewRomanPS-BoldMT
Font name: TimesNewRomanPS-BoldItalicMT
Font name: TimesNewRomanPS-ItalicMT
Family name: Georgia
Font name: Georgia-Bold
Font name: Georgia
Font name: Georgia-BoldItalic
Font name: Georgia-Italic
Family name: STHeiti J
Font name: STHeitiJ-Medium
Font name: STHeitiJ-Light
Family name: Arial Rounded MT Bold
Font name: ArialRoundedMTBold
Family name: Trebuchet MS
Font name: TrebuchetMS-Italic
Font name: TrebuchetMS
Font name: Trebuchet-BoldItalic
Font name: TrebuchetMS-Bold
Family name: STHeiti K
Font name: STHeitiK-Medium
Font name: STHeitiK-Light
Similar posts:

