You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to do something similar to https://texwelt.de/fragen/22255/xsim-printcollection-jede-aufgabe-mit-losung-auf-einer-neuen-seite. I'm trying to start some exercises on a new page. However, when I set the exercise hook on the exercise environment itself, it seems that the hook is not applied. Setting the hook globally does work. Setting the hook on the solution environment also works.
Is this expected behaviour that I missed in the docs? Or what am I doing wrong?
I greatly appreciate any help.
The text was updated successfully, but these errors were encountered:
m-haug
changed the title
Pre-hook is not applicable to exercises
Pre-hook is not applicable to exercise environment
Nov 16, 2023
It seems the support for hook options pre-hook, begin-hook, end-hook, and post-hook are incomplete.
For exercise environment, it currently treats all env options as properties. But hook options are not properties, thus they are either ignored (in v0.21 2022/02/12) or throw errors
! Package xsim Error: You tried to set the property `pre-hook' on line <n>.
(xsim) This property does not exist. Check for a typo or
(xsim) define the property yourself.
using the current dev (99d8b80, the change in \__xsim_set_property:nnnn).
For solution environment, it currently process env options through normal key-value functions. This may seem to work if solution envs are printed immediately, but if they're printed by \printsolutions, per env hook settings are still lost.
I'm trying to do something similar to https://texwelt.de/fragen/22255/xsim-printcollection-jede-aufgabe-mit-losung-auf-einer-neuen-seite. I'm trying to start some exercises on a new page. However, when I set the exercise hook on the exercise environment itself, it seems that the hook is not applied. Setting the hook globally does work. Setting the hook on the solution environment also works.
Is this expected behaviour that I missed in the docs? Or what am I doing wrong?
I greatly appreciate any help.
The text was updated successfully, but these errors were encountered: