At 22.20 +0200 01-04-08, Frank Mittelbach wrote:
> > I just noticed that the std template of type justification in the xhj
> > package globally sets the paragraph justification; at least its settings
> > aren't contained in an environment. How should one then go about with
> > implementing an environment that simply changes the justification for the
> > paragraphs inside it? To me this seems like a task which should be simple;
> > it shouldn't require using the galley2 interfaces.
>what's wrong with the idea of using something like the galley inferface
>throughout (beside the fact that it isn't good enough yet (even as a prototype
You mean in addition to the fact that the xhj package abstract claims you
shouldn't use galley2 directly in more than 2% of the cases?
>but i think that if you want extended control like offered by the galley
>interface you can't simply turn it on and off but have to stay within its
That's not at all what I was doing. I simply had expected that changes to
justification would be contained by the normal grouping mechanism (because
they are in 2e) and the fact that they aren't suggests that there are
things missing from the basic interfaces. For my present needs I can just
switch to using instances of the `single' template instead since the
justification was changed for each new paragraph anyhow. I suspect however
that having changes of the justification (or whatever) apply for the
duration of an environment will be a rather frequent request and one
shouldn't have to go to the "special needs" interface to achieve it. It
could be that you have to start a new galley level for the environment, but
then that should probably be given as an example somewhere.
>but perhaps you are right and the whole thing needs further thought.
>throughout last week i worked on a frontmatter template interface for handling
>complex author/address relations etc. and for that I also needed to interface
>to paragraph justification. Since the galley interface isn't yet good to be
>usable in arbitrary circumstances I ended up implementnig a very primitive
>version of the xhj templates that can work on their own (just to get that
>frontmatter stuff working)
It is a bit annoying that the galley stuff makes all old code so completely
ineffective. Would it be possible to create some templates which (at each
\par and in \everypar, I suspect) simply have the mechanisms look in the
registers which take the names of the primitive parameters and uses the
values found there? It would (hopefully) enable old code to work in the
extent that it isn't overridden by settings using the LaTeX2e* interfaces.
>as side issue: is the xhj template at the right level of detail anyhow?
Dunno, the only one I've used so far is justification. I'm probably going
to try out linebreak for an example, though (and for that example one wants
them to be independent).