Re: Commit: Localized normal.awt files

From: Dom Lachowicz (domlachowicz@yahoo.com)
Date: Mon May 26 2003 - 12:22:23 EDT

  • Next message: Marc Maurer: "Commit: Dialog cleanup"

    > > I'm wondering if we can ultimately just scrap the
    > > profiles in favour of normal.awt at some point?
    >
    > I am pretty sure you cant and that it doesn't make
    > sense. It might take
    > me a while but I am sure I can find a some screw
    > cases.

    Well, the only interesting one is SmartQuotes.

    We're not advocating removing user preferences at all,
    but rather removing the per-locale preferences -
    they're pretty hackish. No one's advocating storing
    zoom level, spell checking, toolbar, etc...
    preferences inside of a document. These are per-user
    metadata meant to customize how you wish to act on a
    document. The template files only alter the default
    content of a document. This generally includes:

    1) Right to left/Left to right dominant
    2) Default language(s)
    3) Default font(s)
    4) Various style definitions (#2 and #3 are achieved
    via this mechanism)
     
    > It would suck to have to ship a Normal.awt for every
    > locale.
    > Can Normal.awt be generated at runtime based on
    > current locale?

    Wel, we ship system.profiles for every locale. And as
    far as I can see, there's no way to sensibly generate
    one at runtime without having a huge map of
    information inside of abiword (basically what the
    system.profile files were) or somehow having a *lot*
    smarter OS services, which I don't think exist.
    Namely, we'd have to have at minimum:

    1) Way to get the preferred language
    2) Determine if it's LTR/RTL dominant
    3) Get the default paper size
    4) Get the preferred font for representing the
    language

    The lconv struct and other things in locale.h doesn't
    even come close to helping us along here.

    There are probably other screw cases. I think that
    it's hard for this to happen at runtime, and that the
    normal.awt attack is a fairly elegant one.
     
    Dom

    __________________________________
    Do you Yahoo!?
    The New Yahoo! Search - Faster. Easier. Bingo.
    http://search.yahoo.com



    This archive was generated by hypermail 2.1.4 : Mon May 26 2003 - 12:36:57 EDT