nanogui: FLNX 0.12 - fonts problems


Previous by date: 20 Oct 2000 20:01:33 -0000 Re: custom calls to driver, Alex Holden
Next by date: 20 Oct 2000 20:01:33 -0000 Re: win32 help, Greg's email
Previous in thread: 20 Oct 2000 20:01:33 -0000 Re: FLNX 0.12 - fonts problems, Jeff Moellmer
Next in thread: 20 Oct 2000 20:01:33 -0000 Re: FLNX 0.12 - fonts problems, Greg Haerr

Subject: Re: FLNX 0.12 - fonts problems
From: "Greg's email" ####@####.####
Date: 20 Oct 2000 20:01:33 -0000
Message-Id: <01fb01c03ad0$f8a5d500$8900a8c0@applieddata>

Jeff,
    Let's plan on meeting early next week to finally put
to bed all the FLNX/Microwindows font issues.  You or Scott
can hack FLNX, and I'll hack Microwindows, and we need
to make sure that T1, TrueType, and GB2312 chinese fonts
all work with FLNX.  Then let's go after the interal (I suggest
UTF-8) encoding format.  You and Scott might want to look
at all this to get prepared to hack it into submission.

In particular, the following needs to happen:

FLNX:
1. Font names are consistent, no chinese recompile should be
required.  That is, only Microwindows is recompiled, not FLNX
or ViewML.  There needs to be a way to specify that a chinese
font is wanted, rather than say Western truetype.

2. Known font names will be used, and font name aliasing will
be added to Microwindows.

3. Internal text encoding UTF-8 standard will be used. (or
at least mult-byte, rather than UC16 wide characters)

Nano-X:
1. Add font aliasing, and font directory configuration files,
readable at run-time.

2. Possibly add run-time selection of chinese vs truetype,
rather than having to recompile.  This might allow GB2312
chinese fonts to be image-loaded, rather than bound-in.

3. Allow GB2312 and UTF-8 encodings to run simultaneosly,
with the addition of another MWTF_GB2312 type.

4. Get approval for all chinese fonts used in Microwindows, as
part of the standard distribution.

ViewML: (post 0.2)
1. Run ViewML using UTF-8/GB2312 internally.  Allow
HTML conversion to this format and display of any HTML
page in Western as well as Chinese.

Regards,

Greg

