ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Peter Davis <pfd@pfdstudio.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Placing boxes anywhere on the page
Date: Tue, 16 Nov 2010 15:32:40 -0500	[thread overview]
Message-ID: <AANLkTikRVjoZrapQa793ZsdJ9d-V9t=iyVCuNYMMf6GT@mail.gmail.com> (raw)
In-Reply-To: <8B3095C1-246E-46D0-B427-34BC5507423F@gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 5179 bytes --]

On Tue, Nov 16, 2010 at 3:22 PM, Wolfgang Schuster <
schuster.wolfgang@googlemail.com> wrote:

>
> Am 16.11.2010 um 21:06 schrieb Peter Davis:
>
> > Is there a way to place a box at some specified x and y position on the
> page, and then typeset one or more paragraphs of text into the box?  I guess
> I'm thinking of something like LaTeX's minipage, but with the ability to
> specify absolute coordinates, rather than just position relative to the
> current baseline.
>
> Use layers (untested):
>
> \definelayer[textbox][width=\paperwidth,height=\paperheight]
>
> \setupbackgrounds[page][background=textbox]
>
> \def\starttextbox
>  {\dosingleargument\dostarttextbox}
>
> \def\dostarttextbox[#1]%
>  {\def\stoptextbox{\setlayerframed[textbox][#1]{\getbuffer[textbox]}}%
>   \startbuffer[textbox][starttextbox][stoptextbox]}
>
> \starttext
>
> \starttextbox[x=2cm,y=4cm,width=8cm,frame=off]
> some text ...
>
> more text ...
> \stoptextbox
>
> \starttextbox[x=6cm,y=12cm,width=8cm,frame=off]
> another example ...
> \stoptextbox
>
> \stoptext
>
> Wolfgang
>


Thanks, Worfgang!  I just tried this.  I don't see any errors, but I don't
see any PDF either.  Here's the log file:


sorters         > setting language 'en'

(layertest.tex
jobcontrol      > resuming randomizer with 0.72399060029908
publications    : loading formatting style from bxml-apa
(C:/context/tex/texmf-context/tex/context/base/bxml-apa.mkiv)

ConTeXt  ver: 2010.07.30 11:35 MKIV  fmt: 2010.11.9  int: english/english

system          : cont-new loaded
(C:/context/tex/texmf-context/tex/context/base/cont-new.tex
systems         : beware: some patches loaded from cont-new.tex
(C:/context/tex/texmf-context/tex/context/base/cont-new.mkiv))
system          : cont-fil loaded
(C:/context/tex/texmf-context/tex/context/base/cont-fil.tex
loading         : ConTeXt File Synonyms
)
system          : cont-sys.rme loaded
(C:/context/tex/texmf-context/tex/context/user/cont-sys.rme
(C:/context/tex/texmf-context/tex/context/base/type-def.mkiv)
(C:/context/tex/texmf-context/tex/context/base/type-lua.mkiv)
(C:/context/tex/texmf-context/tex/context/base/type-siz.mkiv)
(C:/context/tex/texmf-context/tex/context/base/type-otf.mkiv))
system          : layertest.top loaded
%
% begin of optionfile
%
% % runtime options files (command line driven)
% \unprotect
% % feedback and basic job control
% % handy for special styles
% \startluacode
% document = document or { }
% document.arguments={
% }
% document.files={
% "layertest.tex",
% }
% \stopluacode
% % process info
% \setupsystem[inputfile=layertest.tex]
% \setupsystem[\c!n=1,\c!m=1]
% % modes
% % options (not that important)
% \startsetups *runtime:options
% \setupoutput[pdftex]
% \stopsetups
% % styles and modules
% \startsetups *runtime:modules
% \stopsetups
% % done
% \protect \endinput
%
% end of optionfile
%
(layertest.top)
fonts           : preloading latin modern fonts
{C:/context/tex/texmf/fonts/map/dvips/lm/lm-math.map}{C:/context/tex/texmf/fonts/map/dvips/lm/lm-rm.map}{C:/context/tex/texmf-context/fonts/map/pdftex/context/mkiv-base.map}
bodyfont        : 12pt rm is loaded
language        : language en is active
systems         : begin file layertest.tex at line 12
systems         : end file layertest.tex at line 24
system          : cont-err loaded
(C:/context/tex/texmf-context/tex/context/base/cont-err.tex
systems         : no file 'cont-sys.tex', using 'cont-sys.rme' instead
) )
mkiv lua stats : used config file          -
C:/context/tex/texmf/web2c/texmfcnf.lua
mkiv lua stats : used cache path           -
C:/context/tex/texmf-cache/luatex-cache/context/f53042fa2e1c106bc7e3383ec8c3a00c
mkiv lua stats : input load time           - 0.026 seconds
mkiv lua stats : stored bytecode data      - 231 modules, 54 tables, 285
chunks
mkiv lua stats : node list callback tasks  - 6 unique task lists, 4
instances (re)created, 316 calls
mkiv lua stats : cleaned up reserved nodes - 33 nodes, 10 lists of 411
mkiv lua stats : node memory usage         - 20 glue_spec
mkiv lua stats : used backend              - pdf (backend for directly
generating pdf output)
mkiv lua stats : loaded patterns           - en::2
mkiv lua stats : callbacks                 - direct: 425, indirect: 4447,
total: 4872
mkiv lua stats : result saved in file      - layertest.pdf
mkiv lua stats : loaded fonts              - 33 files: stmary10.afm
lmmono12-regular.otf lmmono8-regular.otf lmmono9-regular.otf
lmroman12-bold.otf lmroman12-regular.otf lmroman7-bold.otf
lmroman7-regular.otf lmroman9-bold.otf lmroman9-regular.otf
lmsans12-regular.otf lmsans8-regular.otf lmsans9-regular.otf eufb10.tfm
eufb7.tfm eufm10.tfm eufm7.tfm msam10.tfm msam7.tfm msbm10.tfm msbm7.tfm
lmex10.tfm lmmi12.tfm lmmi7.tfm lmmi9.tfm lmmib10.tfm lmmib7.tfm lmsy10.tfm
lmsy7.tfm lmsy9.tfm rm-lmr12.tfm rm-lmr7.tfm rm-lmr9.tfm
mkiv lua stats : fonts load time           - 0.262 seconds
mkiv lua stats : luatex banner             - this is luatex, version
beta-0.63.0-2010090921 (web2c 2010) (rev 3873)
mkiv lua stats : control sequences         - 30982 of 165536
mkiv lua stats : current memory usage      - 33 MB (ctx: 34 MB)
mkiv lua stats : runtime                   - 0.679 seconds

[-- Attachment #1.2: Type: text/html, Size: 8168 bytes --]

[-- Attachment #2: Type: text/plain, Size: 486 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

  reply	other threads:[~2010-11-16 20:32 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-16 20:06 Peter Davis
2010-11-16 20:22 ` Wolfgang Schuster
2010-11-16 20:32   ` Peter Davis [this message]
2010-11-16 20:48     ` Wolfgang Schuster
2010-11-16 21:12       ` Peter Davis
2010-11-16 21:26         ` Wolfgang Schuster
2010-11-16 21:32           ` Peter Davis
2010-11-16 20:41 ` Peter Münster
2010-11-16 21:16   ` Peter Davis
2010-11-17  0:08     ` Peter Münster
2010-11-17  0:07   ` Hans Hagen
2010-11-17  0:59     ` Martin Schröder
2010-11-17  8:25       ` Hans Hagen
2010-11-17  9:21         ` Alan BRASLAU
2010-11-17  9:48           ` Hans Hagen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='AANLkTikRVjoZrapQa793ZsdJ9d-V9t=iyVCuNYMMf6GT@mail.gmail.com' \
    --to=pfd@pfdstudio.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).