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

[Dark] [Light] [HTML] Too much italics in STYLE element. #10

Closed
Zegnat opened this issue Apr 26, 2011 · 6 comments
Closed

[Dark] [Light] [HTML] Too much italics in STYLE element. #10

Zegnat opened this issue Apr 26, 2011 · 6 comments

Comments

@Zegnat
Copy link
Contributor

Zegnat commented Apr 26, 2011

Currently you are setting source.css.embedded.html to italics. This is wrong. Only the tag name (style) should use italics. The way it is set-up now attributes (likes type) and the tag itself (< and >) use italics as well.

  • source.css.embedded.html should use the regular font.
  • source.css.embedded.html entity.name.tag.style.html should use the italic font.
@deplorableword
Copy link
Owner

This issue is now fixed in light and dark, thanks for spotting it. 8626d5f

@Zegnat
Copy link
Contributor Author

Zegnat commented Apr 27, 2011

It’s not fixed for me. The type attribute it still displayed in italics. Another clear sign of this bug is how ID selectors (#id) are being italicised.

The culprit seems to be “HTML: Embeddable” which sets source.css.embedded.html to italic. It seems this rule is used to italicise the <!-- --> used to hide CSS from ancient browsers? I’ve been toying around with it but it seems impossible to italicise only the HTML comment…

This TextMate selector was the closest I got: source.css.embedded.html - entity - meta - punctuation.

This will pass on any entity (these are attributes inside the style tag), any meta (these are all matched CSS elements, eg. selectors) and any punctuation (these match the < and > of the style tag). This is only close because it will still italicise characters within the tag that it doesn’t have other selectors for, like the = between the attribute name and value.

(Incidentally this also means the = takes on the colour set to source.css.embedded.html making it a lighter base colour than it should be.)

@deplorableword
Copy link
Owner

How does this look?

http://i52.tinypic.com/qznkp4.png

@Zegnat
Copy link
Contributor Author

Zegnat commented Apr 30, 2011

Yes, that is the only other real solution: to not italicise source.css.embedded.html at all.

It also looks like it’s a too light base colour or is that just me? Comments (in Dark) would normally be base01 (#586E75) according to Solarized Usage & Development.

(Sorry, I accidentally hit “Comment & Close”.)

@Zegnat Zegnat closed this as completed Apr 30, 2011
@Zegnat Zegnat reopened this Apr 30, 2011
@deplorableword
Copy link
Owner

Cool, I'll go ahead and merge in that change.

@deplorableword
Copy link
Owner

Just added in those changes, I've also learned you can prevent a selector from inheriting italics by setting an unsetting italics in theme editor which creates an empty fontStyle.

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