> 1. microwin/src/confg:
>     A. Turn on HZK font support:
>
>             HAVE_HZK_SUPPORT         = "Y";
>
>     B. Tell microwindows *exactly* where it is exactly (not a relative
path):
>
>             HZK_FONT_DIR                     =
> "/home/jeffm/microwin/src/fonts/chinese"
>
> 2. flnx/src/fl_font.cxx:
>
>     A. Only use HZFONT in the fonts section:
>
> static Fl_Fontdesc built_in_table[] = {
>   {"HZKFONT"}
> /*
> {"/usr/X11R6/lib/X11/fonts/webfonts/arial.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/arialb.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/ariali.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/arialz.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/cour.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/courb.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/couri.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/courz.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/times.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/timesb.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/timesi.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/timesz.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"},
> {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"}
> */
> };
>
> 3. Recompile both mircowindows and FLNX.
>
> Afterwards, when you run a flnx applications you should see something like
this:
>
> this is in nano-X
> Nano-X don't support get_mouse(x,y)in file(Fl_X.cxx)
> hzk_createfont(HZKFONT,16)
> Loading Chinese HZK font from
> file(/home/jeffm/microwin/src/fonts/chinese/hzk16)...done.
> Loading ASCII HZK font...done.
>
> Try this out, however, there seems to be problems with displaying the
fonts in some
> FLNX. For example, even though the fonts load, the fonts test demo program
seg
> faults every time!
>
> I'll have to talk with Greg and get some more details, but we'll get it
working.
> Chinese font support is very important.
>
> Thanks,
>
> Jeff
>
> ####@####.#### wrote:
>
> > Hi Jeff,
> >
> > How to configure flnx to support different fonts, like generic, T1, TTF,
> > HZKFONT, etc?
> >
> > I'd like to use fltk running on nano-x on Assabet board. Now, I
successfully
> > port Microwindows 0.89pre3 on my platform.
> > I can display different font type/size including T1LIB, Free Type,
HZKFONT
> > Chinese characters, etc. under Microwinodws.
> >
> > However, I cannot change the font type or font size on my application
written by
> > flnx and even cannot run the demo program - fonts under subdirectory
flnx/test/
> > .
> >
> > The demo program - fonts cannot work even I try several combination.
> >
> > (1) I copy all *.ttf file to /usr/X11R6/lib/X11/fonts/webfonts/  and run
> > I got the following error (but I am sure the files are existed in the
correct
> > directory)
> >
> > hifi:~/microwindows/flnx/test # /fonts
> >
> > t1lib_createfont: /usr/X11R6/lib/X11/fonts/webfonts/arial.ttf,16 not
found
> > t1lib_createfont: /usr/X11R6/lib/X11/fonts/webfonts/timesb.ttf,16 not
found
> >
> > (2) use generic fonts
> > I definitely use the second part of font table by using XX_NANO_X macro
to
> > unselect the first part  in file fl_font.cxx (as shown below)
> >
> > ////////////////////////////////////////////////////////////////
> > #ifdef XX_NANO_X
> > // WARNING: if you add to this table, you must redefine FL_FREE_FONT
> > // in Enumerations.H & recompile!!
> > static Fl_Fontdesc built_in_table[] = {
> > {"/usr/X11R6/lib/X11/fonts/webfonts/arial.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/arialb.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/ariali.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/arialz.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/cour.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/courb.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/couri.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/courz.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/times.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/timesb.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/timesi.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/timesz.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"},
> > {"/usr/X11R6/lib/X11/fonts/webfonts/impact.ttf"},
> > /*{"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"},
> > {"HZKFONT"}
> > */
> > };
> >
> > #else
> > // WARNING: if you add to this table, you must redefine FL_FREE_FONT
> > // in Enumerations.H & recompile!!
> > static Fl_Fontdesc built_in_table[] = {
> > {"-*-helvetica-medium-r-normal--*"},
> > {"-*-helvetica-bold-r-normal--*"},
> > {"-*-helvetica-medium-o-normal--*"},
> > {"-*-helvetica-bold-o-normal--*"},
> > {"-*-courier-medium-r-normal--*"},
> > {"-*-courier-bold-r-normal--*"},
> > {"-*-courier-medium-o-normal--*"},
> > {"-*-courier-bold-o-normal--*"},
> > {"-*-times-medium-r-normal--*"},
> > {"-*-times-bold-r-normal--*"},
> > {"-*-times-medium-i-normal--*"},
> > {"-*-times-bold-i-normal--*"},
> > {"-*-symbol-*"},
> > {"-*-lucidatypewriter-medium-r-normal-sans-*"},
> > {"-*-lucidatypewriter-bold-r-normal-sans-*"},
> > {"-*-*zapf dingbats-*"}
> > };
> > #endif
> >
> > Unluckily, I got the following error.
> >
> > hifi:~/microwindows/flnx/test # ./fonts
> > t1lib_createfont:
> > -*-helvetica-medium-r-normal--*,16 not foundt1lib_createfont:
> > -*-times-bold-r-normal--*,16 not found
> >
> > Actually, I have no files something
ike  -*-helvetica-medium-r-normal--* . Is
> > it a build-in fonts? Else, where can I get the fonts file?
> >
> > (3) using T1LIB
> > I copy the FoneDataBase file to the flnx/test and modify the path
accordingly
> > (FREETYPE_FONT_DIR=/usr/local/microwin/fonts)
> >
> > No run time errors.
> >
> > Unluckily, I also cannot change the font type or size as I wish.
> >
> > The questions is that what am I doing wrong?
> > Is there any environment variables I have to define? In fact, I do
change the
> > font type or size in Mircowindows.
> >
> > By the way, where can I get more fonts?
> >
> > Your help is highly appreciated.
> > Thank you in advance.
> >
> > Hifi Wong.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ####@####.####
> For additional commands, e-mail: ####@####.####
>
>


Previous by date: 20 Oct 2000 20:01:33 -0000 Re: custom calls to driver, Alex Holden
Next by date: 20 Oct 2000 20:01:33 -0000 Re: win32 help, Greg's email
Previous in thread: 20 Oct 2000 20:01:33 -0000 Re: FLNX 0.12 - fonts problems, Jeff Moellmer
Next in thread: 20 Oct 2000 20:01:33 -0000 Re: FLNX 0.12 - fonts problems, Greg Haerr


Powered by ezmlm-browse 0.20.