\setupcolors[state=start]

\beginOLDTEX
\loadmapfile[qhv-ec.map]

\definefontsynonym  [BigNumberFont] [ec-qhvb] 
\endOLDTEX

\beginLUATEX
\definefontsynonym  [BigNumberFont] [name:texgyreherosbold]
\endLUATEX

\definefont         [NumberFont]    [BigNumberFont at 30pt]

\definetextext[taspresent:sometxt:left] {\TaspresentSometxtLeft}
\definetextext[taspresent:sometxt:right]{\TaspresentSometxtRight}

\unexpanded\def\TaspresentSometxtLeft#1%
  {\getvalue{taspresent:framed:small}
                       {\color[orange]
                       {\NumberFont #1}}}

\unexpanded\def\TaspresentSometxtRight#1%
  {\getvalue{taspresent:framed:small}
                       {\color[blue]
                       {\NumberFont #1}}}

\startuseMPgraphic{test}
StartPage ;
picture Left, Right ;

Left  := \sometxt[taspresent:sometxt:left] {\folio} ysized 6cm; 
Right := \sometxt[taspresent:sometxt:right]{\folio} ysized 6cm; 

clip Left  to boundingbox Left  xyscaled(0,3cm) ;

if PageNumber < 10:
	clip Right to boundingbox Right xyscaled(0,3cm) shifted (bbwidth(Right)/2,0) ;
	draw Left  shifted (14.26cm,-.5cm) ;
	draw Right shifted (14.26cm,-.5cm) ;
else :
	clip Right to boundingbox Right xyscaled(0,3cm) shifted (bbwidth(Right)/1.5,0) ;
	draw Left  shifted (12.59cm,-.5cm) ; 
	draw Right shifted (12.59cm,-.5cm) ;
fi;
StopPage ;
\stopuseMPgraphic

\defineoverlay[test][\useMPgraphic{test}]

\setupbackgrounds[page]
                 [background=test]

\starttext

\dorecurse{10}{
\chapter{test}
\input knuth}

\stoptext


