% Context-file
% filename: test-font-aguntia.tex

\mainlanguage[de]

\setuplanguage
  [de]
  [righthyphenchar=173]
	
\definefontfeature
	[maguntia]
	[mode=auto,script=latn,pnum=no,onum=no,lnum=yes]

\definefontfeature[onum][pnum=yes]
\definefontfeature[pnum][pnum=yes]
\definefontfeature[tnum][tnum=yes]
\definefontfeature[lnum][lnum=yes]

\starttypescript[calligraphy][maguntia]
	\definefontsynonym [maguntia][file:UnifrakturMaguntia][features=maguntia]
\stoptypescript

\starttypescript[maguntia]
	\definetypeface[\typescriptone][cg][calligraphy] [\typescriptone][default]
	\definetypeface[\typescriptone][ss][sans]        [heros]   [default]
	\definetypeface[\typescriptone][rm][serif]       [pagella] [default]
	\definetypeface[\typescriptone][mm][math]        [pagella] [default]
	\definetypeface[\typescriptone][tt][mono]        [cursor]  [default]
\stoptypescript

\setupbodyfont[maguntia,cg,10pt]

\subtractfeature[onum]
\subtractfeature[pnum]

\startbuffer[ruledhboxed]
\ruledhbox{1234567890}
\stopbuffer

\startbuffer[Sample]

	\subtractfeature[onum]
	\subtractfeature[pnum]
	\subtractfeature[lnum]
	\subtractfeature[tnum]
	
	\startsubject[title=\fontname\font]

	pnum=no,onum=no,lnum=no,tnum=no
	
	1234567890
	
	1+2=3
	
	\starttabulate[|lw(3.5cm)|p|]
	\NC 
		\rm pnum=yes,onum=yes 
	\NC
		\subtractfeature[lnum]
		\addfeature[pnum]
		\addfeature[onum]
		\getbuffer[ruledhboxed]
		\subtractfeature[onum]
	\NC\NR
	\NC 
		\rm pnum=yes,lnum=yes
	\NC
		\addfeature[lnum]
		\getbuffer[ruledhboxed]
		\subtractfeature[lnum]
		\subtractfeature[pnum]
	\NC\NR
	\NC
		\rm tnum=yes,onum=yes
	\NC
		\addfeature[tnum]
		\addfeature[onum]
		\getbuffer[ruledhboxed]
		\subtractfeature[onum]
	\NC\NR
	\NC
		\rm tnum=yes,lnum=yes
	\NC
		\addfeature[lnum]
		\getbuffer[ruledhboxed]
		\subtractfeature[lnum]
		\subtractfeature[tnum]
		\addfeature[pnum]
		\addfeature[onum]
	\NC\NR
	\stoptabulate
	
	1234567890
	\stopsubject
\stopbuffer

\starttext

	\getbuffer[Sample]

\stoptext