Reputation
3,830
Top tag
Next privilege 5,000 Rep.
Approve tag wiki edits
Badges
10 27
Newest
 Nice Answer
Impact
~66k people reached

23s
comment screenplay-pkg affects margins
The margins are wrong but that was my question. How did you determine they are wrong? how would one determine they are wrong? I looked at both version and see no difference. But you did not say what tool to use to determine the margins are wrong. Just looking?
42m
comment screenplay-pkg affects margins
spine margins (about the size of 1 letter) How to do actually determine this? It also helps to put a link to this package {screenplay-pkg} so that folks do not spend time looking for it since it is not on CTAN
5h
comment How to use luacode* to eliminate need to escape “\”?
@JavierBezos I can't get the [[..]] to work inside Latex. I see the correct string build by printing it, but the PDF shows grabage. Feel free to modify the example I have above to show me how. Here is one of my attempts.\documentclass{article} \usepackage{luacode} \begin{document} The following is my table \begin{luacode*} i=6; j=8; a = [[\begin{tabular}{|l|l|}\hline ]]..i.."&"..j..[[\\ \hline \end{tabular} ]]; print(a); tex.print(a); \end{luacode*} \end{document} I can do all this in Python using r""..."" so easily, I wonder why would I need to use Lua inside Latex for this.
12h
revised Is it possible to view the latex code after Lua expansion is made?
made it more clear
13h
comment Is it possible to view the latex code after Lua expansion is made?
Ok, but I thought I was very clear there when I said What I'd like to now see is the Latex file that would resulted after the Lua code expansion, which should be something as follows and also gave example of what the file I'd like to see would look like. But I will add more in few minutes....I need to make a little larger example....
14h
comment Is it possible to view the latex code after Lua expansion is made?
I wonder if you want us to print the TeX code into the LaTeX document in a verbatim fashion Not really. I do not want the lua code printed in Verbatim. I just wanted to see the full Latex document, after all the lua code was replaced by the actual Latex code it generated as I have in the example in my question.
14h
comment Is it possible to view the latex code after Lua expansion is made?
Thanks. This does make it little hard to see the bits of the code on the screen, and if I understand you method, it means one has to duplicate all the lua code inside the Latex file? One copy to use print and one copy to use tex.print? it would be nice if luatex would add support to generate the full expended latex to some external file as I said in my above comment to the other answer. Thanks for your answer.
14h
comment Is it possible to view the latex code after Lua expansion is made?
Oh, I did not know the message on the screen I was getting was by design. I knew very little about these Latex tricks. But this method is not really practical for me. First of all, I do not want to write "\noexpand" everywhere, this makes the code hard to read and write. All what I was thinking of, is that if the final latex file, after all expansion, could be written to some other file, say foo.lux or something (we need new extension :) and then a user can look at the .lux file to see the full Latex code which was actually compiled to generated the pdf after all the expansion.
18h
awarded  Nice Answer
21h
awarded  Nice Question
1d
comment Is it possible to view the latex code after Lua expansion is made?
does the above code compile ok for you? Here is screen shot showing the error I get. I copied the code as is. !Mathematica graphics fyi, I am using TL 2015 on Linux mint.
1d
revised Reducing fraction using LaTeX 3
clean code
1d
answered Reducing fraction using LaTeX 3
1d
comment Is it possible to view the latex code after Lua expansion is made?
Thanks. fyi, there seems to be some typo somewhere? I get this error on TL 15 lualatex foo1.tex This is LuaTeX, Version beta-0.80.0 (TeX Live 2015) (rev 5238) restricted \write18 enabled. (./foo1.tex LaTeX2e <2015/01/01> Babel <3.9l> and hyphenation patterns for 79 languages loaded. (/usr/local/texlive/2015/texmf-dist/tex/latex/base/article.cls Document Class: article 2014/09/29 v1.4h Standard LaTeX document class (/usr/local/texlive/2015/texmf-dist/tex/latex/base/size10.clo)) (./foo1.aux) > \begin {tabular}{|l|l|}\hline 6&8 \\ \hline \end {tabular}. l.14 } ? x
1d
comment Is it possible to view the latex code after Lua expansion is made?
@JosephWright I do not know to change the example about to use \directlua and keep everything else the same. I get errors when I replaced luacode with \directlua{...}. If you could show this is done and how to view the generated Latex that will help. I do not want to have external lua files. I want the lua code to be inside the Latex file itself as shown. I am still learning lua and find all these different environments very confusing so far. Thanks
1d
asked Is it possible to view the latex code after Lua expansion is made?
1d
comment How to use luacode* to eliminate need to escape “\”?
@UlrikeFischer this is all so confusing. I do not know about Tex->Lua part, since I am just looking at Lua->Tex now. But if you are saying the luacode* is meant to apply for the "Tex->Lua" and not to Lua->Tex then this makes using strings in Lua very hard if one have to escape all the "\" each time. I can do all the above much easier in Python, without having to escape anything, using Pythons r""" multi-line raw string support. So I am trying to understand why would I need to use Lua then in this case.
1d
asked How to use luacode* to eliminate need to escape “\”?
2d
comment How can I make a professional looking article layout?
I am using LyX, which usually makes typing text easier, but it seems adding actual Latex design is very difficult if you want full control of Latex, you must write Latex code directly yourself. I use SW also, and many times, I have to edit the Latex code generated to make any customization. Using a GUI application in these cases (Lyx, SW, etc...) gets in the way of doing such things.
2d
answered Convert to HTML with {arabtext} sections rendered as images