Re: [NTG-context] Clickable question/answer numbers (Otared Kavian)

2016-11-07 Thread Willi Egger
Otared, thank you for this nice example! Willi > On 7 Nov 2016, at 04:21, Otared Kavian wrote: > > Dear Dalyoung, > > I guess you are typesetting the wrong file, or you have put the last code I > sent into a file which contains something of the previous codes… > Indeed in

Re: [NTG-context] Clickable question/answer numbers

2016-11-07 Thread Otared Kavian
Hi Dalyoung, Yes I see what your problem might had been. Recently ConTeXt creates a fine named FILENAME.tuc when one typesets FILENAME.tex. This *.tuc file creates difficulties when the typesetting is stopped for some reason or another, because then at times it is impossible to typeset again

Re: [NTG-context] Clickable question/answer numbers

2016-11-07 Thread Jeong Dal
Dear Otared, It is not the problem of your code. Strangely, the code you just sent to me is stopped by the same reason during the compilation even though it does not contain the word “myanswer”. After removing *.tmc file, the error disappear. I still don’t know why such an error occurred.

Re: [NTG-context] Clickable question/answer numbers (Otared Kavian)

2016-11-06 Thread Otared Kavian
Dear Dalyoung, I guess you are typesetting the wrong file, or you have put the last code I sent into a file which contains something of the previous codes… Indeed in the last file I sent (which I am sending again at the end of this reply) does not contain the command \myanswer… which appears in

Re: [NTG-context] Clickable question/answer numbers (Otared Kavian)

2016-11-06 Thread Jeong Dal
Dear Otared, Hi, I run the given code and got an error message as following. tex error > tex error on line 1 in file virtual://block.answer.2: ! Undefined control sequence l.1 \myanswer [Q:test] Would you please tell me how to avoid such an error? It seems to me that you

Re: [NTG-context] Clickable question/answer numbers

2016-11-06 Thread Otared Kavian
Hi Wolfgang, Hi Mikael, Thanks Wolfgang! I didn’t know that \beginBLOCKNAME \endBLOCKNAME cannot be used in other macros… There is some mystery in this for me. Now with \doifnotmode{*trialtypesetting} everything works as expected. Since I don’t know whether, nor where on the wiki,

Re: [NTG-context] Clickable question/answer numbers

2016-11-06 Thread Wolfgang Schuster
Otared Kavian 6. November 2016 um 11:43 Hi Wolfgang, Thanks for the solution you sent yesterday. Your solutions solves the problem I was fighting with, but when I try to apply it to my real document there is an issue when some questions don’t have answers. This

Re: [NTG-context] Clickable question/answer numbers

2016-11-06 Thread Otared Kavian
Hi Wolfgang, Thanks for the solution you sent yesterday. Your solutions solves the problem I was fighting with, but when I try to apply it to my real document there is an issue when some questions don’t have answers. This prevents the synchronization of Questions and Answers if one doesn't

Re: [NTG-context] Clickable question/answer numbers

2016-11-05 Thread Wolfgang Schuster
Otared Kavian 5. November 2016 um 18:34 Hi Wolfgang, Hi Mikael, Thank you both for your great inputs! I tried to modify the code each of you sent yesterday in order to « couple » automatically each question with its answer, using the keyword « coupling=… », but

Re: [NTG-context] Clickable question/answer numbers

2016-11-05 Thread Otared Kavian
Hi Wolfgang, Hi Mikael, Thank you both for your great inputs! I tried to modify the code each of you sent yesterday in order to « couple » automatically each question with its answer, using the keyword « coupling=… », but somehow I am unable to create automatic references by extracting the

Re: [NTG-context] Clickable question/answer numbers

2016-11-05 Thread Mikael P. Sundqvist
Dear Wolfgang, thank you for the information. I will probably do that in next document, since it seems convenient. Best regards, Mikael On Sat, Nov 5, 2016 at 1:38 PM, Wolfgang Schuster wrote: > Mikael P. Sundqvist > 4. November 2016 um 16:33 > Thank you very

Re: [NTG-context] Clickable question/answer numbers

