forked from shu223/iOS7-Sampler
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
211 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<array> | ||
<string>Thonburi-Light</string> | ||
<string>GeezaPro-Light</string> | ||
<string>Menlo-BoldItalic</string> | ||
<string>Menlo-Regular</string> | ||
<string>Menlo-Bold</string> | ||
<string>Menlo-Italic</string> | ||
<string>IowanOldStyle-Bold</string> | ||
<string>IowanOldStyle-BoldItalic</string> | ||
<string>IowanOldStyle-Italic</string> | ||
<string>IowanOldStyle-Roman</string> | ||
<string>DamascusBold</string> | ||
<string>Damascus</string> | ||
<string>DamascusMedium</string> | ||
<string>DamascusSemiBold</string> | ||
<string>AlNile-Bold</string> | ||
<string>AlNile</string> | ||
<string>Farah</string> | ||
<string>DINCondensed-Bold</string> | ||
<string>Superclarendon-Regular</string> | ||
<string>Superclarendon-BoldItalic</string> | ||
<string>Superclarendon-Light</string> | ||
<string>Superclarendon-BlackItalic</string> | ||
<string>Superclarendon-Italic</string> | ||
<string>Superclarendon-LightItalic</string> | ||
<string>Superclarendon-Bold</string> | ||
<string>Superclarendon-Black</string> | ||
<string>DiwanMishafi</string> | ||
<string>SavoyeLetPlain</string> | ||
<string>AppleSDGothicNeo-Thin</string> | ||
<string>AppleSDGothicNeo-SemiBold</string> | ||
<string>AppleSDGothicNeo-Regular</string> | ||
<string>AppleSDGothicNeo-Light</string> | ||
<string>ArialHebrew-Light</string> | ||
<string>HelveticaNeue-MediumItalic</string> | ||
<string>HelveticaNeue-Thin</string> | ||
<string>HelveticaNeue-Thin_Italic</string> | ||
<string>DINAlternate-Bold</string> | ||
</array> | ||
</plist> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// FontsViewController.h | ||
// iOS7Sampler | ||
// | ||
// Created by shuichi on 10/17/13. | ||
// Copyright (c) 2013 Shuichi Tsutsumi. All rights reserved. | ||
// | ||
|
||
#import <UIKit/UIKit.h> | ||
|
||
@interface FontsViewController : UIViewController | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
// | ||
// FontsViewController.m | ||
// iOS7Sampler | ||
// | ||
// Created by shuichi on 10/17/13. | ||
// Copyright (c) 2013 Shuichi Tsutsumi. All rights reserved. | ||
// | ||
|
||
#import "FontsViewController.h" | ||
|
||
|
||
@interface FontsViewController () | ||
@property (nonatomic, strong) NSArray *items; | ||
@end | ||
|
||
|
||
@implementation FontsViewController | ||
|
||
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil | ||
{ | ||
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; | ||
if (self) { | ||
// Custom initialization | ||
} | ||
return self; | ||
} | ||
|
||
- (void)viewDidLoad | ||
{ | ||
[super viewDidLoad]; | ||
|
||
NSString *path = [[NSBundle mainBundle] pathForResource:@"addedIn7" | ||
ofType:@"plist"]; | ||
self.items = [NSArray arrayWithContentsOfFile:path]; | ||
} | ||
|
||
- (void)didReceiveMemoryWarning | ||
{ | ||
[super didReceiveMemoryWarning]; | ||
// Dispose of any resources that can be recreated. | ||
} | ||
|
||
|
||
// ============================================================================= | ||
#pragma mark - TableViewDataSource | ||
|
||
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView { | ||
|
||
return 1; | ||
} | ||
|
||
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { | ||
|
||
return [self.items count]; | ||
} | ||
|
||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath | ||
{ | ||
static NSString *CellIdentifier = @"Cell"; | ||
|
||
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; | ||
|
||
if (cell == nil) { | ||
|
||
cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle | ||
reuseIdentifier:CellIdentifier]; | ||
|
||
cell.accessoryType = UITableViewCellAccessoryNone; | ||
cell.selectionStyle = UITableViewCellSelectionStyleNone; | ||
} | ||
|
||
NSString *fontName = [self.items objectAtIndex:indexPath.row]; | ||
|
||
cell.textLabel.text = fontName; | ||
cell.textLabel.font = [UIFont fontWithName:fontName size:cell.textLabel.font.pointSize]; | ||
|
||
return cell; | ||
} | ||
|
||
|
||
// ============================================================================= | ||
#pragma mark - UITableViewDelegate | ||
|
||
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { | ||
|
||
return 44.0; | ||
} | ||
|
||
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { | ||
|
||
} | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="4510" systemVersion="12F45" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES"> | ||
<dependencies> | ||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3742"/> | ||
</dependencies> | ||
<objects> | ||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="FontsViewController"> | ||
<connections> | ||
<outlet property="view" destination="1" id="3"/> | ||
</connections> | ||
</placeholder> | ||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/> | ||
<view contentMode="scaleToFill" id="1"> | ||
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/> | ||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> | ||
<subviews> | ||
<tableView clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" alwaysBounceVertical="YES" style="plain" separatorStyle="none" rowHeight="44" sectionHeaderHeight="22" sectionFooterHeight="22" translatesAutoresizingMaskIntoConstraints="NO" id="fsA-vb-KYZ"> | ||
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/> | ||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> | ||
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/> | ||
<connections> | ||
<outlet property="dataSource" destination="-1" id="EXx-Kq-Q7N"/> | ||
<outlet property="delegate" destination="-1" id="H3f-gI-5E8"/> | ||
</connections> | ||
</tableView> | ||
</subviews> | ||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/> | ||
<simulatedStatusBarMetrics key="simulatedStatusBarMetrics"/> | ||
<simulatedNavigationBarMetrics key="simulatedTopBarMetrics" prompted="NO"/> | ||
<simulatedScreenMetrics key="simulatedDestinationMetrics" type="retina4"/> | ||
</view> | ||
</objects> | ||
</document> |