OK.  Thanx very much - for me it is a useful thing...
Jaroslav Hajtmar


Dne 12.1.2014 17:08, Otared Kavian napsal(a):

Hi Jaroslav,

Actually the formatting of what you put in the block determined for example by
is independent of the block mechanism: you can use whatever structure you want.
In the example we exchanged on, an enumeration such as
where this \start \stop has been defined by \defineenumeration[answer], but you

Best regards: OK

On 12 janv. 2014, at 11:45, Jaroslav Hajtmar <hajt...@gyza.cz> wrote:


Hello Otared and Wolfgang.

Thanks for launching this example.
Is there a possibility to write the answers into a more compact form (more
columns, one paragraph, etc) like in any textbooks? I tried experimenting, but
I was unable to put answers into a compact form.
Thanks Jaroslav Hajtmar

Here is my modification of answer enumeration (not working):

\defineblock[question]
\defineblock[hint]

\defineenumeration[question]
[alternative=hanging,
width=2.5cm,
text={Question},
stopper={.}]

\defineenumeration[hint]
[alternative=hanging,
width=4cm,
text={Hint for question},
stopper={.}]

[alternative=hanging,
before={\startcolumns[n=4]},
after=\stopcolumns,
width=0.5em,
text={},
stopper={.}]

\setupblock[question][before={\startquestion},after={\stopquestion}]
\setupblock[hint][before={\starthint},after={\stophint}]

\keepblocks[question]
\hideblocks[hint]

\starttext

\section{Questions}

\beginquestion
Compute $4\times 5$.
\endquestion

\beginhint
Use the fact that $2\times 5 = 10$.
\endhint

$20$.

\beginquestion
What is the value of $100 / 10$?
\endquestion

\beginhint
Remember that $10\times 10 = 100$.
\endhint

$10$

\beginquestion
Compute $4\times 5$.
\endquestion

\beginhint
Use the fact that $2\times 5 = 10$.
\endhint

$20$.

\beginquestion
What is the value of $100 / 10$?
\endquestion

\beginhint
Remember that $10\times 10 = 100$.
\endhint

$10$

\beginquestion
Compute $4\times 5$.
\endquestion

\beginhint
Use the fact that $2\times 5 = 10$.
\endhint

$20$.

\beginquestion
What is the value of $100 / 10$?
\endquestion

\beginhint
Remember that $10\times 10 = 100$.
\endhint

$10$
\beginquestion
Compute $4\times 5$.
\endquestion

\beginhint
Use the fact that $2\times 5 = 10$.
\endhint

$20$.

\beginquestion
What is the value of $100 / 10$?
\endquestion

\beginhint
Remember that $10\times 10 = 100$.
\endhint

$10$

\section{Hints to all questions}

\useblocks[hint]

\stoptext

Dne 11.1.2014 20:01, Otared Kavian napsal(a):

%%%% begin question-hint-answer-blocks.tex
\defineblock[question]
\defineblock[hint]

\defineenumeration[question]
[alternative=hanging,
width=2.5cm,
text={Question},
stopper={.}]

\defineenumeration[hint]
[alternative=hanging,
width=4cm,
text={Hint for question},
stopper={.}]

[alternative=hanging,
width=4.5cm,
stopper={.}]

\setupblock[question][before={\startquestion},after={\stopquestion}]
\setupblock[hint][before={\starthint},after={\stophint}]

\keepblocks[question]
\hideblocks[hint]

\starttext

\section{Questions}

\beginquestion
Compute $4\times 5$.
\endquestion

\beginhint
Use the fact that $2\times 5 = 10$.
\endhint

$20$.

\beginquestion
What is the value of $100 / 10$?
\endquestion

\beginhint
Remember that $10\times 10 = 100$.
\endhint

$10$

\section{Hints to all questions}

\useblocks[hint]

\stoptext

___________________________________________________________________________________
Wiki!

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




___________________________________________________________________________________