Get Updates By E-mail 

Article Written By:
Johann Dowa

Open Source Library Allowing You To Easily Style iOS UIKit Elements With Style Sheets

  •  
  •  
  •  
  •  
  •  

I’ve mentioned a couple of libraries that allow you to style UIKit elements using a CSS style syntax such as NUI, and UISS.

Here’s an interesting new project called Classy from Jonas Budelmann that allows you to use stylesheets to style your UIKit elements.

What’s unique about Classy is that rather than try to implement CSS styling Classy uses its own stylesheet syntax which works extremely well.

Classy supports all UIAppearance properties and methods and more.

Here’s an example from the homepage of a valid style sheet:

$main-color = #e1e1e1;

MYCustomView {
  background-color: $main-color;
  title-insets: 5, 10, 5, 10;
  > UIProgressView.tinted {
    progress-tint-color: black;
    track-tint-color: yellow;
  }
}

^UIButton.warning, UIView.warning ^UIButton {
  title-color[state:highlighted]: #e3e3e3;
}

A nice clean syntax for styling your interfaces, and you can reload the stylesheets and see changes in real time which helps in coming up with the right style during development.

You can read more about Classy and its usageon the homepage here.

You can download Class from the repository on Github here.

A very nice library for easily styling UIKit Elements.


  •  
  •  
  •  
  •  
  •  

Submit A Resource

Have you created a useful tutorial, library or tool for iOS development that you would like to get in front of our 300,000+ monthly page views from iOS developers?

You can submit the url here.

The resources we feel will appeal to our readers the most will be posted on the front page.

Comments