Thread: Linux - Windows common fonts.

  1. #1
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218

    Linux - Windows common fonts.

    I'm making a website template at the moment, and I'm not too keen on the 'times new roman font'. Anyone got any suggestions as to some nice fonts I could use that come as standard with both windows and linux? Atm all I can think of is sans.

    Cheers.

  2. #2
    Lurking whiteflags's Avatar
    Join Date
    Apr 2006
    Location
    United States
    Posts
    9,613
    Arial Narrow, Tahoma, and Verdana are some nice sans-serif fonts of varying widths. If linux does not have them, they're likely to be installed with Star Office. So there you go.

  3. #3
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218
    Yeah Verdana is one of my favorites, but it seems I don't have it on my Linux pc. I got open office too. I dont know maybe I'll add a javascript to check the OS and then load a stylesheet dependent on whats being run.

    Cheers.

  4. #4
    Lurking whiteflags's Avatar
    Join Date
    Apr 2006
    Location
    United States
    Posts
    9,613
    Mhm, Star Office isn't open office. Style sheets already have the capability to degrade gracefully or whatever, so there's no need for any scripting magic. Just use the font-family property in your rules.

    Arial Narrow looks nice in my opinion. You might want to adjust the letter spacing in your style sheet.

  5. #5
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    See if your distro has a "corefonts" package, it ought to contain Verdana, Tahoma, Courier New, Times New Roman, Arial and a few more.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  6. #6
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    Quote Originally Posted by mike_g View Post
    I'm making a website template at the moment, and I'm not too keen on the 'times new roman font'. Anyone got any suggestions as to some nice fonts I could use that come as standard with both windows and linux? Atm all I can think of is sans.

    Cheers.
    As far as my experience goes, the default browser font is chosen on each platform to actually look good. Why second-guess it? Just make the basic decision whether you want it to be serifed or not and let the browser pick the font.

  7. #7
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218
    CornedBee: thanks, I'll have a look for it.

    Brewbuck: I'm a bit of a weird one when it comes to laying out web pages, I don't use standard p, or h tags; I generally make custom id's and chuck everything in divs. And if I leave it up to Firefox it seems to like to picking yucky serif fonts for me.

  8. #8
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    28,413
    I don't use standard p, or h tags; I generally make custom id's and chuck everything in divs.
    You can use the appropriate paragraph/heading elements with custom ids too.
    Quote Originally Posted by Bjarne Stroustrup (2000-10-14)
    I get maybe two dozen requests for help with some sort of programming or design problem every day. Most have more sense than to send me hundreds of lines of code. If they do, I ask them to find the smallest example that exhibits the problem and send me that. Mostly, they then find the error themselves. "Finding the smallest program that demonstrates the error" is a powerful debugging tool.
    Look up a C++ Reference and learn How To Ask Questions The Smart Way

  9. #9
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218
    Yeah I know its just for some reason I never bothered using them.

  10. #10
    Ethernal Noob
    Join Date
    Nov 2001
    Posts
    1,901
    Anyone know of any Monospace fonts with serifs?

  11. #11
    Lurking whiteflags's Avatar
    Join Date
    Apr 2006
    Location
    United States
    Posts
    9,613
    Courier new.

  12. #12
    Ethernal Noob
    Join Date
    Nov 2001
    Posts
    1,901
    ...I'm so used to it I forget they have them.

    *continues to fail*

  13. #13
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    You can use something like this CSS (copied from my web site):
    Code:
    font-family: Verdana, Geneva, Helvetica, Arial, sans-serif;
    It tries Verdana, then Geneva, etc, and failing all else, whatever sans-serif font the user has selected to be the default "sans-serif font".

    It should be noted that I've never actually seen Geneva, I just got it somewhere; someone said it was a nice sans serif font for UNIX or Mac or something.

    Here's what I use for monospace, because I don't care so much what it looks like:
    Code:
    font-family: 'Courier New', Courier, monospace;
    Anyway, just a thought . . . .
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  14. #14
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218
    Oh cool, I'll do that then. I think remember seeing that used before actually.

  15. #15
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    Actually, I have to discourage you from doing that. Unless you actually test every single of these fonts, making sure that they fit into the layout and look good, you should leave the choice to the user's browser, using the generic font names. After all, if you haven't actually made sure that your font choice looks better than otherwise, who are you to dictate font choices? Perhaps I have my own special, beautiful serif font that I want to be used whenever the website author couldn't think of anything better. Should I be forced back to Times New Roman just because the author was too lazy to think about what he's doing?

    Typography is important.

    For example, I can compare four sans-serif fonts on my Linux box: Arial, Bitstream Vera, DejaVu and Verdana. I do this at three font sizes.
    Generally speaking, Bitstream and DejaVu are extremely similar. DejaVu has slightly thinner lines, making it easier to read at small sizes (9pt). Bitstream has an odd bug where an r followed by an e leads to a huge gap. Could be OpenOffice, though. The fonts have pretty much the same metrics otherwise.
    Verdana is also very similar. It was designed to be readable at small sizes, and it shows. It's a little wider than the other two at 12pt. It's definitely more readable at 9pt. It's butt ugly at 32pt.
    Arial looks completely different. It's very narrow, with strong strokes, making it look very compact, but hard to read at small sizes. On the other hand, it looks better than the others at 32pt.

    Typography is hard.

    But as a simple guideline, I can say this: never put Verdana and Arial in the same font chain. They serve different purposes and look nothing alike. Claiming that one can replace the other is simple ignorance.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Script errors - bool unrecognized and struct issues
    By ulillillia in forum Windows Programming
    Replies: 10
    Last Post: 12-18-2006, 04:44 AM
  2. linux and windows lookup host processes
    By Lynux-Penguin in forum Tech Board
    Replies: 0
    Last Post: 08-31-2003, 11:54 PM
  3. FlashWindowEx not declared?
    By Aidman in forum Windows Programming
    Replies: 3
    Last Post: 05-17-2003, 02:58 AM
  4. Linux OS to Windows OS code
    By sw9830 in forum C Programming
    Replies: 2
    Last Post: 02-28-2003, 03:11 PM
  5. Linux and Windows Duel Boot
    By The15th in forum A Brief History of Cprogramming.com
    Replies: 7
    Last Post: 04-26-2002, 04:59 AM