No replies
jsabarese's picture
Positively 4th Street
Last seen: 10 years 32 weeks ago
Positively 4th Street
Timezone: GMT-4
Joined: 2005-02-05
Posts: 404
Points: 7

What up, y'all homeys, home-slice, chicas, and whomever else be got their ears on:

SVG Content:
0.) The site validates, just fine-- albeit, perhaps the W3C Validator is immune to the artifact at hand.
1.) I realize this is a CSS-specific forum
2.) Amongst the community, , I've found a great resource of knowledge; knowledgeable individuals who offer constructive, generally useful feedback-- hence my approach, rather than go about looking for some-kinda-new-family-o-genius.
3.) The topic is specifically concerned with SVG in HTML, so I do not expect the reader; respondent to concern himself / herself with it. Yet, I maintain a certain confidence; level of expectation of the community leaders if a viable challenge might arise, as aforementioned. Nevertheless, I do not expect you to be eager to engage this topic. (i.e. it's all good, dude / bro'a / bro-ham!)

...blah, blah: that said, here's the deal-e-oh:

I've got the most basic /version/ , if you will, of the application-- specific to satisfy the curious-- installed at this location:

For anyone more interested in the details, or whom may wish to SVN /checkout/ or /export/ the app for more microscopic investigation, I recommend you have a look at:

The application is designed to browse static HTML-- as known to be found, for example, as extracted might exist in HTML documentation-- common to archived media, such as "php_manual_en", where ./php_manual_en/html/* contains a whole !^%$-load of HTML files. Those of us who are wont to (de)compile CHM documents might also be accustomed to an overwhelming list of static documents.

Using PHP, I've successfully created a method by which, depending upon the location of the application Container on the system-path; of the server location, the SVG-- being of bad-ass dynamic capability-- in this simple, proof-of-concept, does write a heading "image", dynamically, as stated-- based upon the container name.

I have the @font-face set to declare a particular family, for what text is drawn in the #header div. Thing is-- it doesn't work. For me-- being all ADD'd-out n that garbage-- I have quite the difficulty in deciding where to begin to solve this problem.

Basically, (i think) it's writing-- or trying to write-- the @font-face, dynamically... err... via PHP... maybe hard-coded-- sorry, that's not the focus, really. The problem is, I think the CSS is /getting there/ but the browser won't change the font-- IF the font is NOT installed on the system. Unlike other circumstance, where the @font-face directive (i believe) is capable of rendering for a visiting user who hasn't the font installed-- temporarily allowing the browser to render such a font-family-- for that browser visit, err... whatever... you know the story of @font-face, i'm sure, and the controversy o'r whether it be good / be bad idea... methinks... i dunno...

anyway-- so the SVG goes in there as an HTML <object /> , and i think-- since the file is referenced as a "src" attribute of the object-- somewhere along the lines, that CSS @font-face bit is being ignored-- IF the system has not the font to render it already.

Specifically, I've got it set to be some Gill Sans this or that, and I've purposefully removed the specific family from an XP system, and the Linux systems don't have it by default, and these are the cases wherein the SVG is displayed in boring old serif, default font-family-- so it seems, in my comprehension.

Is this the /wrong/ way to go about using SVG?
How might i continue to use PHP to render dynamic text to SVG, and yet overcome this apparent issue w/ @font-face?

Do I have something wrong here, regarding my understanding of the use of @font-face?
What else might I study; do you recommend I read, that I might better solve this problem through a more extensive knowledge of the way the browser is rendering the document? (i.e. as far as I can tell, Opera, Webkit, FF, Tcl/TkHtml, etc., all perform similarly, in NOT rendering the desired font-face)

sincerely, your friendly neighborhood ex-old lady