Re: [NTG-context] Images centered on page : Solved

2007-11-24 Thread Wolfgang Schuster
On Fri, 23 Nov 2007 23:50:42 +0100
luigi scarso [EMAIL PROTECTED] wrote:

 On Nov 23, 2007 9:39 PM, Vyatcheslav Yatskovsky [EMAIL PROTECTED] wrote:
  Hello,
 
  Thank you all very much. I'm pleased with number and quality of solutions 
  to my problem.
 Did you look in supp-box at centerbox definition ?
 it' something like
 \vbox to \adimension{\vfill \vfill}
 (well, not \vfill, but \vss)
 
 You approach was not so distant to solutions , you only forget that
 \vfill need a bit of attention.
 (hey even today sometimes i'm lost with \def and \edef...)
 
 Compare
 \starttext
 \vfill
 a
 \vfill
 \stoptext
 
 with
 \starttext
 \hskip1sp
 \vfill
 a
 \vfill
 \stoptext
 
 Given that 1sp is invisible to human eye ,
 one can appreciate here a butterfly effect :))

Hi Luigi,

you can use \dontleavehmode in this case.

\starttext
\dontleavehmode\vfill
a
\vfill
\stoptext

Wolfgang
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Images centered on page : Solved

2007-11-24 Thread luigi scarso
 you can use \dontleavehmode in this case.
yes, i know.

\meaning\ \dontleavehmode
gives
\quitvmode

\meaning\quitvmode
gives
\quitvmode
hence \quitvmode is a primitive .

\quitvmode
The primitive instructs pdfTEX to quit the vertical mode and start
typesetting a paragraph. \quitvmode
has the same effect as \leavevmode definition from plain macro
package. Note however, that
\leavevmode may conflict with \everypar tokens list. No such risk
while using \quitvmode instead
The primitive has been introduced in pdfTEX 1.21a.

\hskip1sp give more the sense of invisible touch ...


-- 
luigi
...
it's new .
it's powerful .
it's luatex .
http://www.luatex.org
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Images centered on page : Solved

2007-11-23 Thread luigi scarso
On Nov 23, 2007 9:39 PM, Vyatcheslav Yatskovsky [EMAIL PROTECTED] wrote:
 Hello,

 Thank you all very much. I'm pleased with number and quality of solutions to 
 my problem.
Did you look in supp-box at centerbox definition ?
it' something like
\vbox to \adimension{\vfill \vfill}
(well, not \vfill, but \vss)

You approach was not so distant to solutions , you only forget that
\vfill need a bit of attention.
(hey even today sometimes i'm lost with \def and \edef...)

Compare
\starttext
\vfill
a
\vfill
\stoptext

with
\starttext
\hskip1sp
\vfill
a
\vfill
\stoptext

Given that 1sp is invisible to human eye ,
one can appreciate here a butterfly effect :))

-- 
luigi
...
it's new .
it's powerful .
it's luatex .
http://www.luatex.org
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] Images centered on page : Solved

2007-11-23 Thread Vyatcheslav Yatskovsky
Hello,

Thank you all very much. I'm pleased with number and quality of solutions to my 
problem.

The winner solution is provided by Wolfgang Schuster.  Simple \centeredbox{} 
makes all the magic I need.

I was also amazed with quick porting of my Lua code for batch image processing 
to native TeX script. I'm an imperative programmer to the marrow and never will 
be able to do such things. Luckily, now we have embedded Lua!

Best regards,
Vyatcheslav Yatskovsky


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___