Class: SectionHeaderView
- Inherits:
-
UIView
- Object
- UIView
- SectionHeaderView
- Defined in:
- lib/project/views/section_header_view.rb
Instance Method Summary collapse
Instance Method Details
#initWithFrame(frame) ⇒ Object
5 6 7 8 9 |
# File 'lib/project/views/section_header_view.rb', line 5 def initWithFrame(frame) super.tap do |view| view.addSubview(section_title) end end |
#section_title ⇒ Object
15 16 17 18 19 20 21 22 23 |
# File 'lib/project/views/section_header_view.rb', line 15 def section_title @section_title ||= PaddedLabel.alloc.initWithFrame(bounds).tap do |label| label.adjustsFontSizeToFitWidth = true label.backgroundColor = MotionForm.section_header_color label.font = MotionForm.section_header_font label.padding = 10 label.textColor = MotionForm.section_header_text_color end end |
#text=(text) ⇒ Object
11 12 13 |
# File 'lib/project/views/section_header_view.rb', line 11 def text=(text) section_title.text = text end |