ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* numbered programlistings
@ 2002-06-12 17:45 Kris Hermans
  2002-06-12 20:00 ` Berend de Boer
  2002-06-13  7:29 ` Hans Hagen
  0 siblings, 2 replies; 3+ messages in thread
From: Kris Hermans @ 2002-06-12 17:45 UTC (permalink / raw)


Hi again!

I'm writing a programming tutorial with ConTeXt. Therefore I have
programlistings that I want to reference in my text. My idea is to labels
together with verbatim text.

For instance:

\definelabel[programlisting][text=listing,
                             location=inmargin,
                             headstyle=small]

And in my text I write:

\listing\starttyping
/* first.c : my first C program */
#include <stdio.h>

int main()
{
  puts("Hello Everybody!");
  return 0;
}
\stoptyping

This all works fine, but I expected the label ("listing 1.1") to appear in
the margin AT THE SAME LINE as the first line of my programlisting (/*
first.c ... */). However, the label is somewhat above the actual verbatim
text.

Any tips on how to solve this are welcome!

thanks in advance,

Kris Hermans


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2002-06-13  7:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-06-12 17:45 numbered programlistings Kris Hermans
2002-06-12 20:00 ` Berend de Boer
2002-06-13  7:29 ` Hans Hagen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).