UIAppearanceプロキシを介して設定できるプロパティは何ですか? AppleのUIKitドキュメントにはリストされていません。これらのプロパティのリストはありますか?
UIAppearanceで設定できるプロパティには、対応するヘッダーファイルでUI_APPEARANCE_SELECTOR
のタグが付けられています。
UI_APPEARANCE_SELECTOR
でタグ付けされたプロパティのリストを生成するには、ターミナルで次のUNIXコマンドを使用できます。
cd /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk/System/Library/Frameworks/UIKit.framework/Headers
grep -H UI_APPEARANCE_SELECTOR ./* | sed 's/ __OSX_AVAILABLE_STARTING(__MAC_NA,__IPHONE_5_0) UI_APPEARANCE_SELECTOR;//'
上記のコマンドを使用してコンパイルしたリストを次に示します。これは5.0 SDK用です。簡潔にするために、対応するgetterメソッドは省略されています。
IActivityIndicatorView
@property (readwrite, nonatomic, retain) UIColor *color
IBarButtonItem
@property(nonatomic,retain) UIColor *tintColor
- (void)setBackgroundImage:(UIImage *)backgroundImage forState:(UIControlState)state barMetrics:(UIBarMetrics)barMetrics
- (void)setBackgroundVerticalPositionAdjustment:(CGFloat)adjustment forBarMetrics:(UIBarMetrics)barMetrics
- (void)setTitlePositionAdjustment:(UIOffset)adjustment forBarMetrics:(UIBarMetrics)barMetrics
- (void)setBackButtonBackgroundImage:(UIImage *)backgroundImage forState:(UIControlState)state barMetrics:(UIBarMetrics)barMetrics
- (void)setBackButtonTitlePositionAdjustment:(UIOffset)adjustment forBarMetrics:(UIBarMetrics)barMetrics
- (void)setBackButtonBackgroundVerticalPositionAdjustment:(CGFloat)adjustment forBarMetrics:(UIBarMetrics)barMetrics
[iOS 6.0]
- (void)setBackgroundImage:(UIImage *)backgroundImage forState:(UIControlState)state style:(UIBarButtonItemStyle)style barMetrics:(UIBarMetrics)barMetrics [iOS 6.0]
IBarItem
- (void)setTitleTextAttributes:(NSDictionary *)attributes forState:(UIControlState)state
INavigationBar
@property(nonatomic,retain) UIColor *tintColor
@property(nonatomic,copy) NSDictionary *titleTextAttributes
- (void)setBackgroundImage:(UIImage *)backgroundImage forBarMetrics:(UIBarMetrics)barMetrics
- (void)setTitleVerticalPositionAdjustment:(CGFloat)adjustment forBarMetrics:(UIBarMetrics)barMetrics
[iOS 6.0]
@property(nonatomic,retain) UIImage *shadowImage
[iOS 7.0]
@property(nonatomic,retain) UIColor *barTintColor
- (void)setBackgroundImage:(UIImage *)backgroundImage forBarPosition:(UIBarPosition)barPosition barMetrics:(UIBarMetrics)barMetrics
- (UIImage *)backgroundImageForBarPosition:(UIBarPosition)barPosition barMetrics:(UIBarMetrics)barMetrics
@property(nonatomic,retain) UIImage *backIndicatorImage
@property(nonatomic,retain) UIImage *backIndicatorTransitionMaskImage
IPageControl
[iOS 6.0]
@property(nonatomic,retain) UIColor *pageIndicatorTintColor
@property(nonatomic,retain) UIColor *currentPageIndicatorTintColor
IProgressView
@property(nonatomic, retain) UIColor* progressTintColor
@property(nonatomic, retain) UIColor* trackTintColor
@property(nonatomic, retain) UIImage* progressImage
@property(nonatomic, retain) UIImage* trackImage
IRefreshControl
[iOS 6.0]
@property (nonatomic, retain) UIColor *tintColor
@property (nonatomic, retain) NSAttributedString *attributedTitle
ISearchBar
@property(nonatomic,retain) UIImage *backgroundImage
@property(nonatomic,retain) UIImage *scopeBarBackgroundImage
@property(nonatomic) UIOffset searchFieldBackgroundPositionAdjustment
@property(nonatomic) UIOffset searchTextPositionAdjustment
- (void)setSearchFieldBackgroundImage:(UIImage *)backgroundImage forState:(UIControlState)state
- (void)setImage:(UIImage *)iconImage forSearchBarIcon:(UISearchBarIcon)icon state:(UIControlState)state
- (void)setScopeBarButtonBackgroundImage:(UIImage *)backgroundImage forState:(UIControlState)state
- (void)setScopeBarButtonDividerImage:(UIImage *)dividerImage forLeftSegmentState:(UIControlState)leftState rightSegmentState:(UIControlState)rightState
- (void)setScopeBarButtonTitleTextAttributes:(NSDictionary *)attributes forState:(UIControlState)state
- (void)setPositionAdjustment:(UIOffset)adjustment forSearchBarIcon:(UISearchBarIcon)icon
[iOS 7.0]
@property(nonatomic,retain) UIColor *barTintColor
- (void)setBackgroundImage:(UIImage *)backgroundImage forBarPosition:(UIBarPosition)barPosition barMetrics:(UIBarMetrics)barMetrics
- (UIImage *)backgroundImageForBarPosition:(UIBarPosition)barPosition barMetrics:(UIBarMetrics)barMetrics
ISegmentedControl
@property(nonatomic,retain) UIColor *tintColor UI_APPEARANCE_SELECTOR;
- (void)setBackgroundImage:(UIImage *)backgroundImage forState:(UIControlState)state barMetrics:(UIBarMetrics)barMetrics
- (void)setDividerImage:(UIImage *)dividerImage forLeftSegmentState:(UIControlState)leftState rightSegmentState:(UIControlState)rightState barMetrics:(UIBarMetrics)barMetrics
- (void)setTitleTextAttributes:(NSDictionary *)attributes forState:(UIControlState)state
- (void)setContentPositionAdjustment:(UIOffset)adjustment forSegmentType:(UISegmentedControlSegment)leftCenterRightOrAlone barMetrics:(UIBarMetrics)barMetrics
ISlider
@property(nonatomic,retain) UIColor *minimumTrackTintColor
@property(nonatomic,retain) UIColor *maximumTrackTintColor
@property(nonatomic,retain) UIColor *thumbTintColor
IStepper
[iOS 6.0]
@property(nonatomic,retain) UIColor *tintColor
- (void)setBackgroundImage:(UIImage*)image forState:(UIControlState)state
- (void)setDividerImage:(UIImage*)image forLeftSegmentState:(UIControlState)leftState rightSegmentState:(UIControlState)rightState
- (void)setIncrementImage:(UIImage *)image forState:(UIControlState)state
- (void)setDecrementImage:(UIImage *)image forState:(UIControlState)state
ISwitch
@property(nonatomic, retain) UIColor* onTintColor
[iOS 6.0]
@property(nonatomic, retain) UIColor *tintColor
@property(nonatomic, retain) UIColor *thumbTintColor
@property(nonatomic, retain) UIImage *onImage
@property(nonatomic, retain) UIImage *offImage
ITabBar
@property(nonatomic,retain) UIColor *tintColor
@property(nonatomic,retain) UIColor *selectedImageTintColor
@property(nonatomic,retain) UIImage *backgroundImage
@property(nonatomic,retain) UIImage *selectionIndicatorImage
[iOS 6.0]
@property(nonatomic,retain) UIImage *shadowImage
[iOS 7.0]
@property(nonatomic,retain) UIColor *barTintColor
@property(nonatomic) UITabBarItemPositioning itemPositioning
@property(nonatomic) CGFloat itemWidth
@property(nonatomic) CGFloat itemSpacing
@property(nonatomic) UIBarStyle barStyle
ITabBarItem
- (void)setTitlePositionAdjustment:(UIOffset)adjustment
ITableView
[iOS 6.0]
@property(nonatomic, retain) UIColor *sectionIndexColor
@property(nonatomic, retain) UIColor *sectionIndexTrackingBackgroundColor
[iOS 7.0]
@property (nonatomic) UIEdgeInsets separatorInset
@property(nonatomic, retain) UIColor *sectionIndexBackgroundColor
ITableViewCell
[iOS 7.0]
@property (nonatomic) UIEdgeInsets separatorInset
ITableViewHeaderFooterView
[iOS 6.0]
@property(nonatomic, retain) UIColor *tintColor
IToolbar
@property(nonatomic,retain) UIColor *tintColor;
- (void)setBackgroundImage:(UIImage *)backgroundImage forToolbarPosition:(UIToolbarPosition)topOrBottom barMetrics:(UIBarMetrics)barMetrics
[iOS 6.0]
- (void)setShadowImage:(UIImage *)shadowImage forToolbarPosition:(UIToolbarPosition)topOrBottom
[iOS 7.0]
@property(nonatomic,retain) UIColor *barTintColor
(2012年7月3日):このリストは、XCode(4.3.3)の最新バージョンまで変更されていません。
(2013年3月12日):SDK 6.1用にリストが更新されました。 iOS 6.0(またはそれ以降)に適用されるプロパティは、[iOS 6.0]
タグの下にリストされています。
(2013年10月24日):SDK 7.0用にリストが更新されました。 iOS 7.0(またはそれ以降)に適用されるプロパティは、[iOS 7.0]
タグの下にリストされています。