Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't style UILabel class #136

Open
emptyarray opened this issue Nov 6, 2013 · 2 comments
Open

Can't style UILabel class #136

emptyarray opened this issue Nov 6, 2013 · 2 comments

Comments

@emptyarray
Copy link

I am trying to set a custom font as globally as possible, and the first things I tried were:

Teacup::Stylesheet.new(:main) do

  style UILabel,
        font: UIFont.systemFontOfSize(10)
end

and also (with Teacup::Appearance.apply in my app delegate):

Teacup::Appearance.new do

  style UILabel,
        font: "Helvetica".uifont(10)

end

whereas these work:

style UIView,
backgroundColor: UIColor.blackColor

style :label,
font: "Helvetica".uifont(10)

I am on iOS 7, and all my UILabels are inside TableViews. I have included the Teacup::TableViewDelegate.

Am I missing something or misunderstanding how styling classes is supposed to work? Thanks.

@colinta
Copy link
Owner

colinta commented Mar 19, 2014

Your code looks correct; a project that reproduces this would help me investigate it. I don't have the time to try and reproduce it with a new project.

@colinta colinta closed this as completed Mar 19, 2014
@colinta colinta reopened this Mar 19, 2014
@colinta
Copy link
Owner

colinta commented Mar 19, 2014

(oops, didn't mean to hit close)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants