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

Change font and font-size for specific theme #64

Open
ivancantarino opened this issue May 1, 2019 · 6 comments
Open

Change font and font-size for specific theme #64

ivancantarino opened this issue May 1, 2019 · 6 comments

Comments

@ivancantarino
Copy link

ivancantarino commented May 1, 2019

Hello.

I was wondering if there's a way to change the font and the font size for a specific theme, let's say "Markdown".

I've tried to set it as the font of the UITextView but it keeps changing to some default one. I think that it changes due to the applied theme but I cannot find where it is default set to.

I'm using CodeAttributedString to perform the real time highlight

Can someone point me in the right direction?

@ivancantarino
Copy link
Author

I noticed I could do this in previous versions of highlightr but now I cannot, and don’t know why.
@raspu any hint?

@ivancantarino
Copy link
Author

I’m currently using the default.min.css theme and I’ve looked into the file and cannot find a way to change the font. I’ve looked as well into the CodeAttributedString and where the font is set to Courier whenever I change that value the font stays the same

@raspu
Copy link
Owner

raspu commented Jun 3, 2019

Did you tried using setCodeFonton the Theme object?

@ivancantarino
Copy link
Author

Yes I did, but it doesn’t work!

@funkenstrahlen
Copy link

It does work for me as expected.

@zachgibson
Copy link

Works for me too.

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

4 participants