printing Latex
Modérateur : xcasadmin
-
- Messages : 151
- Inscription : mer. janv. 13, 2010 3:20 pm
printing Latex
Is there a way to not output levels that are grouped and hidden when producing Latex output?
Re: printing Latex
No, you must edit manually the tex file.
-
- Messages : 151
- Inscription : mer. janv. 13, 2010 3:20 pm
Re: printing Latex
Could you put an identifiable text string in the tex file before and after grouped and hidden sections?
Re: printing Latex
I'll try...
-
- Messages : 151
- Inscription : mer. janv. 13, 2010 3:20 pm
Re: printing Latex
Thank you. The more I use xcas the more I like it. I use in in teaching. I teach Mechanical Engineering at the University of Miami. The latex output is great for handouts and explanations.
Re: printing Latex
It should be implemented now: and
Code : Tout sélectionner
%% begin hidden group
Code : Tout sélectionner
%% end hidden group
-
- Messages : 151
- Inscription : mer. janv. 13, 2010 3:20 pm
Re: printing Latex
Thank you.
I got to try it and it works very well. Here is a sample bash script
# remove hidden sections from xcas latex printout
if [ $# -eq 0 ] # if no args
then
echo "Usage: $0 <xcas latex filename>"
echo "backup of original latex file saved in xcas_strip_hidden.bk"
exit
fi
cp $1 xcas_strip_hidden.bk # save original .tex file
gawk '
BEGIN {
printflag=1
}
/%% begin hidden group/{
# print "found:", $0
printflag=0
}
/\\end\{document\}/{
printflag=1
}
/%% end hidden group/&&printflag==0{
# print "found:", $0
printflag=1
next
}
printflag==1{
print
}
' xcas_strip_hidden.bk >$1
works good in Cygwin
I got to try it and it works very well. Here is a sample bash script
# remove hidden sections from xcas latex printout
if [ $# -eq 0 ] # if no args
then
echo "Usage: $0 <xcas latex filename>"
echo "backup of original latex file saved in xcas_strip_hidden.bk"
exit
fi
cp $1 xcas_strip_hidden.bk # save original .tex file
gawk '
BEGIN {
printflag=1
}
/%% begin hidden group/{
# print "found:", $0
printflag=0
}
/\\end\{document\}/{
printflag=1
}
/%% end hidden group/&&printflag==0{
# print "found:", $0
printflag=1
next
}
printflag==1{
}
' xcas_strip_hidden.bk >$1
works good in Cygwin