I am having some issues with Firefox not rendering an element with the
correct font. I am using the font-family style within a stylesheet class
definition. I then set the element I am creating to use that class and the
font is not showing correctly. If I set the font-family to "arial" or
"Comic Sans MS" the font shows correctly, however I am trying to use the
"Webdings" font, which is installed on my computer. All fonts show
correctly using IE6. Any ideas?
..cartSlct
{
font-family:webdings;
font-size:12pt;
cursor:default;
width:5%;
}
cellSlct=newRow.insertCell(-1)
cellSlct.appendChild(winDVDCart.document.createTex tNode("4"))
The text should display as an arrow pointing to the right 12 18251
David wrote: I am having some issues with Firefox not rendering an element with the correct font. I am using the font-family style within a stylesheet class definition. I then set the element I am creating to use that class and the font is not showing correctly. If I set the font-family to "arial" or "Comic Sans MS" the font shows correctly, however I am trying to use the "Webdings" font, which is installed on my computer. All fonts show correctly using IE6. Any ideas?
.cartSlct { font-family:webdings; font-size:12pt; cursor:default; width:5%; }
cellSlct=newRow.insertCell(-1) cellSlct.appendChild(winDVDCart.document.createTex tNode("4"))
The text should display as an arrow pointing to the right
If you want a right arrow, use the proper HTML character entity, i.e.
'→' or '→'.
C A Upsdell wrote: If you want a right arrow, use the proper HTML character entity, i.e. '→' or '→'.
Well, the right arrow that I would LIKE to use is actually the HTML
character entity '⇒' or '⇒' but now IE has decided it doesn't
like that one and only displays a box. In addition, how would I put an HTML
character entity reference into my createTextNode statement, it doesn't seem
to interpret anything as anything more than text.
cellSlct.appendChild(winDVDCart.document.createTex tNode("⇒"))
How should this look? (sorry if this question should actually be posted
somewhere else, but since I started the topic here....)
David wrote: C A Upsdell wrote:
If you want a right arrow, use the proper HTML character entity, i.e. '→' or '→'.
Well, the right arrow that I would LIKE to use is actually the HTML character entity '⇒' or '⇒' but now IE has decided it doesn't like that one and only displays a box. In addition, how would I put an HTML character entity reference into my createTextNode statement, it doesn't seem to interpret anything as anything more than text.
cellSlct.appendChild(winDVDCart.document.createTex tNode("⇒"))
How should this look? (sorry if this question should actually be posted somewhere else, but since I started the topic here....)
The character entity IS text.
C A Upsdell wrote: David wrote: C A Upsdell wrote:
If you want a right arrow, use the proper HTML character entity, i.e. '→' or '→'.
Well, the right arrow that I would LIKE to use is actually the HTML character entity '⇒' or '⇒' but now IE has decided it doesn't like that one and only displays a box. In addition, how would I put an HTML character entity reference into my createTextNode statement, it doesn't seem to interpret anything as anything more than text.
cellSlct.appendChild(winDVDCart.document.createTex tNode("⇒"))
How should this look? (sorry if this question should actually be posted somewhere else, but since I started the topic here....)
The character entity IS text.
Ok, so since the character entity IS text, then that should mean that I
wouldn't need the quotes around it? When I leave it without the quotes I
start getting script errors in other places in my document, obviously a
result of taking it out of quotes. How should I go about creating a text
node with that value in it? Also, any ideas why IE6 won't display the
⇒ character but has no problems displaying the other one, → ??
Sorry for my ignorance on this topic, it is all kind of new to me.
On Tue, 19 Jul 2005, David wrote: Ok, so since the character entity IS text, then that should mean that I wouldn't need the quotes around it?
You're one step further away from what we usually discuss here, namely
some static HTML (or xhtml) with a stylesheet to propose presentation.
You're evidently generating something programmatically. How you do
that is your concern, I'm starting from the result of that program...
The important part, for the current discussion, is the HTML (it
defines the /content/), which makes it really off-topic for this
group, but I'm tackling the question where I found it, for now.
There are (potentially) three ways to represent a character: the coded
character itself, its numeric character reference &#number; (decimal
or hex), or, where available, a character entity &whatever;
If you decide which you prefer, and inject that with whatever software
it is that you're using, then the problem is solved, theoretically.
Also, any ideas why IE6 won't display the ⇒ character but has no problems displaying the other one, → ??
Possibly a font limitation. The single arrows are in MS WGL4, so
they'd likely be in any current MS font that offers a wide repertoire
of basically Western characters. The double arrow is not, however.
But it seems to work for me if I choose Lucida Sans Unicode as IE's
default font.
hope this helps a bit
Remark: In general in a web context you have no idea which fonts your
readers may have available. Even if you guess, there are different
versions of the same-named font that have different (sometimes very
different) repertoires. So you do better, in a situation where
unusual characters are needed, /not/ to try to influence their font
choice from a stylesheet.
"David" <dk****@hotmail.com> wrote: cellSlct.appendChild(winDVDCart.document.createTex tNode("⇒"))
Script elements contain character data, not parsed character data
(which may contain entites which will be parsed by the browser).
So you have to use Unicode to denote the character, "\u21D2" in this
case.
Make a post to comp.lang.javascript, if you want to follow-up on this
subject.
Bye,
Martin
On Tue, 19 Jul 2005, Alan J. Flavell wrote: There are (potentially) three ways to represent a character: the coded character itself, its numeric character reference &#number; (decimal or hex), or, where available, a character entity &whatever;
I gather from other followups since, that the second and third options
aren't available to you in your particular context. Apologies if I caused
any confusion.
Alan J. Flavell wrote: On Tue, 19 Jul 2005, Alan J. Flavell wrote:
There are (potentially) three ways to represent a character: the coded character itself, its numeric character reference &#number; (decimal or hex), or, where available, a character entity &whatever;
I gather from other followups since, that the second and third options aren't available to you in your particular context. Apologies if I caused any confusion.
No problem, I was able to use the Unicode character code "\u21D2" to get the
character I was looking for, though I am disappointed that the character for
⇒ will not show up on IE6 under any font I try. Anyways, thanks to
all.
On Mon, 18 Jul 2005 15:22:35 -0700, "David" <dk****@hotmail.com> wrote
or quoted : All fonts show correctly using IE6. Any ideas?
Try http://mindprod.com/applets/fontshower.html
to see what fonts are installed on your machine and precisely what
they are called.
Whether it officially matters or not, it is a good idea to get the
case right and exactly where the spaces go.
You are not supposed to put quotes around the generic font names like
sans-serif
--
Bush crime family lost/embezzled $3 trillion from Pentagon.
Complicit Bush-friendly media keeps mum. Rumsfeld confesses on video. http://www.infowars.com/articles/us/...s_rumsfeld.htm
Canadian Mind Products, Roedy Green.
See http://mindprod.com/iraq.html photos of Bush's war crimes
On Wed, 20 Jul 2005, David wrote: No problem, I was able to use the Unicode character code "\u21D2" to get the character I was looking for, though I am disappointed that the character for ⇒ will not show up on IE6 under any font I try.
IE is very strange in some regards. I don't understand the internals,
but I've set out some of my observations, amongst other browsers, at http://ppewww.ph.gla.ac.uk/~flavell/...ers-fonts.html
However, I'm definite that "Lucida Sans Unicode" contains this
character (I've browsed the font with SIL Viewglyph to be sure).
Arial (the regular font, not the big unicode one) doesn't have the
double arrow, on the other hand.
What struck me as completely bizarre was that when, by chance, I
enabled Japanese language support, IE started to display a whole lot
of extra characters of this kind - even ones which weren't present in
the selected font. Sure: once that has been done, it's hard to
disentangle what's really happening. But I think the SIL Viewglyph
font browser is telling the truth as regards which characters are
really in each font.
I admit that telling your readers that they'd get better display of
these characters by installing Japanese support is quite likely to
"get some funny looks", but it seems to be the case, even so. (Tried
with Win/2K Pro and XP Pro).
cheers This discussion thread is closed Replies have been disabled for this discussion. Similar topics
1 post
views
Thread by yoni cohen |
last post: by
|
5 posts
views
Thread by news |
last post: by
|
6 posts
views
Thread by mike |
last post: by
|
12 posts
views
Thread by news |
last post: by
|
35 posts
views
Thread by Aaron Gray |
last post: by
| |
7 posts
views
Thread by Xah Lee |
last post: by
|
3 posts
views
Thread by Tyrone Slothrop |
last post: by
|
reply
views
Thread by atarumorooka |
last post: by
| | | | | | | | | | | |