最終更新:2024-04-01 (月) 23:03:57 (24d)  

UIButton
Top / UIButton

https://developer.apple.com/documentation/uikit/uibutton

Tasks

Creating Buttons

  • +buttonWithType?

Configuring the Button Title

  • titleLabel? - プロパティ (UILabel)
  • reversesTitleShadowWhenHighlighted? - プロパティ (BOOL)
  • setTitle:forState?
  • setAttributedTitle:forState?
  • setTitleColor:forState?
  • setTitleShadowColor:forState?
  • titleColorForState?
  • titleForState?
  • attributedTitleForState?
  • titleShadowColorForState?

Configuring Button Presentation

  • adjustsImageWhenHighlighted? - プロパティ (BOOL)
  • adjustsImageWhenDisabled? - プロパティ (BOOL)
  • showsTouchWhenHighlighted? - プロパティ (BOOL)
  • backgroundImageForState?
  • imageForState?
  • setBackgroundImage:forState?
  • setImage:forState:?
  • tintColor - プロパティ (UIColor)

Configuring Edge Insets

  • contentEdgeInsets? - プロパティ (UIEdgeInsets?)
  • titleEdgeInsets? - プロパティ (UIEdgeInsets?)
  • imageEdgeInsets? - プロパティ (UIEdgeInsets?)

Getting the Current State

Getting Dimensions

  • backgroundRectForBounds?
  • contentRectForBounds?
  • titleRectForContentRect?
  • imageRectForContentRect?

Deprecated Properties

  • font? - プロパティ (UIFont) - Deprecated in iOS 3.0?
  • lineBreakMode? - プロパティ (UILineBreakMode?) - Deprecated in iOS 3.0?
  • titleShadowOffset? - プロパティ (CGSize) - Deprecated in iOS 3.0?

イベント

メモ

  • フォントをヒラギノにかえると、文字の位置がボタンの真ん中ではなくなるらしい。。