We need a good code font for the function signatures on dlang.org
I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei
Re: We need a good code font for the function signatures on dlang.org
On Wed, Dec 16, 2015 at 04:05:27PM -0500, Andrei Alexandrescu via Digitalmars-d wrote: > I was looking at > https://github.com/D-Programming-Language/dlang.org/pull/1169 and that > bold sans serif proportional text for the code is just... well let's > say it's time to replace it. > > What would be a good code font to use for those? [...] Any monospaced font should do? T -- Дерево держится корнями, а человек - друзьями.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei I would just like to reiterate what I said in the other thread. Please don't use custom, downloaded fonts unless we do some optimizations on the website. On that note: Andrei, how do I get in contact with whoever runs the server to get that going? As for a good font that is supported on all browsers natively, courier new is good.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:40:13 UTC, Jack Stouffer wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei I would just like to reiterate what I said in the other thread. Please don't use custom, downloaded fonts unless we do some optimizations on the website. On that note: Andrei, how do I get in contact with whoever runs the server to get that going? As for a good font that is supported on all browsers natively, courier new is good. Just set style "font-family: monospace", and there you go. I don't think we even need to discuss a change like this.
Re: We need a good code font for the function signatures on dlang.org
On 12/16/2015 04:40 PM, Jack Stouffer wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei I would just like to reiterate what I said in the other thread. Please don't use custom, downloaded fonts unless we do some optimizations on the website. Sure, testing the speed impact of the change would be great. On that note: Andrei, how do I get in contact with whoever runs the server to get that going? Jan Knepper is our webmaster. You can find his contact info at https://www.janknepper.com/. As for a good font that is supported on all browsers natively, courier new is good. I was hoping for a nicer one and courier new as a fallback. Andrei
Re: We need a good code font for the function signatures on dlang.org
On 12/16/2015 04:32 PM, H. S. Teoh via Digitalmars-d wrote: On Wed, Dec 16, 2015 at 04:05:27PM -0500, Andrei Alexandrescu via Digitalmars-d wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? [...] Any monospaced font should do? Preferably a nice one. -- Andrei
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei I like Prestige Elite Std (or Prestige Elite), Latin Modern Mono and Cutive Mono. Cutive Mono is free on google fonts.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei Maybe Source Code Pro by Adobe?
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: What would be a good code font to use for those? http://sourcefoundry.org/hack/
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei Maybe one of the monospace fonts here https://www.google.com/fonts From the about page https://www.google.com/fonts#AboutPlace:about "A web with web fonts is more beautiful, readable, accessible and open." ... "Our API service makes it easy to add Google Fonts to a website in seconds. The service runs on Google's servers which are fast, reliable and tested. Google provides this service free of charge." ... "All of the fonts are Open Source."
Re: We need a good code font for the function signatures on dlang.org
On 2015-12-17 00:25, Andrei Alexandrescu wrote: I was hoping for a nicer one and courier new as a fallback. I use Menlo. I think that's default in TextMate, perhaps Xcode is uing that as well. Before that I used Monaco. I'm pretty sure they are both available by default on OS X. I'm not sure if it needs to be the same font on all platforms. -- /Jacob Carlborg
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei https://www.google.com/fonts Try with some text like: 0OQ iI1lL 2Z ~ () [] {} Ubuntu Mono Source Code Pro Inconsolata
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei On Windows, it doesn't look so awful:: http://imgur.com/8BuNoG6 That's probably because Verdana is installed by default and the body style is defined as "Bitstream Vera Sans", sans-serif>
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:32:29 UTC, H. S. Teoh wrote: Any monospaced font should do? Monospaced fonts have a common problem that they display "mm" as a tight knot of vertical lines (relevant for the commonPrefix example in the pull).
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei Is it's possible to colourize content like in, out, optional parameters etc?
Re: We need a good code font for the function signatures on dlang.org
On 12/17/2015 03:07 AM, Mike Parker wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: What would be a good code font to use for those? http://sourcefoundry.org/hack/ Could someone please round up this and other proposals into pull requests? Then we can see them displayed in Vladimir's rig. Thanks! -- Andrei
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? I don't think listening to random forum opinions (Inconsolata!!1) is a good process. What is the intention we want to convey with the font choice? a) Just use whatever is default, we dont care. (font-family:monospace;) b) Use what the viewer is familiar with. That depends on the OS and other factors. Consolas for Windows users? A quick google tour did not turn up any popularity statistics for "programmer fonts". c) Something beautiful. We are special. We care for every detail. We have a brand. Increased loading time for the website is the price to pay. It should also look the same on most systems. d) Any other relatively objective process?
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? I've recently become partial to Fira Mono. https://typecast.com/preview/google/fira%20mono:400:normal It has nice open counters, tall braces that don't overextend, and relatively weighty punctuation. http://typecast.com/blog/10-fonts-for-code There are a few others that may be worth considering here. I don't like the condensed fonts so much because I prefer "O" not be as narrow as "0". For zeros, dot > slash ≫ open. (I used a dotted version of Droid Sans Mono for a long time.) -Wyatt
Re: We need a good code font for the function signatures on dlang.org
On Thursday, 17 December 2015 at 16:01:01 UTC, Wyatt wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? I've recently become partial to Fira Mono. https://typecast.com/preview/google/fira%20mono:400:normal It has nice open counters, tall braces that don't overextend, and relatively weighty punctuation. http://typecast.com/blog/10-fonts-for-code There are a few others that may be worth considering here. I don't like the condensed fonts so much because I prefer "O" not be as narrow as "0". For zeros, dot > slash ≫ open. (I used a dotted version of Droid Sans Mono for a long time.) -Wyatt Fira Mono looked ugly to me. I use Input Mono for a while (Input Sans and Input Serif are available as well). http://input.fontbureau.com/preview/?size=16&language=clike&theme=solarized-dark&family=InputMono&width=300&weight=400&line-height=1.2&a=0&g=ss&i=0&l=0&zero=0&asterisk=0&braces=0&preset=default&customize=please Not very smooth like Consolas etc, but it is very readable.
Re: We need a good code font for the function signatures on dlang.org
On 12/17/15 10:43 AM, qznc wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? I don't think listening to random forum opinions (Inconsolata!!1) is a good process. Then I guess I should stop reading here :o). What is the intention we want to convey with the font choice? a) Just use whatever is default, we dont care. (font-family:monospace;) b) Use what the viewer is familiar with. That depends on the OS and other factors. Consolas for Windows users? A quick google tour did not turn up any popularity statistics for "programmer fonts". c) Something beautiful. We are special. We care for every detail. We have a brand. Increased loading time for the website is the price to pay. It should also look the same on most systems. d) Any other relatively objective process? The task is intentionally loosely defined. "Make a different nice font choice for the function signatures." There shouldn't be a need to micromanage that. Andrei
Re: We need a good code font for the function signatures on dlang.org
On Thursday, 17 December 2015 at 15:43:22 UTC, qznc wrote: I don't think listening to random forum opinions (Inconsolata!!1) is a good process. ...And I was about to say Source Code Pro and Inconsolata are my favorite fonts to use. >_> I think they fit the "nice" quality Andrei is looking for.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei I personally use Fantasque Sans Mono, it's FOSS (https://github.com/belluzj/fantasque-sans). It has good support for lIi1 and others. But that is just an opinion, I just find it beautiful.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei In the interest of "Show Don't Tell", here's what the homepage looks like using the following font string: font-family: Consolas, "Liberation Mono", Courier, monospace http://imgur.com/DIymzqO
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei Consolas is pretty solid IMO. It is not only good for code but readable even from a long distance with it's round nature. In fact my CLI, Atom and every IDE I use have font face set to Consolas. Pretty neat.
Re: We need a good code font for the function signatures on dlang.org
On 12/17/15 4:30 PM, Eric Scrivner wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei In the interest of "Show Don't Tell", here's what the homepage looks like using the following font string: font-family: Consolas, "Liberation Mono", Courier, monospace http://imgur.com/DIymzqO Looks good. What would the phobos function signatures look like? -- Andrei
Re: We need a good code font for the function signatures on dlang.org
On Thursday, 17 December 2015 at 21:30:21 UTC, Eric Scrivner wrote: In the interest of "Show Don't Tell", here's what the homepage looks like using the following font string: font-family: Consolas, "Liberation Mono", Courier, monospace Consolas + 1. Hack is too vertical to my taste.
Re: We need a good code font for the function signatures on dlang.org
On Thursday, 17 December 2015 at 13:59:14 UTC, Andrei Alexandrescu wrote: On 12/17/2015 03:07 AM, Mike Parker wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: What would be a good code font to use for those? http://sourcefoundry.org/hack/ Could someone please round up this and other proposals into pull requests? Then we can see them displayed in Vladimir's rig. Thanks! -- Andrei https://github.com/D-Programming-Language/dlang.org/pull/1170 https://github.com/D-Programming-Language/dlang.org/pull/1171 https://github.com/D-Programming-Language/dlang.org/pull/1172 https://github.com/D-Programming-Language/dlang.org/pull/1173 Despite people's requests, Consolas is a premium font owned by Microsoft, so it cannot be used. Inconsolas was included instead.
Re: We need a good code font for the function signatures on dlang.org
On 12/18/2015 04:06 PM, Jack Stouffer wrote: On Thursday, 17 December 2015 at 13:59:14 UTC, Andrei Alexandrescu wrote: On 12/17/2015 03:07 AM, Mike Parker wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: What would be a good code font to use for those? http://sourcefoundry.org/hack/ Could someone please round up this and other proposals into pull requests? Then we can see them displayed in Vladimir's rig. Thanks! -- Andrei https://github.com/D-Programming-Language/dlang.org/pull/1170 https://github.com/D-Programming-Language/dlang.org/pull/1171 https://github.com/D-Programming-Language/dlang.org/pull/1172 https://github.com/D-Programming-Language/dlang.org/pull/1173 Despite people's requests, Consolas is a premium font owned by Microsoft, so it cannot be used. Inconsolas was included instead. Cool, thanks! Shall we take one of them rigged referendums? -- Andrei
Re: We need a good code font for the function signatures on dlang.org
On Friday, 18 December 2015 at 21:15:48 UTC, Andrei Alexandrescu wrote: rigged referendums Huh?
Re: We need a good code font for the function signatures on dlang.org
On 12/18/15 4:19 PM, Jack Stouffer wrote: On Friday, 18 December 2015 at 21:15:48 UTC, Andrei Alexandrescu wrote: rigged referendums Huh? Forgot the smiley - you know, all that online voting that swung wildly which every way. -- Andrei
Re: We need a good code font for the function signatures on dlang.org
On 12/16/2015 3:22 PM, Andrei Alexandrescu wrote: Preferably a nice one. -- Andrei I prefer bad ones. -- Walter
Re: We need a good code font for the function signatures on dlang.org
On 12/16/2015 1:05 PM, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. I've always hated proportional fonts for code, so much that I read a book on Modula II in the 80's and irrationally disliked it because it used a proportional font for the code and looked so ugly. I never got that bad taste for M2 out of my mouth.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 23:25:01 UTC, Andrei Alexandrescu wrote: On that note: Andrei, how do I get in contact with whoever runs the server to get that going? Jan Knepper is our webmaster. You can find his contact info at https://www.janknepper.com/. It seems his email server is down. Do you know of any other way to contact him?
Re: We need a good code font for the function signatures on dlang.org
Some fonts examples http://www.slant.co/topics/67/~programming-fonts
Re: We need a good code font for the function signatures on dlang.org
On Thursday, 17 December 2015 at 07:35:50 UTC, ZombineDev wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei Maybe Source Code Pro by Adobe? +1, this is an excellent code font.
Re: We need a good code font for the function signatures on dlang.org
On Friday, 18 December 2015 at 21:48:36 UTC, Andrei Alexandrescu wrote: On 12/18/15 4:19 PM, Jack Stouffer wrote: On Friday, 18 December 2015 at 21:15:48 UTC, Andrei Alexandrescu wrote: rigged referendums Huh? Forgot the smiley - you know, all that online voting that swung wildly which every way. -- Andrei After thinking about this more, I came to believe that you should just pick one, merge it, and we can move on to other things, as we already have about six bikeshedding discussions on the front page of General about the website and the font of the code is such a minor point.
Re: We need a good code font for the function signatures on dlang.org
On Thursday, 17 December 2015 at 21:30:21 UTC, Eric Scrivner wrote: In the interest of "Show Don't Tell", here's what the homepage looks like using the following font string: font-family: Consolas, "Liberation Mono", Courier, monospace http://imgur.com/DIymzqO FYI, everything after "Consolas" doesn't matter because you posted a screenshot, and it will not look like in the screenshot on non-Windows systems.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? Thanks, Andrei Let's stay away from web fonts. Rationale: Different text rendering algorithms will render the same text and font file in different ways. A font may look nice on one platform, but pretty bad on another. The default fonts (i.e. monospace) are generally set to something that will look fine on that system. Other fonts bundled with the OS are also likely to look good. Using a custom font may thus make the text less readable on some platforms (plus the downsides already mentioned in this thread). I am not completely opposed to the idea of using a web font, on the condition that it is tested and does not lead to a downgrade of usability on any of the major platforms, but I don't think the downsides are worth it. Looking at what other people are doing (and have much more resources to think about such things): Microsoft (MSDN): Consolas,Courier,monospace Apple: Menlo,monospace Android: Consolas,"Liberation Mono",Menlo,Courier,monospace Go: Menlo,monospace Java: monospace Python: Consolas,"Lucida Console","Liberation Mono","DejaVu Sans Mono","Bitstream Vera Sans Mono","Courier New",monospace,sans-serif It seems that all of the above are fonts that are likely to be already installed on users' systems.
Re: We need a good code font for the function signatures on dlang.org
On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: I was looking at https://github.com/D-Programming-Language/dlang.org/pull/1169 and that bold sans serif proportional text for the code is just... well let's say it's time to replace it. What would be a good code font to use for those? My favourites would be: Menlo, DejaVu Sans Mono, Ubuntu Mono. But don't embed them, just provide a safe fallback, like monospace.
Re: We need a good code font for the function signatures on dlang.org
On 12/18/2015 04:06 PM, Jack Stouffer wrote: On Thursday, 17 December 2015 at 13:59:14 UTC, Andrei Alexandrescu wrote: On 12/17/2015 03:07 AM, Mike Parker wrote: On Wednesday, 16 December 2015 at 21:05:27 UTC, Andrei Alexandrescu wrote: What would be a good code font to use for those? http://sourcefoundry.org/hack/ Could someone please round up this and other proposals into pull requests? Then we can see them displayed in Vladimir's rig. Thanks! -- Andrei https://github.com/D-Programming-Language/dlang.org/pull/1170 https://github.com/D-Programming-Language/dlang.org/pull/1171 https://github.com/D-Programming-Language/dlang.org/pull/1172 https://github.com/D-Programming-Language/dlang.org/pull/1173 Despite people's requests, Consolas is a premium font owned by Microsoft, so it cannot be used. Inconsolas was included instead. Thanks for this work! I chose Inconsolata, https://github.com/D-Programming-Language/dlang.org/pull/1170. -- Andrei