-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Find the best PNG + Retina solution #113
Comments
What would be really helpful is a screenshot comparison in the browsers you use most often, on your machine. (Note, use PNG, and embed them in a comment; GitHub still authorizes that!) |
Is this a retina screen? Is the zoom at 100%? |
Yes, retina screen. Nothing has been zoomed. Screenshots just appear 2x size because of the retina screen. I think there might be two issues here. First, the png is not @2x. Second, the antialiasing makes the text a bit blurry and dark. |
Unfortunately, making the image 2x is a third of the issue. Chrome (and other browsers) will render the image just as blurry; it's simply going to be twice as big. There are a few ways to tell the browser how to render it well, but those are not yet standard. Besides, some 3x screens are already coming to the market. We can make this issue a follow-up to #102 focused on finding the best way to have PNG images on retina. |
If you offered @2x images, one option would be to just specify a "height" inline in the HTML. It is perfectly valid to include html within a markdown document. For example, with the following html: <img src="image@2x.png" height="313"> I can render the retina screenshot from above at the perfect size. The width automatically scales with the explicit height that we set. This is perfect since badges have a consistent height, but variable width. Just don't specify a width and the browser will scale it proportionally. |
^ I think this would solve the retina problem for PNG images. |
@feross I'll try to implement |
Yep, I agree that svg is preferable. Too bad it's currently not an option due to #112. When/if that's resolved, I'll happily switch back to svg! Also, thanks for being so responsive :) |
I want to use svg images, but due to issue #112, that's no longer an option that GitHub supports. What would it take to make the typeface in the png images look as nice as it does in the svg images?
PNG vs SVG (can't embed it due to issue #112, lol)
The text was updated successfully, but these errors were encountered: