Hi,

At Tue, 01 May 2001 13:54:11 +0900,
Maxime Froment <[EMAIL PROTECTED]> wrote:

> - the font order is fixed, for instance, whatever the encoding:
>   (m)font1 < (m)font2 < (m)font3 < (m)font < (m)font4 < (m)font5 
>    < (m)font6 < (m)font7. In other words, font0_idx is a constant, 
>   and the default font is approximately in the middle of the font
>   list.

Good.  Then, src/defaultfont.h must be rewritten so that font1,
font2, and font3 will be smaller than font and font4...font7 will
be larger than font.

However, this will depend on fixed font0_idx, i.e., it should not
be changed even when compilation.  This also means that nfonts
should not be changed when compilation.  Though I think it is
no problem, how do you think?


> - the font order has nothing to do with actual font SIZE. It only
>   reflects the font cycling order (where the current font is changed 
>   by using Shift-KP_Add and Shift-KP_Substract). 

I see.  It is users who want to arrange fonts in size order
and Rxvt doesn't need to concern about this.


> - when changing fonts, if the next font is not defined or cannot
>   be loaded, it should be skipped, and the next one in the cycling
>   order should be considered, unless the extremity of the font list has
>   been reached. 
>     For instance, suppose that the current font is font4, and the
>     value of font6 is a loadable font, but not font5 nor font7. The
>     first time Shift-KP_Add is pressed, the font should be changed to
>     font6 (since font5 is not defined, or cannot be loaded), the next 
>     time it should stay to font6 (since font7 cannot be loaded, 
>     and there is no further font to consider).

This will be mandatory, because, for example in GB encoding,
only (m)font and (m)font4 will have valid font specification
and all others will have NULL in src/defaultfont.h .


> - obviously, the default font should always be correctly defined (failure
>   to load it could be treated as a special case)

This is true but I think this is not related to the current topic,
because the default font is always defined by (m)font.


> About the patch you submitted in your other message: the algorithm you
> use to determine the index of the default font will only yield a
> meaningful result when other font resource values (font1, font2,
> etc...) are already ordered in increasing font size order. Which seems
> to me like a rather strong assumption to begin with.
> For more correctness, you would actually want to sort all specified
> fonts. But this would become even "heavier" (quoting the end of your
> other message). My opinion is that the improvement (font cycling order
> and font size order are always identical) is not worth the extra 
> complexity. 

I see.  With your idea Rxvt can keep backward-compatibility and
my locale-sensibility extension, without "heavy" processing.

---
Tomohiro KUBOTA <[EMAIL PROTECTED]>
http://www.debian.or.jp/~kubota/
"Introduction to I18N"  http://www.debian.org/doc/manuals/intro-i18n/

Reply via email to