CSS - Css Font Question
Is possible to write this in one line? :
Code: font: 12px Verdana,Arial,Helvetica,sans-serif; line-height: 1.4; What I need to do to put line-height: 1.4; in font line ? Similar TutorialsThe font-stretch property, for example:
css Code: Original - css Code font-stretch: condensed; font-stretch: condensed; doesn't seem to be adequately supported by most browsers, even though it has been part of CSS 2 for quite a while. Most references I checked seemed to point to system font dependency, i.e., if your system does not have a condensed or expanded version of that particular font installed, no change in font width will appear. Why is this? Microsoft Word has an algorithm to stretch and condense all fonts, not just those with special versions. Why can't the css standard use a similar display algorithm to implement font-stretch? Hi, In the code below, when i put the font to arial, i do not see any difference, i mean if I have it arial or if I do not have any style tags it does not make any difference the way text look. Am I doing something wrong here. Code: <html> <head> <style> td {font-family:arial} </style> </head> <table> <tr><td>John</td></tr> <tr><td><p>Pong</p></td></tr> </table> </html> I have two easy questions about CSS... 1. Can two font-size settings interfere with each other if the they overlap? For example, suppose I have a page set to have the font at size 14px. Then within that page, I do a <p> tag that sets the font size to 10px. Is the font size relative (do they add, multiply, whatever), or is 10px absolute? It seems like 32px is a lot for a heading I'm making, but that's how big I needed to set it for it to look like a heading... It wouldn't show up super-big on another computer with a different browser, would it? 2. Is there any way in CSS to change the amount of space before and after a <p> tag? I have one paragraph right after another, and I want to get rid of some of the space that is between them. Thanks in advance. Hi, If you set a font-size: 7pt and font-family:Verdana in your stylesheet, does the text in your webpage look slightly bigger in Firefox than in IE 6? I'm using Windows by the way ... this is just a general question as some of my menu links are lined up well on IE (which displays text a bit smaller) but overlapping to multiple lines on Firefox (because the text size is slightly bigger) Many thanks! Hi there, Does anyone know what font this is that is used for text such as "Everything you need to get a professional website online" at the top and below: "Takeaway Website Standard" When I highlight it, it has a black bacground which is unusual. Any ideas? Thanks! I have a 'DIV' tag, its css height property is set to 15px. Why is it, that it's not really 15px until I insert "font: 10px Verdana " *** one of the rules? So fi I have: #topSeperate { height: 15px; width: 100%; background-color: #00FF00; font-weight: bold; font: 10pt Verdana; } The div is perfect, but as soon as I remove the font: tag, it grows in height about 4px even though there is no text typed in the 'DIV'. If this doesnt make sense and you need further explaination, Let me know. I am trying to use this font for my text: http://www.google.com/webfonts/specimen/Droid+Sans I have tried using: font-family: 'Droid Sans', Arial, Helvetica, sans-serif; but it doesn't work. Any ideas? Thanks! Is there any way to embed font so it would be viewable by firefox? I know yo can do it in IE, but can't find a way for firefox. Thanks, Greg Can someone please tell me what the font-stretch property within CSS does? I have been playing around with the following online example, but the way the text is rendered never changes. [access the world wide web]w3schools.com/js/tryit.asp?filename=try_dom_style_fontstretch Could someone please tell me how to use the font-stretch property? I am just trying to see what it does. Thank you! People viewing my site at 120 dpi are seeing misaligned text and layout, whereas people viewing the site at 96dpi can see it properly. I'm using "em" instead of pixels when setting font sizes in CSS. The site has fixed length and width, do I HAVE to allow it to resize itself? Hello, I would like to know if a font can be imported into a CSS. I am asking that because it would be very nice if I had the opprtunity to design my webpage with the fonts that I want, in order to achieve the desirable layout. Thank you. Hello, My font shorthand have this different outputs on IE and FF Quote: h1 { /*font-size: 16px; font-weight: bold; font-style: normal;*/ font: normal medium bold 16px Verdana, Arial, Helvetica, sans-serif; margin: 0 10px; padding: 15px 0 5px 0; color: #FFF; } If I replace the font-variant at shorthand it works well on IE but still the font size is not rendered Quote: font: normal larger bold 16px Verdana, Arial, Helvetica, sans-serif; the commented long hand is what I'm trying to get Well, the title might be a little oversimplified, but I guess it caught your attention In the past, I always set my font sizes using px. I know that this is not the appropriate standard (since it doesn't allow a user to re-size the font on their end), but I usually did it because it was easiest and most predictable. Now, I finally want to make the step towards more accessibility and I would like to learn a little bit more about using em's appropriately. Does anyone have any good advise on how to get started with the following questions: How/where do I set the initial font-size, from which I can use em's? What are the dangers of using em's instead of px? Where could this change impact my usual styling? Are there any good resources/tutorials about this? Any help/suggestions/ideas are appreciated... i copied some of this code from a page i liked. all it is is a background image and i want to type text over it that is in a table. the problem is i cannot center my text ("<?=$information[nickName]?>"). the text always is on the left, never in the center. i have tried different things such as <td align=center> as opposed to the <td valign=center> the other author has in the 2nd block, the align:center does not work with font. and i have tried appending a ;text-align:center within that SPAN tag, but that does not work either. does anyone have any advice??? thanks! <table border=0 cellspacing=0 cellpadding=0 width="750" style="border: solid black 2px;"> <tr><td style="background-image:url(images/name_test.jpg); background-attachment: 100% 0%"> <table border="0" cellspacing=0 cellpadding=1><TR><TD valign="center"><SPAN style="font-size: 14pt; font-family: arial black, helvetica; padding: 3px; align: center;"><?=$information[nickName]?></SPAN></TD></TR> </table> Hi, Suppose I define a font-family with several fallbacks, for example: Code: font-family: "Georgia", "Liberation Serif", serif; Now I would like to know which font did the browser effectively pick without me having to go through my system looking for which fonts are installed. When I inspect the text with tools such as Firebug or the Web Developer Toolbar, they just give me the full font-family definition, but don't tell me the actual font being used... Thank you in advance! Jean hi, someone using foxfire keeps saying the my font is really really tiny, I have my css file like:
Code: body { background: #FFFFFF; /* for internet explorer */ scrollbar-face-color: #FFFFFF; scrollbar-highlight-color: #FFFFFF; scrollbar-shadow-color: #FFFFFF; scrollbar-3dlight-color: #494969; scrollbar-arrow-color: #494969; scrollbar-track-color: #FFFFFF; scrollbar-darkshadow-color: #494969; margin: 0px; padding: 0px; border: 0px; border-top: 1px solid #8E9397; border-left: 1px solid #8E9397; font-color: #494969; font-family: Verdana,Arial,Helvetica; font-size: 8pt; text-align: left; } a:link,a:active,a:visited { color: #494969; text-decoration: none } a:hover { text-decoration: underline; color: #494969; position: relative; top: -1px; left: -1px; } hr { background: transparent; color: #494969; height: 1px; border-width: 0px; } fieldset { margin: 0; padding: 1px; border: 1px solid #494969; } legend { margin: 0; padding: 7px; color: #494969; background: transparent; font-weight: bold; } img { border: 0px; } table { background: transparent; } tr { background: transparent; } td { background: transparent; color: #494969; font-family: Verdana,Arial,Helvetica; font-size: 70%; } input, textarea, select { color: #494969; font: normal 11px Verdana, Arial, Helvetica, sans-serif; background: transparent; border: 1px solid #494969; border-style: inset; text-align: center; text-indent: 2px; } form { margin: 0px; padding: 0px; } any idea on whats wrong? and I would of changed the % to an actual value but I wanted to make it so people can control the size of the font to lager or smaller here is a preview with that css file in use : http://www.dbznetwork.net/ I'm making a site, and the guy I'm making it for says he wanted a more 'tough' font. So I downloaded a, 'tough' but still readable of course, font. The main page has an iframe, and the content in the iframe is where the text goes that has the tough font. Everything works when it's offline. But when I try uploading it, it's the old font. I even check the source and it's all old. The server is running extremely slow right now, so that might be the problem and it just hasn't uploaded yet or something. Because I also deleted the content files and refreshed the page and it was still old. So, I'll wait a little longer and check or something. I also know that viewers can't see custom fonts if they don't have them on their pc. So this is kind of seeming pretty pointless. But is there ANYWAY I Can make it viewable to everyone that views the site. So they can see the font even if they don't have it on their pc. Like, make them have it temporarily or something. My friend told me it had something to do with CSS, but I don't really know. Anything I can do to make it work? Is there maybe a Java Script I can use? Hey everyone. I've been reading up on @font-face, and to me it seems like not many people are using this. Its more or less supported in all browsers (well, not ie 6) so was wondering if there is a reason no one is using this that I'm over looking? If not it seems awesome, and I think it will make the designers here giddy with joy. I would like to set my site so that any text not given a specific class id for CSS will appear as a certain font. can I do this, and if so, how? thanks. Hello, I have something has follows: <div> ... <table> ... </table> </div> My document font size is 1em. My div font size is 1.4em. What should be the font-size in my table to get back to the 1em of the document? Thanks, Miguel |