robertwijas / UISS

UIAppearance Stylesheets
MIT License
1.23k stars 80 forks source link

Copperplate Font not showing up in Demo #35

Closed mulle-nat closed 10 years ago

mulle-nat commented 10 years ago

UISS sounds like a great idea. Unfortunately, when I tried it, I had some immediate very simple problems with it. (iPad Simulator 7.0.3).

When I run the UISSDemo it looks like this:

uissdemo

There is obviously no Copperplate font in sight, though the JSON thinks, there should be:

"UISSDemoFirstViewController": {
    "UIButton": {
        "backgroundImage:normal": ["button-background-normal", [0,10,0,10]],
        "backgroundImage:highlighted": ["button-background-highlighted", [0,10,0,10]],
        "titleColor:normal": ["white", 0.8],
        "titleColor:highlighted": "white",
        "titleEdgeInsets": [1,0,0,0],
        "UILabel": {
            "font": ["Copperplate-Bold", 18]
        }
    }
}

Also it would be nice, if there is a JSON parser error, to get at least in DEBUG some sort of console output.

robertwijas commented 10 years ago

UILabel.font is not marked as UI_APPEARANCE_SELECTOR so there's no guarantee it will work with UIAppearance proxy. I worked on 6.x though.

For 7.x try using textAttributes property introduced by UILabel+UISS category.

UISS 2.0 with better iOS 7 support is coming soon :)

codeon-nat commented 10 years ago

Yeah, but then why put it in the demo project (or not take it out) ? :) For first time users like myself, it's a head-scratcher.