Beefy Boxes and Bandwidth Generously Provided by pair Networks Bob
Don't ask to ask, just ask
 
PerlMonks  

Re^3: revise font?

by halley (Prior)
on Jun 30, 2005 at 16:59 UTC ( [id://471474]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Re^2: revise font?
in thread revise font?

The point is, you cannot specify both font-family: monospace and font-family: sans-serif; they are mutually exclusive options thanks to the way the CSS specification has been written.

As for whether or not it's a design issue, I would say the flaw of the design is in the font itself, not in whether or not it has serifs. To wit, my monospace fonts make it clear that 1 is one but l is ell. This may vary from system to system, as the fonts included on a user's computer are not something over which a website has much control.

--
[ e d @ h a l l e y . c c ]

Replies are listed 'Best First'.
Re^4: revise font?
by ww (Archbishop) on Jun 30, 2005 at 21:23 UTC

    Update, 01 Jul after rereading parent: Agree: no, you cannot use both "serif" and "monospace" as the DEFAULT style (last) in a stylesheet, but there is nothing in the css spec to prevent you from including, by name, a monospace, sans-serif font, as the original code below was intended to illustrate
    HOWEVER, membership in the "monospace" class has NOTHING WHATSOEVER to do with whether a font has or lacks serifs. Membership in "monospace" indicates ONLY that it is one of a class of fonts in which each character occupies the same amount of horizontal space.
    </update #2>

    /* I believe PM uses both <code> and .c   demerphq corrects me below*/

    <style type="text/css"> <!-- code, .c { font-family: "unix_sans_serif_monospace choice here", and_another_if_desired, MAC_choice(s), windoze_choice(s), monospace; } -->
    The w3c spec calls for the browser to use the first font it recognizes/has available. If neither specified font (pseudo-coded here as unix_font(s)) is available, try MAC, then windows... and only if no suitable font is avail, default to the system's default monospace. NB: This is NOT doing OS recognition -- it simply causes a compliant browser (today: most of 'em for the purpose of this discussion)to walk thru the list of faces specified by the designer (unless the user has overidden with a personal stylesheet). If a given font is available on a windows box with the name spec'ed in the first alt above, so be it: it's probably gonna' be acceptable.

    Update #1 Reformatted code for easier readability, emended some language in previous paragraph for precision, 01 Jul

      code, .c { /* I believe PM uses both */

      Actually I dont think so. CODE and C tags are pseudo tags that get transformed by the PM rendering engine. The class code however has meaning. If you find any examples of CODE tags leaking out please report them.

      ---
      $world=~s/war/peace/g

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://471474]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.