Skip to content
Eonist edited this page Mar 20, 2017 · 2 revisions
img

Testing some states with some different styles :

CSS:

TextButton{
   fill:red;
}TextButton:over{
   fill:yellow;
}TextButton:down{
   fill:green;
}Text{
   font:Lucida Grande;
   selectable:false;
   size:22px;
   color:blue;
   align:center;
   backgroundColor:orange;
   background:false;
}Text:down{
   color:white;
}

Swift:

StyleManager.addStyle(css)
let textButton = TextButton("Hello world",200,80)
self.addSubview(textButton)
img
Clone this wiki locally