My personal, ugly way of doing this would be the following approach :

Render each glyph of the font (like, 'A'..'Z','a'..'z') into its own bitmap, and create your banners from that, either via a small CGI Perlscript (merlyn had a very interesting Apache page-not-found handler for creating nice rounded corners), or make a Perl script that combines these gif-glyphs on the fly into a large banner.

Some more elaboration on merlyns approach, as seen in one of his Web Techniques columns :

You create a directory, where your webserver can write files into, say, /banners. You set up a script as the "file-not-found" handler for that directory. All banner images are included as images like <IMG src="/banners/Text of banner.gif">, where "Text of banner" obviously means the text of the banner. Whenever such an image is not found, your script gets called as the error handler for that image. Your script then creates the file via the 10 seconds Perl/Ghostscript/GD program, returns it to the browser and also writes it to disk in the directory. This means, that after your first call, you get a cached version without having to worry about maintaining the correct banners in the directory.

If you're worried about the /banners/ directory getting too large, set up a reaper job that simply wipes out all files in that directory - this only means that your banner cache will be flushed and the first person(s) to request the banner will have to wait a little bit longer.


In reply to Re: Font Mafia by Corion
in thread Font Mafia by faure

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.