Comments (12)
I can only speak for me. At the moment I'm using exsheets because synctex is working fine with it. Synctex is essential for my workflow, so I would appreciate this feature very much.
from xsim.
I have implemented the experimental package option no-files
(official update to CTAN will come in the next days…). For the time being this does not allow verbatim material when used.
\usepackage[no-files]{xsim}
Feedback (problems? ... ) very welcome!
from xsim.
I don't know much about synctex but I am quite certain there is nothing a package author can do about it.
from xsim.
This is the same problem: https://tex.stackexchange.com/questions/163951/ – no solution, though
from xsim.
Ok, thanks for your research, maybe the problem will be fixed some day...until now I will live with it :-)
from xsim.
I wonder if there is a way to make an xsim option to put only the verbatim environments in their own separate source document, rather than doing this unconditionally on the entire text of every exercise and solution. Then, outside of the verbatim environment, the source links would link back to the original source.
I'll bet the problem could be solved in this way: give an option, disabled by default, to turn off the "separate exercise/solution *.tex files". Then, introduce a new environment, xsimverbatim
, which, if this option is enabled, would be required to surround any verbatim environment used. For example:
Here is some verbatim text:
\begin{xsimverbatim}
\begin{verbatim}
def f(x):
return x+1
\end{verbatim}
\end{xsimverbatim}
Here is some code in another verbatim environment:
\begin{xsimverbatim}
\begin{lstlisting}[language=Python]
def f(x):
return x+1
\end{lstlisting}
\end{xsimverbatim}
Then xsim could pull the content out of each xsimverbatim
environment and put it into a separate file, similarly to what is currently done with the exercise
and solution
environments. Similarly, there could be a new command \xsimverb
for inline verbatim text: \xsimverb{\verb!x++;!}
The idea is that xsim wouldn't have to do much special processing or know anything about the verbatim text. One could use xsimverbatim
and \xsimverb
anywhere, without having to have a verbatim
environment inside of it. It's just an instruction to put the contents in a separate file before running pdflatex.
Update: I read the documentation more carefully and saw there already is something like this in the xsimverb
package, although it seems to require some boilerplate compared to simply having a new environment. So it seems that the above could be fairly simply implemented with an option to disable the writing of exercise/solution-body.tex files.
from xsim.
I have thought about this and not yet dismissed it completely. There is a good chance I will implement it when I find the time. The default behaviour will stay the same, though, I think.
from xsim.
I'd like to second this request, not only because synctex takes me to the wrong file, but also because in AUCTeX (I don't know about other LaTeX environments), jumping to an error also takes me to the temp file, rather than to my main document. I'm actually trying out exsheets
right now for these very reasons, even though I know it's deprecated.
BTW, doesn't issue #30 address the same issue?
from xsim.
I am planning to add a solution as an alternative to the current behavior. I do not have as much time as I used to for (La)TeX currently.
This will come one time…
(#30 (comment))
from xsim.
I'd also welcome a fix for this. I recently switched from exsheets to xsim (found out that the former is deprecated because it seemingly became incompatible with a change in the newest texlive). However, not having proper synctex support is really annoying. Actually I don't care at all about verbatim environments in my exercise sheets, so even an option to disable external files while sacrificing verbatim support would be fine for me.
In any case, thanks for the work on both exsheets and xsim :).
from xsim.
Is there any way to make this more granular so that verbatim material is allowed, and it will generate extra files (with their associated source link problems), but any exercise not using verbatim environments could be given the option [no-file] and would remain inline (and have working source links)?
from xsim.
Probably, yes. But I don't expect this to be happening soon. It would require significant (!) changes to existing code.
from xsim.
Related Issues (20)
- 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
- Printcollection outputs questions without question number HOT 1
- Pre-hook is not applicable to exercise environment HOT 1
- Buffer problem HOT 4
- Usint \lstinline{#include <iostream>} display one more # HOT 4
- mcq with more than one correct choice
- xsim.description-list.tex does not compile HOT 1
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.