2016-11-05 Thread Wolfgang Schuster
Mikael P. Sundqvist 4. November 2016 um 16:33 Thank you very much Wolfgang! Now I can get exactly what I need, see the example below (also tested with my larger document, available at http://www.maths.lth.se/matematiklth/personal/mickep/analysB2ht16/analys-context.pdf).

Re: [NTG-context] Clickable question/answer numbers

2016-11-04 Thread Mikael P. Sundqvist
Thank you very much Wolfgang! Now I can get exactly what I need, see the example below (also tested with my larger document, available at http://www.maths.lth.se/matematiklth/personal/mickep/analysB2ht16/analys-context.pdf). I'm very happy about this solution. Also, thanks to Hans for giving us

Re: [NTG-context] Clickable question/answer numbers

2016-11-04 Thread Wolfgang Schuster
Mikael P. Sundqvist 3. November 2016 um 16:14 Dear Otared (and others), while waiting for Hans reply on the \namedenumerationparameter and \enumerationparameter, this is the best I could do. Now, only "Question" is clickable and not the number, but I think I could live

Re: [NTG-context] Clickable question/answer numbers

2016-11-04 Thread Otared Kavian
Hi Mikael, Thank you for sharing the solution you found! Your definitions suit me too, but in any case I’ll play with your code to see whether using the concept of « coupling » between each exercise and its solution (or hint, if one adds them) could allow the creation of an automatic

Re: [NTG-context] Clickable question/answer numbers

2016-11-03 Thread Mikael P. Sundqvist
Dear Otared (and others), while waiting for Hans reply on the \namedenumerationparameter and \enumerationparameter, this is the best I could do. Now, only "Question" is clickable and not the number, but I think I could live with that if no other solution show up. Best regards, Mikael

Re: [NTG-context] Clickable question/answer numbers

2016-11-03 Thread Mikael P. Sundqvist
Dear Hans, This seems to be exactly what I need, but I cannot get it to work. With the example below nothing comes from those commands (I just updated my standalone to the latest one). On the other hand, with text instead of reference it works. Best regards, Mikael \defineenumeration[question][

Re: [NTG-context] Clickable question/answer numbers

2016-11-03 Thread Hans Hagen
On 11/2/2016 9:58 PM, Mikael P. Sundqvist wrote: Dear Otared, thank you again. This is somehow a proof that it should work. In my real document I use the title to name some exercises (after old exams), and I don't see how that can be combined with your solution. If someone else reads this: I

Re: [NTG-context] Clickable question/answer numbers

2016-11-02 Thread Mikael P. Sundqvist
Dear Otared, thank you again. This is somehow a proof that it should work. In my real document I use the title to name some exercises (after old exams), and I don't see how that can be combined with your solution. If someone else reads this: I think the question boils down to the following:

Re: [NTG-context] Clickable question/answer numbers

2016-11-02 Thread Otared Kavian
Hi Mikael, A partial solution to the feature we are discussing is contained in the example below, but somone more aware of ConTeXtish coding might improve it. It is not satisfactory in that one has to define twice \startquestion and \StartQuestion, \beginanswer and \BeginAnswer, and more

Re: [NTG-context] Clickable question/answer numbers

2016-11-02 Thread Mikael P. Sundqvist
Dear Otared (and list), thank you for your reply and support. The links from the answers to the questions work as wanted with my solution, it is the links from the questions to the answers that do not. I guess I need something like headcommand={\in{Question}[A:###]}, where ### is the

Re: [NTG-context] Clickable question/answer numbers

2016-11-02 Thread Otared Kavian
Hi Mikael, I had a similar question some time ago, but I wanted to add a sort of automatic referencing of questions and answers (and interaction going from questions to answers and back). If you accept the hurdle of adding manual references, in your case you can add (for instance…)

[NTG-context] Clickable question/answer numbers

2016-11-02 Thread Mikael P. Sundqvist
Dear list, I have a pretty large text with a lot of questions and answers, and want the user(students) to be able to click in the pdf to go from a certain exercise to its answer, and back. I have a solution (see below) to go from answers to questions, but not the other way around. I simply have