quattro_4 scribble

scribble 落書き (調べた事をただ落書きする)

MotionInMotion Episode 10 - Teacup

Teacup - MotionInMotion

teacupなどを使ってスタイルやconstraintsを設定

  • teacup
    • sugarcube
    • sweettea (teacup + sugarcube = sweettea)
  • class PostView < UIView
    • layout self do
      • subview UITextView, :content_view, {
  • app/styles/
    • Teacup::Stylesheet.new :main_window do
      • style :hi_button,
  • class PostDetailController < UIViewController
    • viewDidLoad
      • layout self.view, :post_view
  • constraints
    • style :post_view,
      • constraints: [
      • constrain_left(0),
      • constrain(:width).equals(:superview, :width),
    • PostView
      • self.stylesheet = Teacup::Stylesheet[:main]
      • apply_constraints