texmacs-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Texmacs-dev] Braces


From: Nix N. Nix
Subject: Re: [Texmacs-dev] Braces
Date: 18 May 2003 02:00:43 -0600

On Sat, 2003-05-17 at 11:08, Joris van der Hoeven wrote:
> I finally managed to implement wide braces today.
> The implementation is very hacky; the font stuff really
> has to be reorganized too sometime; I will not further
> increase the complexity until this reorganization by the way.

Yeah, I agree.  One side effect of the whole font fixup will be to
finally have vector fonts in .ps files, right ?

I had a further look at the large delimiter code, and here's what I
found in src/Resource/Fonts/tex_rubber_font.cc:229:

    if (tfm->top (c)!=0) draw (dev, tfm->top (c), x, y, real_y);
    if (tfm->rep (c)!=0)
      for (i=0; i<nr_rep; i++)
        draw (dev, tfm->rep (c), x, y, real_y);
    if (tfm->mid (c)!=0) draw (dev, tfm->mid (c), x, y, real_y);
    if ((tfm->rep (c)!=0) && (tfm->mid (c)!=0))
      for (i=0; i<nr_rep; i++)
        draw (dev, tfm->rep (c), x, y, real_y);
    if (tfm->bot (c)!=0) draw (dev, tfm->bot (c), x, y, real_y);

This is basically

1. Draw top character (if there is one)
2. Draw extension character(s) (if there is one)
3. Draw middle character (if there is one)
4. Draw extension character(s) (if there is one)
5. Draw bottom character (if there is one)

isn't it ?

I assume this works for vertical braces because all the necessary
characters are inside the cmex font and bitmaps are properly generated,
whereas for horizontal braces, two fonts would have to be brought
together (cmex and txexa).

> 
> Anyway, the idea is to provide a new construction on
> bitmap characters: stretch a given column of the character
> horizontally by a certain amount of space. This allows me
> to produce wide braces, but also a variety of wide arrows.
> The same thing has been implemented for vertical stretching.

Very cool idea !  But, ummm, does this mean that you took out
cmex#122-125 ?  A few days ago I understood you saying that these
characters were now available to the point where I could produce them
using C-q.  Is that still the case ?

> 
> I also implemented braces as wide accents. They are available
> through the menus. Keyboard shortcuts, LaTeX conversions,
> translations, etc. have still to be implemented.

Yes, that's a good place for them.  LaTeX conversion should be no
problem.  As for keyboard shortcuts, well, I don't know ... A-{ and A-},
A-o and A-u, are taken :o)  Perhaps some H-<something> shortcuts.  We
don't use H- much, do we ?

Thanks, Joris ! I can't wait to see it !





reply via email to

[Prev in Thread] Current Thread [Next in Thread]