www.webdeveloper.com
Results 1 to 8 of 8

Thread: 2 small questions

  1. #1
    Join Date
    Dec 2002
    Posts
    14

    2 small questions

    how do i make a font in css, i see these css files that have 5 different fonts in them and it looks like one i've never seen, does the css file combine all those fonts? and if so, how can i know what will look good?

    also, what i mainly want the css for is to have background images that dont move with the text arrows. can someone tell me how to do that? or iff i can do it without css?


    thanks alot.
    patrick

  2. #2
    Join Date
    Nov 2002
    Posts
    631
    For the fonts:

    font:normal 12pt "font 1","font 2","font 3";

    normal = normal, bold, bolder, light, lighter

    12pt (point value) or 15px (pixel value), 200% (this would be 200% bigger than the text is by default)

    font 1, 2, and 3: Font 1 would be the main font, if the user doesn't have it installed on their computer, font 2 would be used, etc.



    Background image:

    This can be done without CSS:

    <body background="img.ext" bgproperties="fixed">

  3. #3
    Join Date
    Dec 2002
    Posts
    14
    ok, so css doesn't create fonts, it just gives you more options as far as what the viewer has installed on they're comp, right?

  4. #4
    Join Date
    Nov 2002
    Posts
    631
    Right.

  5. #5
    Join Date
    Dec 2002
    Posts
    14
    thanks

  6. #6
    Join Date
    Nov 2002
    Posts
    984
    Originally posted by Zach Elfers
    normal 12pt
    Avoid using pt unless you are making a stylesheet for print. It will vary in relative size especilly between different OS.

    If you must use a fixed size stick to px, but % is usually better (especially since IE has a bug that makes fonts in px not scale when people try to increase/decrease fontsize).

    "font 1","font 2","font 3";
    Remember to always end the list of different fonts with a general family in case the user doesn't have ANY of the fonts you list.
    http://www.w3.org/TR/REC-CSS2/fonts....-font-families

    Background image:
    This can be done without CSS:
    Yes, but why? It's longer as well as clumsier since you have to specify it on every page on your site instead of being able to specify it in your external css file one for your entire site.

    {background: url(img.ext) fixed;}

  7. #7
    Join Date
    Dec 2002
    Location
    Perth, Western Australia
    Posts
    55

    embedded fonts

    If you have seen a web page display a font that is not installed on your system, the author could be using Embedded fonts. This is a couple of systems, like Embedded OpenType and TrueDoc, but they only work for some browsers. I never tested the technology myself, because it seems like a huge waste of time for what it gives you, but you could read about it here:
    http://hotwired.lycos.com/webmonkey/...tutorial2.html

  8. #8
    Join Date
    Nov 2002
    Location
    XYZZY - UK
    Posts
    1,760
    Yes, I have seen sites that have embedded fonts, used via CSS and out of interest the Cascading Style Sheets, Level 2 revision 1 is in favour of deprecating such a method and waiting until CSS-3 hits the road when theoretical things like SVG could be used as a CSS WebFont reference base.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles