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

Re: [StrongED] Display of Tabs and Ctrls



In message <3a128fce52.martin@xxxxxxxxxxxxxxxx>
          Martin Bazley <martin.bazley@xxxxxxxxxxxxxxxx> wrote:

> The following bytes were arranged on 12 Sep 2012 by Fred Graute :
>
> > The mapping you propose for bitmap fonts differs from that for outline
> > fonts meaning syntax colouring needs to know which font type is in use.
> > Something I'd just managed to get rid off with the new, more universal
> > mapping.
>
> Ah, but that's the clever bit - it *doesn't*.  Everything I propose can
> be implemented by a few improvements to the user interface to the
> Choices file without the redraw engine being any the wiser.

No, It can't. For one, the mapping needs to know how wide a given Tab
is so that it can be mapped to the right characters. This isn't known
until the line is redrawn, hence the mapping must be done at redraw
time.

This is done at the third stage of building the list of redraw elements
by replacing the pointer to the actual Ctrl/Tab with a pointer to the
representation string to use.

The best you could hope to do is to decide on the representation table
at the redraw initialisation stage, as that needs to know which redraw
engine is in use anyway so as to do the initialisation correctly. This
way the code building the redraw list can be kept font type agnostic.

Changes to other parts than mode choices would also be required. With
CtrlTab no longer being a style we need to have extra code to read it
and convert it to internal format. Probably the same format as for the
bitmap styles otherwise the code to generate the colourtables required
for redrawing bitmap fonts would need altering as well.

It's also not clear how your scheme would work if bitmaps of sizes other
than 8*8/8*16 would become possible (I've already done work on this).

Cheers,
Fred.

-- 
StrongED developer
http://www.stronged.iconbar.com/

-- 
To unsubscribe send a mail to StrongED+unsubscribe@xxxxxxxxxxxxxx