Re: Using Javascript to Detect Script Support in a Browser

From: Ed Trager (ed.trager@gmail.com)
Date: Mon Jun 21 2010 - 20:51:18 CDT

  • Next message: Andrew Cunningham: "Re: Using Javascript to Detect Script Support in a Browser"

    Thanks, Andrew! I like Keith's approach.

    I have been looking at Lanna a little bit and I am not sure if *any*
    OS shaper currently really has fully implemented correct shaping
    support for Lanna? In any event, Lanna is quite similar to Myanmar,
    so Keith's approach could be used very successfully.

    It might be interesting to see if Keith's approach can be generalized
    a bit to detect whether correct rendering is available for a number of
    those related S and SE Asian scripts: Myanmar, Lanna, Khmer, Kannada,
    etc.

    - Ed

    On Fri, Jun 18, 2010 at 3:16 AM, Andrew Cunningham
    <lang.support@gmail.com> wrote:
    > it is an issue that we've struggled with for a while
    >
    > eot, ttf font linking, woff and svg fonts all play a part in a
    > possible solution.
    >
    > for my projects i also have to consider if clients are likely to be
    > using older operating systems, and thus may not have rendering
    > support.
    >
    > SO detecting if appropriate fonts are available, doesn't
    >
    > Keith Stribley used a similar approach, see
    > http://www.thanlwinsoft.org/ThanLwinSoft/MyanmarUnicode/WebDevelopers/#detect
    >
    > For Myanmar he compared <U+1000 U+1000> to <U+1000 U+1039 U+1000>
    > which not only allowed him to see if an appropriate font was a
    > available, but whether appropriate rendering was occurring.
    >
    > On 17 June 2010 07:29, Ed Trager <ed.trager@gmail.com> wrote:
    >> On Tue, Jun 15, 2010 at 5:52 PM, Marc Durdin
    >
    >>> Couldn't you do this just using font fallback in CSS, and just leave it to the user agent to sort out?  Two examples:
    >>>
    >>>  P { font-family: Code2000, MyCode2000; }
    >>>  @font-face { font-family: MyCode2000; src: url('code2000.ttf'); }
    >>>
    >>> Or:
    >>>
    >>>  P { font-family: MyCode2000; }
    >>>  @font-face { font-family: MyCode2000; src: local("Code2000"), url('code2000.ttf'); }
    >>>
    >>
    >
    > for the browsers that can handle src local() syntax.
    >
    >> I cannot conclusively say at this point whether my planned "dynamic"
    >> solution is better than a more static "let the UA figure it out"
    >> approach, but I'm going to try it and see how it goes.
    >>
    >
    > both approaches have there benefits, really depends on what you are
    > trying to achieve. But i suspect that the static solution is more
    > scaleable.
    >
    >
    >
    >
    >
    > --
    > Andrew Cunningham
    > Senior Project Manager, Research and Development
    > Vicnet
    > State Library of Victoria
    > Australia
    >
    > andrewc@vicnet.net.au
    > lang.support@gmail.com
    >



    This archive was generated by hypermail 2.1.5 : Mon Jun 21 2010 - 20:53:40 CDT