Comments (5)
Also \printsolutions
does not show exercises with the property solution
. This worked before upgrading to xsim v0.21
.
from xsim.
Oh bugger. I don't know how this could happen :(
This is a bug in
\prg_new_conditional:Npnn \xsim_if_exchange:nnn #1#2#3 {T,F,TF}
{
\str_if_eq:nnTF {#3} {solution} % <<< this should be `exercise'
{
\xsim_if_boolean_property:nnnTF {#1} {#2} {solution}
{ \prg_return_true: }
{ \prg_return_false: }
}
{ \prg_return_false: }
}
Adding
\ExplSyntaxOn
\prg_set_conditional:Npnn \xsim_if_exchange:nnn #1#2#3 {T,F,TF}
{
\str_if_eq:nnTF {#3} {exercise}
{
\xsim_if_boolean_property:nnnTF {#1} {#2} {solution}
{ \prg_return_true: }
{ \prg_return_false: }
}
{ \prg_return_false: }
}
\ExplSyntaxOff
to your preamble should restore the behaviour till the next update is released.
Unrelated to the bug I'm not sure
\begin{exercise}[solution]
algebra question 1
\IfInsideSolutionT{Solution to algebra question 1}
\end{exercise}
should print anything with exercise/print=false
.
I'd rather use
\begin{exercise}[solution=true,ID=one]
algebra question 1
\IfInsideSolutionT{Solution to algebra question 1}
\end{exercise}
\printsolution{exercise}{one}
from xsim.
Yes, I just tested commit 99d8b80 and it fixed the issue. Thanks a lot!
Is there a place for discussions? I understood, that (conceptually) the solution property creates a solution environment by "copying" the exercise. Hence, I expected that exercise/print=false
does not print the exercise, but the copied solution.
I am using the solution property a lot and would like to print a sheet with solutions only. Using IDs and then iterate over them for \printsolution
is okay, but I am not very happy with this.
from xsim.
We can discuss here.
I can imagine an option that enables the behaviour you want – maybe even as a default setting.
Maybe
\begin{exercise}[solution]
xxx
\end{exercise}
should be the same as
\begin{exercise}
xxx
\end{exercise}
\begin{solution}
xxx
\end{solution}
at least in regard to global options...
from xsim.
Great! That is exactly the behavior I expected.
from xsim.
Related Issues (20)
- Improve doc for `\UseExerciseTemplate` HOT 3
- \numberofexercise with space after HOT 1
- Custom grading table template not working HOT 3
- global option print-solutions HOT 1
- Solutions not printed HOT 2
- Allow printcollection to filter by tags
- match-all and match-any option for collection may be redundant.
- xsim, babel and tikz; problem with quotation marks
- Request: pointssum of an exercise behind the last line
- Possible Bug when combining a tabular and an exercise environment HOT 3
- double vertical line in array HOT 1
- Cloze-Tests, blanks not filled with solution/print = true HOT 1
- Wrong documentation for `AddtoExerciseTypeGoal` and `AddtoExerciseTypeGoalPrint`
- Points question xsim package precision decimal HOT 2
- Strange distancing when starting with a bulleted enviroment. HOT 1
- solution HOT 4
- Problem with two ExerciseType HOT 3
- Wording of warning message HOT 4
- Generic hook 'package/after/xsim' is deprecated. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xsim.