Re: Python Graphics in LyX [was: Python bindings]
Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang
Re: Python Graphics in LyX [was: Python bindings]
I retryed again and now got the PythonGraphicsLyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of viewpdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H return for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang
Re: Python Graphics in LyX [was: Python bindings]
Alex Vergara Gil a...@cphr.edu.cu writes: Dear Lyxers! Studying a little of python and LyX I have reached to this feature that makes LyX show and process python graphics. Thanks to Rainer M Krug for the hints. I share this contribution for LyX under LGPL license, so everyone benefits from it. Good luck and happy lyxing! Alex Vergara Gil MSc Nuclear Physics SSDL, CPHR, Havana Cuba PS: If Rainer agree, pass him from acknowledgements to author list, please. That looks beautiful. AS I have no idea how python works, co-author would probably better. Thanks, Rainer -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgphSDFfXP5gr.pgp Description: PGP signature
Re: Python Graphics in LyX [was: Python bindings]
Murat Yildizoglu myi...@gmail.com writes: Thanks Alex, That opens new and nice perspectives. I have just thought about another possibility: Since the Sage software uses Python as a glue, it must be also possible to use the Sage module for LyX to make computations in Python in Sage and include the results in the final PDF file. There are numerous possibilities using converters like this - ranging From simple scripts (one can also call R like this if one does not need a single session and only wants to do simple graphs), to calling complex simulations... whatever produces graphs. Actually not only graphs, also text, e.g. tables generated should work with the correct export format? Alex - I think it would be a good idea to add this to the LyX wiki. Cheers, Rainer That reminds me that I should check the Sage module for the last version of Lyx (have not had any time to look at it yet). Best regards, Murat Alex Vergara Gil a écrit : Dear Lyxers! Studying a little of python and LyX I have reached to this feature that makes LyX show and process python graphics. Thanks to Rainer M Krug for the hints. I share this contribution for LyX under LGPL license, so everyone benefits from it. Good luck and happy lyxing! Alex Vergara Gil MSc Nuclear Physics SSDL, CPHR, Havana Cuba PS: If Rainer agree, pass him from acknowledgements to author list, please. -- Universite' de Bordeaux CNRS Prof. Murat Yildizoglu GREThA (UMR CNRS 5113) UNIVERSITE DE BORDEAUX GREThA (UMR CNRS 5113) MURAT YILDIZOGLU 16 AVENUE LEON DUGUIT CS 50057 33608 PESSAC CEDEX FRANCE Bureau : E-331 yildizoglu.info -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpBotkKNuSAc.pgp Description: PGP signature
Inserting text (instead of graphics) from code into LyX?
Hi In the thread Python Graphics in LyX it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpVGQSRoC0nx.pgp Description: PGP signature
Re: reconfiguration fails (miktex)
Paul A. Rubin rubin at msu.edu writes: I don't have ready access to a Windows partition with LyX 2.1 any more, so I'm winging this a bit. I noticed your path to lyx.exe contained cygdrive: $ /cygdrive/c/Program\ Files\ \(x86\)/LyX\ 2.1/bin/lyx.exe -x reconfigure By any chance does that mean you have LyX installed on a machine running Cygwin? Years ago I had problems with reconfiguring LyX because Cygwin had a (broken, as I recall) version of latex that appeared on the command path ahead of the MiKTeX version. If that's the case for you, moving MiKTeX's bin directory ahead of the Cygwin bin directory on the system command path might help. (I would put LyX's bin directory ahead of Cygwin's as well.) Paul Hi Paul, thanks for your help! Yes, there is cygwin install on the computer. I now looked for the cygwin directory in system path variable, but there was only the miktex path, so I'm not sure if that is the problem or if I looked at the wrong variable. This is what's in the path variable: C:\Windows\system32 C:\Windows C:\Windows\System32\Wbem C:\Windows\System32\WindowsPowerShell\v1.0\ C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\ C:\Program Files\OpenAFS\Common C:\Program Files\OpenAFS\Client\Program C:\Program Files (x86)\OpenAFS\Common C:\Program Files (x86)\OpenAFS\Client\Program C:\Program Files (x86)\Heimdal\bin\ C:\Program Files\Heimdal\bin\ and these are the paths from LyX: $LyXDir\bin; $LyXDir\Python; $LyXDir\Python\Lib; $LyXDir\Perl\bin; $LyXDir\imagemagick; C:\Program Files (x86)\MiKTeX 2.9\miktex\tex\latex; C:\Program Files (x86)\MiKTeX 2.9\miktex\bin; C:\Program Files (x86)\Vim\vim74; C:\Program Files (x86)\LyX 2.1\ghostscript\bin Cheers, Fabian
Re: Backspacing at the start of an inset occupying a paragraph
08/06/2014 22:57, Richard Heck: I think the reason this happens is that the layout in effect in the inset becomes the layout in effect in the paragraph, if the inset is the only thing there. I'm not sure exactly why it works that way, though. This is is probably the case indeed. This makes sense when the note contains a Section environment for example. The behavior should be dependent on whether the layout is the default one or not. I have no idea of where this code lives, though. I think this deserves a bug report. JMarc
Re: How to insert a slashed o?
08/06/2014 23:01, stefano franchi: Thanks Richard, that's what I did, eventually (cutting and pasting). I was just hoping there'd be a function I could bind to a shortcut, but apparently not. Try unicode-insert 0x00F8. JMarc
paper accepted for publication, but need help!
Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: paper accepted for publication, but need help!
I guess, if you take out the ref: Vazquez-Castro, and A.~Morello the error is gone. Check carefully the reference, perhaps by adding parts only (eg only the first word of the title, journal etc) Wolfgang Am 10.06.2014 13:35, schrieb Neal Becker: Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: paper accepted for publication, but need help!
The problem is triggered by my .bib entry, which includes a non-ascii character: author = {Wojciech Bruzda and Wojciech Tadej and Karol Życzkowski}, By playing with lyx Document/Settings/Encoding, selecting unicode XeTeX (utf-8), I seem to be able to export dvi and then convert dvipdf OK. So is this a good procedure, or is something else recommended here? Neal Becker wrote: Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: [Feature Request] python binding
Alex, This did not work for me. I can run the python script from the command line and it does produce a .png output. So I know the script is working. But, in LyX 2.0.1 which I'm using, I get Error converting to loadable format. I am trying to debug it. Not sure at this point why it does not convert inside LyX. I double checked the file format is defined and also the converter is defined correctly. I will try to turn on a log file to see if there are some other diagnostic messages. Phil On 6/2/2014 1:25 PM, Alex Vergara Gil wrote: This might work!! Thanks for the suggestions, I will try it extensively and I will comments my experiences afterwards. It seems it also renders the graphic inside LyX itself! That's what I was talking about. Regards Alex - Original Message - From: Rainer M Krug rai...@krugs.de To: Alex Vergara Gil a...@cphr.edu.cu Cc: Richard Heck rgh...@lyx.org; lyx-users Users lyx-users@lists.lyx.org; lyx-de...@lists.lyx.org Sent: Monday, June 02, 2014 8:31 AM Subject: Re: [Feature Request] python binding I just add comments inline Let's see if I understand: -1. You define a *file type* in LyX under Preferences File Handling File Formats for the file type .pygr in which Vector graphics format is ticked! 0. You define a converter under Preferences File Handling Converters which calls a script which executed files with the extension .pygr and generates, as you suggest below, an svg. 1. I wrote a python script that produces the graphic I want Exactly - and you give it a specific extension .pygr for python script which generates a graphic which you defined above. 2. I insert it in LyX somehow I don't know, perhaps defining a converter from .py to svg, but this needs to be inside a module or every python script in LyX will try to be converted into a svg!! So a module is also needed Use insert graphic and select *your .pygr* file as graphic - and Lyx will do the rest of the conversion - i.e. use your converter to convert the .pygr to an svg and other existing converters to generate the png for the preview and the pdf / eps / ... for the final copmpilation of the document. 3. LyX is the one who knows the correct size of the graphic so in principle if I produce a svg should be enough but in this way I need to produce a new svg every time the data change Correct - if the input data changes, you have to generate the graph again manually, or, if the Converter file cache is disabled, you just have to close the document and open it again. Hope this helps, Rainer
Re: paper accepted for publication, but need help!
10/06/2014 13:49, Neal Becker: The problem is triggered by my .bib entry, which includes a non-ascii character: author = {Wojciech Bruzda and Wojciech Tadej and Karol Życzkowski}, By playing with lyx Document/Settings/Encoding, selecting unicode XeTeX (utf-8), I seem to be able to export dvi and then convert dvipdf OK. So is this a good procedure, or is something else recommended here? You should use the same encoding for your document and the LyX output encoding. A workaround is to use LaTeX markup in the .bib file so that it is compatible with any encoding. JMarc
Re: Insets that don't mess up text flow.
Thanks for the tip! While not what I intended, it indeed results in much less intrusive multi-line footnotes, especially when combined with Richard Heck's local layout. - Klaus 2014-05-27 16:42 GMT+02:00 Liviu Andronic landronim...@gmail.com: On Tue, May 27, 2014 at 3:19 PM, Klaus-Dieter Bauer klaus-dieter.ba...@jku.at wrote: Hello! When creating a lengthy footnote and not folding it (Ctrl+I), it will invariably mess up the text-flow, causing the last line before the footnote to be stretched to paragraph width regardless of contents. I sometimes End up with situations like Maybe this can help: http://wiki.lyx.org/LyX.NewInLyX21#misc Users can now decide for every document in the menu Document→Settings→Text Layout if LyX justifies the document text or not. (This setting has no effect on the output.) Liviu : Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext Sampletext Sampletext : Sample ~ H U G E E M P T Y S P A C E ~ Text : [foot1] : |Here is the footnote text that goes over : |several lines, just because. : +-- : RestOfPar RestOfPar RestOfPar RestOfPar : RestOfPar RestOfPar RestOfPar RestOfPar : RestOfPar RestOfPar. Yet the footnote may contain information that, while not important enough to clutter the output text, may be important enough for me not to fold the footnote away. Would it be possible to get with custom formats either 1. Footnotes that look like normal text, except for a different formatting, i.e. : Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext [foot1][Foot Foot Foot : Foot Foot Foot Foot Foot Foot Foot Foot] Rest : OfPar RestOfPar RestOfPar. 2. Footnotes to show the beginning of the text, like ERT does, i.e. : Sampletext Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext [foot1][This is the footn...] : RestOfPar RestOfPar RestOfPar. - Klaus -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: Python Graphics in LyX [was: Python bindings]
Dear all I have rewritten a little the procedure using recommendations from several users that doesn´t understand the original one. I hope this time everyone can understand the procedure. Regards Alex - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Tuesday, June 10, 2014 2:56 AM Subject: Re: Python Graphics in LyX [was: Python bindings] I retryed again and now got the PythonGraphicsLyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of viewpdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H return for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang __ Información de ESET NOD32 Antivirus, versión de la base de firmas de virus 9900 (20140605) __ ESET NOD32 Antivirus ha comprobado este mensaje. http://www.eset.com Python Graphics.lyx Description: Binary data
Re: Inserting text (instead of graphics) from code into LyX?
- Original Message - From: Rainer M Krug rai...@krugs.de Sent: Tuesday, June 10, 2014 3:26 AM Hi In the thread Python Graphics in LyX it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer Indeed! It can be produced as well, just define a python normal text file format type (as pytxt) and in the converter just add from the pytxt format to simple text format as python $$i $$o in the python script you have to output everything to a text file using the lines import sys outputfile = open(sys.argv[1]) outputfile.write('testing') outputfile.close Voilá! it works with text too Moreover in the converter you can define a csv output format and python handles well with csv, so I give you the rod, now fish something ;) Cheers, Alex
Re: Inserting text (instead of graphics) from code into LyX?
Alex Vergara Gil a...@cphr.edu.cu writes: - Original Message - From: Rainer M Krug rai...@krugs.de Sent: Tuesday, June 10, 2014 3:26 AM Hi In the thread Python Graphics in LyX it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer Indeed! It can be produced as well, just define a python normal text file format type (as pytxt) and in the converter just add from the pytxt format to simple text format as python $$i $$o in the python script you have to output everything to a text file using the lines import sys outputfile = open(sys.argv[1]) outputfile.write('testing') outputfile.close Voilá! it works with text too Moreover in the converter you can define a csv output format and python handles well with csv, so I give you the rod, now fish something ;) As I said - I have missed something trivial. Suggestion: could you add these cases to your document about graphs from Python? Especially the csv might be very useful. Cheers, Rainer Cheers, Alex -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpfDFEEurWzn.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
Better than ever I've found that the pandas package in python handles with excel files and produces tables in csv too, so it can be used to read excel files as input, process a little and output csv tables which can be read by LyX as external documents (child) The panorama becomes interesting! Alex
Re: reconfiguration fails (miktex)
Fabian Wilde fabian.wilde at icloud.com writes: Paul A. Rubin rubin at msu.edu writes: I don't have ready access to a Windows partition with LyX 2.1 any more, so I'm winging this a bit. I noticed your path to lyx.exe contained cygdrive: $ /cygdrive/c/Program\ Files\ \(x86\)/LyX\ 2.1/bin/lyx.exe -x reconfigure By any chance does that mean you have LyX installed on a machine running Cygwin? Years ago I had problems with reconfiguring LyX because Cygwin had a (broken, as I recall) version of latex that appeared on the command path ahead of the MiKTeX version. If that's the case for you, moving MiKTeX's bin directory ahead of the Cygwin bin directory on the system command path might help. (I would put LyX's bin directory ahead of Cygwin's as well.) Paul Hi Paul, thanks for your help! Yes, there is cygwin install on the computer. I now looked for the cygwin directory in system path variable, but there was only the miktex path, so I'm not sure if that is the problem or if I looked at the wrong variable. This is what's in the path variable: C:\Windows\system32 C:\Windows C:\Windows\System32\Wbem C:\Windows\System32\WindowsPowerShell\v1.0\ C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\ C:\Program Files\OpenAFS\Common C:\Program Files\OpenAFS\Client\Program C:\Program Files (x86)\OpenAFS\Common C:\Program Files (x86)\OpenAFS\Client\Program C:\Program Files (x86)\Heimdal\bin\ C:\Program Files\Heimdal\bin\ and these are the paths from LyX: $LyXDir\bin; $LyXDir\Python; $LyXDir\Python\Lib; $LyXDir\Perl\bin; $LyXDir\imagemagick; C:\Program Files (x86)\MiKTeX 2.9\miktex\tex\latex; C:\Program Files (x86)\MiKTeX 2.9\miktex\bin; C:\Program Files (x86)\Vim\vim74; C:\Program Files (x86)\LyX 2.1\ghostscript\bin Cheers, Fabian Hi Paul and everyone! I found the solution to my problem on the LyX troubleshoot wiki. I had a problem with an UNC path. Here is a copy of the solution: LyX does not start and gives the error message: unable to find textclass file This problem may come into existence if you use LyX on a windows-pc where your windows/application profile is not stored local but on an UNC path (i.e. \\Username\Applications\LyX). One solution I have found is the following: Uninstall LyX from your PC if you have used an installation folder whose name exists of seperate words like C:\Program Files. Reinstall LyX and consider, that you use a folder whose name exists of just one word like C:\Lyx15 Start the Command Prompt in windows (Start - All Programs - Accessories - Command Prompt) Change directory to C:\ (type c:) Type c:/lyx15/python/python.exe c:/lyx15/resources/configure.py in the Command Prompt and press return After the configuration has been finished you will find 4 files in the directory c:\ - configure.log, lyxrc.defaults, textclass.lst and packages.lst Cut these 4 files and paste them into the \\Username\Application Data\LyX folder. If a directory for Lyx does not exist create a new one. Start Lyx The problem can arise even if you do not use a UNC path for the windows profile. In this case steps 5-8 are sufficient and can be carried out using the default Program Files location. Sorry for troubling you and again thanks for your help! Cheers, Fabian
Re: Inserting text (instead of graphics) from code into LyX?
Alex Vergara Gil a...@cphr.edu.cu writes: - Original Message - From: Rainer M Krug rai...@krugs.de Sent: Tuesday, June 10, 2014 8:39 AM As I said - I have missed something trivial. Suggestion: could you add these cases to your document about graphs from Python? Especially the csv might be very useful. Cheers, Rainer I see, you have to insert them as external files, like they were child documents! LyX will try to open them and in the process they will be converted But then it is inserted statically - this is not what I was thinking about. I guess the approach to use would be to use the external Material approach - but for this, one would have to define a new type. Or is there a way of dynamically linking a non-LyX or LaTeX file into a LyX document, preferably with preview? Cheers, Rainer Alex -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpqznLyv_flf.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
Alex Vergara Gil a...@cphr.edu.cu writes: Better than ever I've found that the pandas package in python handles with excel files and produces tables in csv too, so it can be used to read excel files as input, process a little and output csv tables which can be read by LyX as external documents (child) The panorama becomes interesting! OK - spreadsheets work via the external documents. But have you found a way of including normal txt files as verbatim? One could always use good old ert (e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=verbfile) But this would not provide preview. Rainer Alex -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpcbPC3_TwLk.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
- Original Message - From: Rainer M Krug Sent: Tuesday, June 10, 2014 9:09 AM OK - spreadsheets work via the external documents. But have you found a way of including normal txt files as verbatim? One could always use good old ert (e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=verbfile) But this would not provide preview. Rainer No, no preview in the case of text I fear. It should be implemented in the LyX code. Developers should handle this kind of things, if they already support image preview, why not supporting external material preview as well? They should answer this. TAIK! Cheers Alex
pick out all graphics from a lyx file?
Anyone know an easy way to pick out all the pdfs that are included in my lyx file? Before you answer, some are multipage pdfs, and are included using page=option. I want to just pick the correct pages of those.
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 4:54 PM, Neal Becker ndbeck...@gmail.com wrote: Anyone know an easy way to pick out all the pdfs that are included in my lyx file? Try to export to archive bundle, and then check what was included in there. LyX should collect all files necessary for the compilation. Liviu Before you answer, some are multipage pdfs, and are included using page=option. I want to just pick the correct pages of those. -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: pick out all graphics from a lyx file?
Liviu Andronic wrote: On Tue, Jun 10, 2014 at 4:54 PM, Neal Becker ndbeck...@gmail.com wrote: Anyone know an easy way to pick out all the pdfs that are included in my lyx file? Try to export to archive bundle, and then check what was included in there. LyX should collect all files necessary for the compilation. Liviu Before you answer, some are multipage pdfs, and are included using page=option. I want to just pick the correct pages of those. Helpful, but does not pick out a page from a multi-page pdf
Re: How to include child documents in Lyx
On Mon, Jun 9, 2014 at 1:46 PM, umair durrani umairdurr...@outlook.com wrote: I have asked this question on tex.stackexchange but got no answer so far. I am new to LaTeX and LyX. For writing my thesis I got 2 files from university: uw_masters_thesis.sty and sample_thesis.tex. The sample file contains \usepackage{uw_masters_thesis} in preamble. If I use LaTex I simply put both files in same directory and include child documents by using \include or \input in the sample_thesis.tex document. The embedded objects manual in LyX suggests to specify the Document Class of master document in child document. But in my case the document class is Report (Standard Class). In my understanding, what uses the style file is the \usepackage{uw_masters_thesis} in preamble. I am creating thesis chapters (child documents) in lyx without specifying any thing in Document Stettings. I want them to use the style provided by .sty file and finally include all of them in master document. How can I achieve this in Lyx. Please suggest a step by step solution. It's a little bit tough to provide a step-by-step solution because I'm not sure you've described your problem completely enough. Nonetheless, I will make some assumptions and do my best. From the title of your message, you appear to be asking about how to include child documents in LyX. I will answer that first, but I don't think that is actually the main problem you are having. I think the main problem you are having has to do with creating a layout file for your thesis template. *How to include child documents in LyX:* This is described in Section 7.2 of the Embedded Objects manual. 1. Go to insert-File-Child Documents. If you select include, then this will do the same as the LaTeX \include, and if you choose \input, it will do the same as the LaTeX \input which you mentioned above. 2. Select the same document class for child documents as the master document. To do this, go to Document-Settings-Document Class, and select the appropriate document class. Please do NOT use your university template when attempting this for the first time. Use one of the built-in classes, like the default article class. If you've got that working fine, then the problem does not lie in the inclusion of child documents, but in the use of your custom class file. I sense that's your real problem. *How to get your custom university thesis template to work:* This has been asked here before, and I will answer specific questions once you read the previous posts and wiki on how to do that. The wiki page on this can be found at: http://wiki.lyx.org/Examples/Thesis One recent post from the mailing list is: http://thread.gmane.org/gmane.editors.lyx.general/82099 Good luck, and please check back after trying the above. -Jacob
Re: How to include child documents in Lyx
*How to get your custom university thesis template to work:* This has been asked here before, and I will answer specific questions once you read the previous posts and wiki on how to do that. The wiki page on this can be found at: http://wiki.lyx.org/Examples/Thesis One recent post from the mailing list is: http://thread.gmane.org/gmane.editors.lyx.general/82099 Good luck, and please check back after trying the above. I have one additional reference, and a correction to what I wrote previously. The above link to the wiki is a list of example thesis templates, not how to create one. The link for how to create a custom layout from an existing style file is: http://wiki.lyx.org/Layouts/CreatingLayouts -Jacob
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 11:35 AM, Neal Becker ndbeck...@gmail.com wrote: Helpful, but does not pick out a page from a multi-page pdf If you want to export a single page from a multi-page pdf then one possibility is to use a .pdf split/merge program such as pdfsam ( http://www.pdfsam.org/ ) or pdftk ( http://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/ ). I have nothing to do with either them, I just use those programs sometimes to get just what I need from a multipage pdf, and it's convenient for me since both are in the package repositories for my OS. pdfsam has a graphical interface, whereas pdftk is commandline only as far as I know. This isn't a very elegant or completely automated solution based on the LyX file which sounds like what you are really looking for, but it's the best way I am aware of. I hope this helps. Jacob
Re: Python Graphics in LyX [was: Python bindings]
Am 10.06.2014 15:52, schrieb Alex Vergara Gil: Thanks, Alex, for the new lyx file. I now realized, that I had to load the matplotlib and pandas packages, which I did. I followed your advices Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Define a new converter from the format Python graphics to the format EPS as ... After reconfigure (necessary?) and making sure the two example graphics (in pygr format) are found in the path I get this error LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.eps' not found on input line 83. Why is it expecting an eps file instead of taking the pygr files? What am I missing? Wolfgang Dear all I have rewritten a little the procedure using recommendations from several users that doesn´t understand the original one. I hope this time everyone can understand the procedure. Regards Alex - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Tuesday, June 10, 2014 2:56 AM Subject: Re: Python Graphics in LyX [was: Python bindings] I retryed again and now got the PythonGraphicsLyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of viewpdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H return for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang __ Información de ESET NOD32 Antivirus, versión de la base de firmas de virus 9900 (20140605) __ ESET NOD32 Antivirus ha comprobado este mensaje. http://www.eset.com
Re: Python Graphics in LyX [was: Python bindings]
- Original Message - From: Wolfgang Engelmann Sent: Tuesday, June 10, 2014 2:19 PM Thanks, Alex, for the new lyx file. I now realized, that I had to load the matplotlib and pandas packages, which I did. I followed your advices Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Define a new converter from the format Python graphics to the format EPS as ... After reconfigure (necessary?) and making sure the two example graphics (in pygr format) are found in the path I get this error No, reconfigure is not necessary LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.eps' not found on input line 83. Why is it expecting an eps file instead of taking the pygr files? indeed a eps file is expected What am I missing? Wolfgang Did you can see the graphic within LyX? Did LyX display it correctly in your system? if not the case check that the example script is located at the same path than the lyx file, another way is to click in the inserted graphic and look for the example.pygr path Another possible explanation is that your system doesn't handle with eps, in this case you should change the definition and instead of eps, put pdf or png as final format, whichever work for you, you can check that because it will display the graphic within LyX even before you export anything! Regards Alex
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 7:35 PM, Neal Becker ndbeck...@gmail.com wrote: Helpful, but does not pick out a page from a multi-page pdf Oh, then (on Linux) I would recommend: PDF Mod: https://wiki.gnome.org/Apps/PdfMod PDF Chain: http://pdfchain.sourceforge.net/ PDF-Shuffler: http://sourceforge.net/projects/pdfshuffler/ Either of these would allow to extract individual pages from a PDF. Liviu -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: Backspacing at the start of an inset occupying a paragraph
On 10/06/2014 8:38 p.m., Jean-Marc Lasgouttes wrote: 08/06/2014 22:57, Richard Heck: I think the reason this happens is that the layout in effect in the inset becomes the layout in effect in the paragraph, if the inset is the only thing there. I'm not sure exactly why it works that way, though. This is is probably the case indeed. This makes sense when the note contains a Section environment for example. The behavior should be dependent on whether the layout is the default one or not. I have no idea of where this code lives, though. I think this deserves a bug report. JMarc Alas, you have confused me now. I'm not sure what to report -- my original posting or something else. Since standard is the default layout, that is indeed what the inset dissolves to if it contains normal text but, having been prompted to try a section heading in a note, it dissolves into a section heading (even within a list -- I see that it is perfectly possible to put a section heading, numbered, bolded, larger type, within a list or sublist or subsublist, and have it indented accordingly). Andrew
Re: Python Graphics in LyX [was: Python bindings]
Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang
Re: Python Graphics in LyX [was: Python bindings]
I retryed again and now got the PythonGraphicsLyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of viewpdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H return for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang
Re: Python Graphics in LyX [was: Python bindings]
Alex Vergara Gil a...@cphr.edu.cu writes: Dear Lyxers! Studying a little of python and LyX I have reached to this feature that makes LyX show and process python graphics. Thanks to Rainer M Krug for the hints. I share this contribution for LyX under LGPL license, so everyone benefits from it. Good luck and happy lyxing! Alex Vergara Gil MSc Nuclear Physics SSDL, CPHR, Havana Cuba PS: If Rainer agree, pass him from acknowledgements to author list, please. That looks beautiful. AS I have no idea how python works, co-author would probably better. Thanks, Rainer -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgphSDFfXP5gr.pgp Description: PGP signature
Re: Python Graphics in LyX [was: Python bindings]
Murat Yildizoglu myi...@gmail.com writes: Thanks Alex, That opens new and nice perspectives. I have just thought about another possibility: Since the Sage software uses Python as a glue, it must be also possible to use the Sage module for LyX to make computations in Python in Sage and include the results in the final PDF file. There are numerous possibilities using converters like this - ranging From simple scripts (one can also call R like this if one does not need a single session and only wants to do simple graphs), to calling complex simulations... whatever produces graphs. Actually not only graphs, also text, e.g. tables generated should work with the correct export format? Alex - I think it would be a good idea to add this to the LyX wiki. Cheers, Rainer That reminds me that I should check the Sage module for the last version of Lyx (have not had any time to look at it yet). Best regards, Murat Alex Vergara Gil a écrit : Dear Lyxers! Studying a little of python and LyX I have reached to this feature that makes LyX show and process python graphics. Thanks to Rainer M Krug for the hints. I share this contribution for LyX under LGPL license, so everyone benefits from it. Good luck and happy lyxing! Alex Vergara Gil MSc Nuclear Physics SSDL, CPHR, Havana Cuba PS: If Rainer agree, pass him from acknowledgements to author list, please. -- Universite' de Bordeaux CNRS Prof. Murat Yildizoglu GREThA (UMR CNRS 5113) UNIVERSITE DE BORDEAUX GREThA (UMR CNRS 5113) MURAT YILDIZOGLU 16 AVENUE LEON DUGUIT CS 50057 33608 PESSAC CEDEX FRANCE Bureau : E-331 yildizoglu.info -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpBotkKNuSAc.pgp Description: PGP signature
Inserting text (instead of graphics) from code into LyX?
Hi In the thread Python Graphics in LyX it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpVGQSRoC0nx.pgp Description: PGP signature
Re: reconfiguration fails (miktex)
Paul A. Rubin rubin at msu.edu writes: I don't have ready access to a Windows partition with LyX 2.1 any more, so I'm winging this a bit. I noticed your path to lyx.exe contained cygdrive: $ /cygdrive/c/Program\ Files\ \(x86\)/LyX\ 2.1/bin/lyx.exe -x reconfigure By any chance does that mean you have LyX installed on a machine running Cygwin? Years ago I had problems with reconfiguring LyX because Cygwin had a (broken, as I recall) version of latex that appeared on the command path ahead of the MiKTeX version. If that's the case for you, moving MiKTeX's bin directory ahead of the Cygwin bin directory on the system command path might help. (I would put LyX's bin directory ahead of Cygwin's as well.) Paul Hi Paul, thanks for your help! Yes, there is cygwin install on the computer. I now looked for the cygwin directory in system path variable, but there was only the miktex path, so I'm not sure if that is the problem or if I looked at the wrong variable. This is what's in the path variable: C:\Windows\system32 C:\Windows C:\Windows\System32\Wbem C:\Windows\System32\WindowsPowerShell\v1.0\ C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\ C:\Program Files\OpenAFS\Common C:\Program Files\OpenAFS\Client\Program C:\Program Files (x86)\OpenAFS\Common C:\Program Files (x86)\OpenAFS\Client\Program C:\Program Files (x86)\Heimdal\bin\ C:\Program Files\Heimdal\bin\ and these are the paths from LyX: $LyXDir\bin; $LyXDir\Python; $LyXDir\Python\Lib; $LyXDir\Perl\bin; $LyXDir\imagemagick; C:\Program Files (x86)\MiKTeX 2.9\miktex\tex\latex; C:\Program Files (x86)\MiKTeX 2.9\miktex\bin; C:\Program Files (x86)\Vim\vim74; C:\Program Files (x86)\LyX 2.1\ghostscript\bin Cheers, Fabian
Re: Backspacing at the start of an inset occupying a paragraph
08/06/2014 22:57, Richard Heck: I think the reason this happens is that the layout in effect in the inset becomes the layout in effect in the paragraph, if the inset is the only thing there. I'm not sure exactly why it works that way, though. This is is probably the case indeed. This makes sense when the note contains a Section environment for example. The behavior should be dependent on whether the layout is the default one or not. I have no idea of where this code lives, though. I think this deserves a bug report. JMarc
Re: How to insert a slashed o?
08/06/2014 23:01, stefano franchi: Thanks Richard, that's what I did, eventually (cutting and pasting). I was just hoping there'd be a function I could bind to a shortcut, but apparently not. Try unicode-insert 0x00F8. JMarc
paper accepted for publication, but need help!
Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: paper accepted for publication, but need help!
I guess, if you take out the ref: Vazquez-Castro, and A.~Morello the error is gone. Check carefully the reference, perhaps by adding parts only (eg only the first word of the title, journal etc) Wolfgang Am 10.06.2014 13:35, schrieb Neal Becker: Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: paper accepted for publication, but need help!
The problem is triggered by my .bib entry, which includes a non-ascii character: author = {Wojciech Bruzda and Wojciech Tadej and Karol Życzkowski}, By playing with lyx Document/Settings/Encoding, selecting unicode XeTeX (utf-8), I seem to be able to export dvi and then convert dvipdf OK. So is this a good procedure, or is something else recommended here? Neal Becker wrote: Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H return for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: [Feature Request] python binding
Alex, This did not work for me. I can run the python script from the command line and it does produce a .png output. So I know the script is working. But, in LyX 2.0.1 which I'm using, I get Error converting to loadable format. I am trying to debug it. Not sure at this point why it does not convert inside LyX. I double checked the file format is defined and also the converter is defined correctly. I will try to turn on a log file to see if there are some other diagnostic messages. Phil On 6/2/2014 1:25 PM, Alex Vergara Gil wrote: This might work!! Thanks for the suggestions, I will try it extensively and I will comments my experiences afterwards. It seems it also renders the graphic inside LyX itself! That's what I was talking about. Regards Alex - Original Message - From: Rainer M Krug rai...@krugs.de To: Alex Vergara Gil a...@cphr.edu.cu Cc: Richard Heck rgh...@lyx.org; lyx-users Users lyx-users@lists.lyx.org; lyx-de...@lists.lyx.org Sent: Monday, June 02, 2014 8:31 AM Subject: Re: [Feature Request] python binding I just add comments inline Let's see if I understand: -1. You define a *file type* in LyX under Preferences File Handling File Formats for the file type .pygr in which Vector graphics format is ticked! 0. You define a converter under Preferences File Handling Converters which calls a script which executed files with the extension .pygr and generates, as you suggest below, an svg. 1. I wrote a python script that produces the graphic I want Exactly - and you give it a specific extension .pygr for python script which generates a graphic which you defined above. 2. I insert it in LyX somehow I don't know, perhaps defining a converter from .py to svg, but this needs to be inside a module or every python script in LyX will try to be converted into a svg!! So a module is also needed Use insert graphic and select *your .pygr* file as graphic - and Lyx will do the rest of the conversion - i.e. use your converter to convert the .pygr to an svg and other existing converters to generate the png for the preview and the pdf / eps / ... for the final copmpilation of the document. 3. LyX is the one who knows the correct size of the graphic so in principle if I produce a svg should be enough but in this way I need to produce a new svg every time the data change Correct - if the input data changes, you have to generate the graph again manually, or, if the Converter file cache is disabled, you just have to close the document and open it again. Hope this helps, Rainer
Re: paper accepted for publication, but need help!
10/06/2014 13:49, Neal Becker: The problem is triggered by my .bib entry, which includes a non-ascii character: author = {Wojciech Bruzda and Wojciech Tadej and Karol Życzkowski}, By playing with lyx Document/Settings/Encoding, selecting unicode XeTeX (utf-8), I seem to be able to export dvi and then convert dvipdf OK. So is this a good procedure, or is something else recommended here? You should use the same encoding for your document and the LyX output encoding. A workaround is to use LaTeX markup in the .bib file so that it is compatible with any encoding. JMarc
Re: Insets that don't mess up text flow.
Thanks for the tip! While not what I intended, it indeed results in much less intrusive multi-line footnotes, especially when combined with Richard Heck's local layout. - Klaus 2014-05-27 16:42 GMT+02:00 Liviu Andronic landronim...@gmail.com: On Tue, May 27, 2014 at 3:19 PM, Klaus-Dieter Bauer klaus-dieter.ba...@jku.at wrote: Hello! When creating a lengthy footnote and not folding it (Ctrl+I), it will invariably mess up the text-flow, causing the last line before the footnote to be stretched to paragraph width regardless of contents. I sometimes End up with situations like Maybe this can help: http://wiki.lyx.org/LyX.NewInLyX21#misc Users can now decide for every document in the menu Document→Settings→Text Layout if LyX justifies the document text or not. (This setting has no effect on the output.) Liviu : Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext Sampletext Sampletext : Sample ~ H U G E E M P T Y S P A C E ~ Text : [foot1] : |Here is the footnote text that goes over : |several lines, just because. : +-- : RestOfPar RestOfPar RestOfPar RestOfPar : RestOfPar RestOfPar RestOfPar RestOfPar : RestOfPar RestOfPar. Yet the footnote may contain information that, while not important enough to clutter the output text, may be important enough for me not to fold the footnote away. Would it be possible to get with custom formats either 1. Footnotes that look like normal text, except for a different formatting, i.e. : Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext [foot1][Foot Foot Foot : Foot Foot Foot Foot Foot Foot Foot Foot] Rest : OfPar RestOfPar RestOfPar. 2. Footnotes to show the beginning of the text, like ERT does, i.e. : Sampletext Sampletext Sampletext Sampletext Sampletext : Sampletext Sampletext [foot1][This is the footn...] : RestOfPar RestOfPar RestOfPar. - Klaus -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: Python Graphics in LyX [was: Python bindings]
Dear all I have rewritten a little the procedure using recommendations from several users that doesn´t understand the original one. I hope this time everyone can understand the procedure. Regards Alex - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Tuesday, June 10, 2014 2:56 AM Subject: Re: Python Graphics in LyX [was: Python bindings] I retryed again and now got the PythonGraphicsLyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of viewpdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H return for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang __ Información de ESET NOD32 Antivirus, versión de la base de firmas de virus 9900 (20140605) __ ESET NOD32 Antivirus ha comprobado este mensaje. http://www.eset.com Python Graphics.lyx Description: Binary data
Re: Inserting text (instead of graphics) from code into LyX?
- Original Message - From: Rainer M Krug rai...@krugs.de Sent: Tuesday, June 10, 2014 3:26 AM Hi In the thread Python Graphics in LyX it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer Indeed! It can be produced as well, just define a python normal text file format type (as pytxt) and in the converter just add from the pytxt format to simple text format as python $$i $$o in the python script you have to output everything to a text file using the lines import sys outputfile = open(sys.argv[1]) outputfile.write('testing') outputfile.close Voilá! it works with text too Moreover in the converter you can define a csv output format and python handles well with csv, so I give you the rod, now fish something ;) Cheers, Alex
Re: Inserting text (instead of graphics) from code into LyX?
Alex Vergara Gil a...@cphr.edu.cu writes: - Original Message - From: Rainer M Krug rai...@krugs.de Sent: Tuesday, June 10, 2014 3:26 AM Hi In the thread Python Graphics in LyX it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer Indeed! It can be produced as well, just define a python normal text file format type (as pytxt) and in the converter just add from the pytxt format to simple text format as python $$i $$o in the python script you have to output everything to a text file using the lines import sys outputfile = open(sys.argv[1]) outputfile.write('testing') outputfile.close Voilá! it works with text too Moreover in the converter you can define a csv output format and python handles well with csv, so I give you the rod, now fish something ;) As I said - I have missed something trivial. Suggestion: could you add these cases to your document about graphs from Python? Especially the csv might be very useful. Cheers, Rainer Cheers, Alex -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpfDFEEurWzn.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
Better than ever I've found that the pandas package in python handles with excel files and produces tables in csv too, so it can be used to read excel files as input, process a little and output csv tables which can be read by LyX as external documents (child) The panorama becomes interesting! Alex
Re: reconfiguration fails (miktex)
Fabian Wilde fabian.wilde at icloud.com writes: Paul A. Rubin rubin at msu.edu writes: I don't have ready access to a Windows partition with LyX 2.1 any more, so I'm winging this a bit. I noticed your path to lyx.exe contained cygdrive: $ /cygdrive/c/Program\ Files\ \(x86\)/LyX\ 2.1/bin/lyx.exe -x reconfigure By any chance does that mean you have LyX installed on a machine running Cygwin? Years ago I had problems with reconfiguring LyX because Cygwin had a (broken, as I recall) version of latex that appeared on the command path ahead of the MiKTeX version. If that's the case for you, moving MiKTeX's bin directory ahead of the Cygwin bin directory on the system command path might help. (I would put LyX's bin directory ahead of Cygwin's as well.) Paul Hi Paul, thanks for your help! Yes, there is cygwin install on the computer. I now looked for the cygwin directory in system path variable, but there was only the miktex path, so I'm not sure if that is the problem or if I looked at the wrong variable. This is what's in the path variable: C:\Windows\system32 C:\Windows C:\Windows\System32\Wbem C:\Windows\System32\WindowsPowerShell\v1.0\ C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\ C:\Program Files\OpenAFS\Common C:\Program Files\OpenAFS\Client\Program C:\Program Files (x86)\OpenAFS\Common C:\Program Files (x86)\OpenAFS\Client\Program C:\Program Files (x86)\Heimdal\bin\ C:\Program Files\Heimdal\bin\ and these are the paths from LyX: $LyXDir\bin; $LyXDir\Python; $LyXDir\Python\Lib; $LyXDir\Perl\bin; $LyXDir\imagemagick; C:\Program Files (x86)\MiKTeX 2.9\miktex\tex\latex; C:\Program Files (x86)\MiKTeX 2.9\miktex\bin; C:\Program Files (x86)\Vim\vim74; C:\Program Files (x86)\LyX 2.1\ghostscript\bin Cheers, Fabian Hi Paul and everyone! I found the solution to my problem on the LyX troubleshoot wiki. I had a problem with an UNC path. Here is a copy of the solution: LyX does not start and gives the error message: unable to find textclass file This problem may come into existence if you use LyX on a windows-pc where your windows/application profile is not stored local but on an UNC path (i.e. \\Username\Applications\LyX). One solution I have found is the following: Uninstall LyX from your PC if you have used an installation folder whose name exists of seperate words like C:\Program Files. Reinstall LyX and consider, that you use a folder whose name exists of just one word like C:\Lyx15 Start the Command Prompt in windows (Start - All Programs - Accessories - Command Prompt) Change directory to C:\ (type c:) Type c:/lyx15/python/python.exe c:/lyx15/resources/configure.py in the Command Prompt and press return After the configuration has been finished you will find 4 files in the directory c:\ - configure.log, lyxrc.defaults, textclass.lst and packages.lst Cut these 4 files and paste them into the \\Username\Application Data\LyX folder. If a directory for Lyx does not exist create a new one. Start Lyx The problem can arise even if you do not use a UNC path for the windows profile. In this case steps 5-8 are sufficient and can be carried out using the default Program Files location. Sorry for troubling you and again thanks for your help! Cheers, Fabian
Re: Inserting text (instead of graphics) from code into LyX?
Alex Vergara Gil a...@cphr.edu.cu writes: - Original Message - From: Rainer M Krug rai...@krugs.de Sent: Tuesday, June 10, 2014 8:39 AM As I said - I have missed something trivial. Suggestion: could you add these cases to your document about graphs from Python? Especially the csv might be very useful. Cheers, Rainer I see, you have to insert them as external files, like they were child documents! LyX will try to open them and in the process they will be converted But then it is inserted statically - this is not what I was thinking about. I guess the approach to use would be to use the external Material approach - but for this, one would have to define a new type. Or is there a way of dynamically linking a non-LyX or LaTeX file into a LyX document, preferably with preview? Cheers, Rainer Alex -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpqznLyv_flf.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
Alex Vergara Gil a...@cphr.edu.cu writes: Better than ever I've found that the pandas package in python handles with excel files and produces tables in csv too, so it can be used to read excel files as input, process a little and output csv tables which can be read by LyX as external documents (child) The panorama becomes interesting! OK - spreadsheets work via the external documents. But have you found a way of including normal txt files as verbatim? One could always use good old ert (e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=verbfile) But this would not provide preview. Rainer Alex -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpcbPC3_TwLk.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
- Original Message - From: Rainer M Krug Sent: Tuesday, June 10, 2014 9:09 AM OK - spreadsheets work via the external documents. But have you found a way of including normal txt files as verbatim? One could always use good old ert (e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=verbfile) But this would not provide preview. Rainer No, no preview in the case of text I fear. It should be implemented in the LyX code. Developers should handle this kind of things, if they already support image preview, why not supporting external material preview as well? They should answer this. TAIK! Cheers Alex
pick out all graphics from a lyx file?
Anyone know an easy way to pick out all the pdfs that are included in my lyx file? Before you answer, some are multipage pdfs, and are included using page=option. I want to just pick the correct pages of those.
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 4:54 PM, Neal Becker ndbeck...@gmail.com wrote: Anyone know an easy way to pick out all the pdfs that are included in my lyx file? Try to export to archive bundle, and then check what was included in there. LyX should collect all files necessary for the compilation. Liviu Before you answer, some are multipage pdfs, and are included using page=option. I want to just pick the correct pages of those. -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: pick out all graphics from a lyx file?
Liviu Andronic wrote: On Tue, Jun 10, 2014 at 4:54 PM, Neal Becker ndbeck...@gmail.com wrote: Anyone know an easy way to pick out all the pdfs that are included in my lyx file? Try to export to archive bundle, and then check what was included in there. LyX should collect all files necessary for the compilation. Liviu Before you answer, some are multipage pdfs, and are included using page=option. I want to just pick the correct pages of those. Helpful, but does not pick out a page from a multi-page pdf
Re: How to include child documents in Lyx
On Mon, Jun 9, 2014 at 1:46 PM, umair durrani umairdurr...@outlook.com wrote: I have asked this question on tex.stackexchange but got no answer so far. I am new to LaTeX and LyX. For writing my thesis I got 2 files from university: uw_masters_thesis.sty and sample_thesis.tex. The sample file contains \usepackage{uw_masters_thesis} in preamble. If I use LaTex I simply put both files in same directory and include child documents by using \include or \input in the sample_thesis.tex document. The embedded objects manual in LyX suggests to specify the Document Class of master document in child document. But in my case the document class is Report (Standard Class). In my understanding, what uses the style file is the \usepackage{uw_masters_thesis} in preamble. I am creating thesis chapters (child documents) in lyx without specifying any thing in Document Stettings. I want them to use the style provided by .sty file and finally include all of them in master document. How can I achieve this in Lyx. Please suggest a step by step solution. It's a little bit tough to provide a step-by-step solution because I'm not sure you've described your problem completely enough. Nonetheless, I will make some assumptions and do my best. From the title of your message, you appear to be asking about how to include child documents in LyX. I will answer that first, but I don't think that is actually the main problem you are having. I think the main problem you are having has to do with creating a layout file for your thesis template. *How to include child documents in LyX:* This is described in Section 7.2 of the Embedded Objects manual. 1. Go to insert-File-Child Documents. If you select include, then this will do the same as the LaTeX \include, and if you choose \input, it will do the same as the LaTeX \input which you mentioned above. 2. Select the same document class for child documents as the master document. To do this, go to Document-Settings-Document Class, and select the appropriate document class. Please do NOT use your university template when attempting this for the first time. Use one of the built-in classes, like the default article class. If you've got that working fine, then the problem does not lie in the inclusion of child documents, but in the use of your custom class file. I sense that's your real problem. *How to get your custom university thesis template to work:* This has been asked here before, and I will answer specific questions once you read the previous posts and wiki on how to do that. The wiki page on this can be found at: http://wiki.lyx.org/Examples/Thesis One recent post from the mailing list is: http://thread.gmane.org/gmane.editors.lyx.general/82099 Good luck, and please check back after trying the above. -Jacob
Re: How to include child documents in Lyx
*How to get your custom university thesis template to work:* This has been asked here before, and I will answer specific questions once you read the previous posts and wiki on how to do that. The wiki page on this can be found at: http://wiki.lyx.org/Examples/Thesis One recent post from the mailing list is: http://thread.gmane.org/gmane.editors.lyx.general/82099 Good luck, and please check back after trying the above. I have one additional reference, and a correction to what I wrote previously. The above link to the wiki is a list of example thesis templates, not how to create one. The link for how to create a custom layout from an existing style file is: http://wiki.lyx.org/Layouts/CreatingLayouts -Jacob
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 11:35 AM, Neal Becker ndbeck...@gmail.com wrote: Helpful, but does not pick out a page from a multi-page pdf If you want to export a single page from a multi-page pdf then one possibility is to use a .pdf split/merge program such as pdfsam ( http://www.pdfsam.org/ ) or pdftk ( http://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/ ). I have nothing to do with either them, I just use those programs sometimes to get just what I need from a multipage pdf, and it's convenient for me since both are in the package repositories for my OS. pdfsam has a graphical interface, whereas pdftk is commandline only as far as I know. This isn't a very elegant or completely automated solution based on the LyX file which sounds like what you are really looking for, but it's the best way I am aware of. I hope this helps. Jacob
Re: Python Graphics in LyX [was: Python bindings]
Am 10.06.2014 15:52, schrieb Alex Vergara Gil: Thanks, Alex, for the new lyx file. I now realized, that I had to load the matplotlib and pandas packages, which I did. I followed your advices Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Define a new converter from the format Python graphics to the format EPS as ... After reconfigure (necessary?) and making sure the two example graphics (in pygr format) are found in the path I get this error LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.eps' not found on input line 83. Why is it expecting an eps file instead of taking the pygr files? What am I missing? Wolfgang Dear all I have rewritten a little the procedure using recommendations from several users that doesn´t understand the original one. I hope this time everyone can understand the procedure. Regards Alex - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Tuesday, June 10, 2014 2:56 AM Subject: Re: Python Graphics in LyX [was: Python bindings] I retryed again and now got the PythonGraphicsLyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of viewpdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H return for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?-- Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang __ Información de ESET NOD32 Antivirus, versión de la base de firmas de virus 9900 (20140605) __ ESET NOD32 Antivirus ha comprobado este mensaje. http://www.eset.com
Re: Python Graphics in LyX [was: Python bindings]
- Original Message - From: Wolfgang Engelmann Sent: Tuesday, June 10, 2014 2:19 PM Thanks, Alex, for the new lyx file. I now realized, that I had to load the matplotlib and pandas packages, which I did. I followed your advices Define a new file format in toolspreferences, name it Python graphics, extension pygr and vector image format ticked Define a new converter from the format Python graphics to the format EPS as ... After reconfigure (necessary?) and making sure the two example graphics (in pygr format) are found in the path I get this error No, reconfigure is not necessary LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.eps' not found on input line 83. Why is it expecting an eps file instead of taking the pygr files? indeed a eps file is expected What am I missing? Wolfgang Did you can see the graphic within LyX? Did LyX display it correctly in your system? if not the case check that the example script is located at the same path than the lyx file, another way is to click in the inserted graphic and look for the example.pygr path Another possible explanation is that your system doesn't handle with eps, in this case you should change the definition and instead of eps, put pdf or png as final format, whichever work for you, you can check that because it will display the graphic within LyX even before you export anything! Regards Alex
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 7:35 PM, Neal Becker ndbeck...@gmail.com wrote: Helpful, but does not pick out a page from a multi-page pdf Oh, then (on Linux) I would recommend: PDF Mod: https://wiki.gnome.org/Apps/PdfMod PDF Chain: http://pdfchain.sourceforge.net/ PDF-Shuffler: http://sourceforge.net/projects/pdfshuffler/ Either of these would allow to extract individual pages from a PDF. Liviu -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: Backspacing at the start of an inset occupying a paragraph
On 10/06/2014 8:38 p.m., Jean-Marc Lasgouttes wrote: 08/06/2014 22:57, Richard Heck: I think the reason this happens is that the layout in effect in the inset becomes the layout in effect in the paragraph, if the inset is the only thing there. I'm not sure exactly why it works that way, though. This is is probably the case indeed. This makes sense when the note contains a Section environment for example. The behavior should be dependent on whether the layout is the default one or not. I have no idea of where this code lives, though. I think this deserves a bug report. JMarc Alas, you have confused me now. I'm not sure what to report -- my original posting or something else. Since standard is the default layout, that is indeed what the inset dissolves to if it contains normal text but, having been prompted to try a section heading in a note, it dissolves into a section heading (even within a list -- I see that it is perfectly possible to put a section heading, numbered, bolded, larger type, within a list or sublist or subsublist, and have it indented accordingly). Andrew
Re: Python Graphics in LyX [was: Python bindings]
Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?--> Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in tools>preferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang
Re: Python Graphics in LyX [was: Python bindings]
I retryed again and now got the PythonGraphics>LyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of view>pdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?--> Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in tools>preferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang
Re: Python Graphics in LyX [was: Python bindings]
"Alex Vergara Gil"writes: > Dear Lyxers! > > Studying a little of python and LyX I have reached to this feature > that makes LyX show and process python graphics. Thanks to Rainer M > Krug for the hints. I share this contribution for LyX under LGPL > license, so everyone benefits from it. Good luck and happy lyxing! > > Alex Vergara Gil > MSc Nuclear Physics > SSDL, CPHR, Havana Cuba > > PS: If Rainer agree, pass him from acknowledgements to author list, please. That looks beautiful. AS I have no idea how python works, co-author would probably better. Thanks, Rainer > > > > -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgphSDFfXP5gr.pgp Description: PGP signature
Re: Python Graphics in LyX [was: Python bindings]
Murat Yildizogluwrites: > Thanks Alex, > That opens new and nice perspectives. > > I have just thought about another possibility: Since the Sage software > uses Python as a glue, it must be also possible to use the Sage module > for LyX to make computations in Python in Sage and include the results > in the final PDF file. There are numerous possibilities using converters like this - ranging From simple scripts (one can also call R like this if one does not need a single session and only wants to do simple graphs), to calling complex simulations... whatever produces graphs. Actually not only graphs, also text, e.g. tables generated should work with the correct export format? Alex - I think it would be a good idea to add this to the LyX wiki. Cheers, Rainer > That reminds me that I should check the Sage module for the last > version of Lyx (have not had any time to look at it yet). > > Best regards, > > Murat > > Alex Vergara Gil a écrit : > > Dear Lyxers! > > Studying a little of python and LyX I have reached to this feature > that makes LyX show and process python graphics. Thanks to Rainer > M Krug for the hints. I share this contribution for LyX under LGPL > license, so everyone benefits from it. Good luck and happy lyxing! > > Alex Vergara Gil > MSc Nuclear Physics > SSDL, CPHR, Havana Cuba > > PS: If Rainer agree, pass him from acknowledgements to author list, > please. > > -- > Universite' de Bordeaux CNRS > > Prof. Murat Yildizoglu > > GREThA (UMR CNRS 5113) > UNIVERSITE DE BORDEAUX > GREThA (UMR CNRS 5113) > MURAT YILDIZOGLU > 16 AVENUE LEON DUGUIT > CS 50057 > 33608 PESSAC CEDEX > FRANCE > > Bureau : E-331 > > yildizoglu.info > -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpBotkKNuSAc.pgp Description: PGP signature
Inserting text (instead of graphics) from code into LyX?
Hi In the thread "Python Graphics in LyX" it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpVGQSRoC0nx.pgp Description: PGP signature
Re: reconfiguration fails (miktex)
Paul A. Rubin msu.edu> writes: > > I don't have ready access to a Windows partition with LyX 2.1 any more, so > I'm winging this a bit. I noticed your path to lyx.exe contained "cygdrive": > > > $ /cygdrive/c/Program\ Files\ \(x86\)/LyX\ 2.1/bin/lyx.exe -x reconfigure > > By any chance does that mean you have LyX installed on a machine running > Cygwin? Years ago I had problems with reconfiguring LyX because Cygwin had a > (broken, as I recall) version of latex that appeared on the command path > ahead of the MiKTeX version. If that's the case for you, moving MiKTeX's bin > directory ahead of the Cygwin bin directory on the system command path might > help. (I would put LyX's bin directory ahead of Cygwin's as well.) > > Paul > > Hi Paul, thanks for your help! Yes, there is cygwin install on the computer. I now looked for the cygwin directory in system path variable, but there was only the miktex path, so I'm not sure if that is the problem or if I looked at the wrong variable. This is what's in the path variable: C:\Windows\system32 C:\Windows C:\Windows\System32\Wbem C:\Windows\System32\WindowsPowerShell\v1.0\ C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\ C:\Program Files\OpenAFS\Common C:\Program Files\OpenAFS\Client\Program C:\Program Files (x86)\OpenAFS\Common C:\Program Files (x86)\OpenAFS\Client\Program C:\Program Files (x86)\Heimdal\bin\ C:\Program Files\Heimdal\bin\ and these are the paths from LyX: $LyXDir\bin; $LyXDir\Python; $LyXDir\Python\Lib; $LyXDir\Perl\bin; $LyXDir\imagemagick; C:\Program Files (x86)\MiKTeX 2.9\miktex\tex\latex; C:\Program Files (x86)\MiKTeX 2.9\miktex\bin; C:\Program Files (x86)\Vim\vim74; C:\Program Files (x86)\LyX 2.1\ghostscript\bin Cheers, Fabian
Re: Backspacing at the start of an inset occupying a paragraph
08/06/2014 22:57, Richard Heck: I think the reason this happens is that the layout in effect in the inset becomes the layout in effect in the paragraph, if the inset is the only thing there. I'm not sure exactly why it works that way, though. This is is probably the case indeed. This makes sense when the note contains a Section environment for example. The behavior should be dependent on whether the layout is the default one or not. I have no idea of where this code lives, though. I think this deserves a bug report. JMarc
Re: How to insert a slashed o?
08/06/2014 23:01, stefano franchi: Thanks Richard, that's what I did, eventually (cutting and pasting). I was just hoping there'd be a function I could bind to a shortcut, but apparently not. Try "unicode-insert 0x00F8". JMarc
paper accepted for publication, but need help!
Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: paper accepted for publication, but need help!
I guess, if you take out the ref: Vazquez-Castro, and A.~Morello the error is gone. Check carefully the reference, perhaps by adding parts only (eg only the first word of the title, journal etc) Wolfgang Am 10.06.2014 13:35, schrieb Neal Becker: Submitting to IEEE conf. They accept TeX. If I try to give them the TeX output, they say they need dvi, and all figures in eps (what is this, 1980??) If I try to export to dvi from lyx, I get: --- ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H for immediate help. ... l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� �S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. ! Package inputenc Error: Keyboard character used is undefined (inputenc)in inputencoding `latin9'. See the inputenc package documentation for explanation. Type H for immediate help. ... l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ S2 ACM} modes for You need to provide a definition with \DeclareInputText or \DeclareInputMath before using this key. -- If I select dvi (LuaTeX) export, lyx does not complain. But then if I test the dvi myself, I get: dvipdf vhtpaper.dvi dvips: ! invalid char 8208 from font ec-lmr8
Re: paper accepted for publication, but need help!
The problem is triggered by my .bib entry, which includes a non-ascii character: author = {Wojciech Bruzda and Wojciech Tadej and Karol Życzkowski}, By playing with lyx Document/Settings/Encoding, selecting unicode XeTeX (utf-8), I seem to be able to export dvi and then convert dvipdf OK. So is this a "good" procedure, or is something else recommended here? Neal Becker wrote: > Submitting to IEEE conf. They accept TeX. > > If I try to give them the TeX output, they say they need dvi, and > all figures in eps (what is this, 1980??) > > If I try to export to dvi from lyx, I get: > > --- > ! Package inputenc Error: Keyboard character used is undefined > (inputenc)in inputencoding `latin9'. > > See the inputenc package documentation for explanation. > Type H for immediate help. > ... > > l.13 Vazquez-Castro, and A.~Morello, ``{DVB�� > �S2 ACM} modes for > You need to provide a definition with \DeclareInputText > or \DeclareInputMath before using this key. > > > ! Package inputenc Error: Keyboard character used is undefined > (inputenc)in inputencoding `latin9'. > > See the inputenc package documentation for explanation. > Type H for immediate help. > ... > > l.13 ... Vazquez-Castro, and A.~Morello, ``{DVB‐ > S2 ACM} modes for > You need to provide a definition with \DeclareInputText > or \DeclareInputMath before using this key. > -- > > If I select dvi (LuaTeX) export, lyx does not complain. But then if I test > the dvi myself, I get: > > dvipdf vhtpaper.dvi > dvips: ! invalid char 8208 from font ec-lmr8
Re: [Feature Request] python binding
Alex, This did not work for me. I can run the python script from the command line and it does produce a .png output. So I know the script is working. But, in LyX 2.0.1 which I'm using, I get "Error converting to loadable format". I am trying to debug it. Not sure at this point why it does not convert inside LyX. I double checked the file format is defined and also the converter is defined correctly. I will try to turn on a log file to see if there are some other diagnostic messages. Phil On 6/2/2014 1:25 PM, Alex Vergara Gil wrote: This might work!! Thanks for the suggestions, I will try it extensively and I will comments my experiences afterwards. It seems it also renders the graphic inside LyX itself! That's what I was talking about. Regards Alex - Original Message - From: "Rainer M Krug"To: "Alex Vergara Gil" Cc: "Richard Heck" ; "lyx-users Users" ; Sent: Monday, June 02, 2014 8:31 AM Subject: Re: [Feature Request] python binding I just add comments inline Let's see if I understand: -1. You define a *file type* in LyX under Preferences > File Handling > File Formats for the file type .pygr in which "Vector graphics format" is ticked! 0. You define a converter under Preferences > File Handling > Converters which calls a script which executed files with the extension .pygr and generates, as you suggest below, an svg. 1. I wrote a python script that produces the graphic I want Exactly - and you give it a specific extension .pygr for "python script which generates a graphic" which you defined above. 2. I insert it in LyX somehow I don't know, perhaps defining a converter from .py to svg, but this needs to be inside a module or every python script in LyX will try to be converted into a svg!! So a module is also needed Use insert graphic and select *your .pygr* file as graphic - and Lyx will do the rest of the conversion - i.e. use your converter to convert the .pygr to an svg and other existing converters to generate the png for the preview and the pdf / eps / ... for the final copmpilation of the document. 3. LyX is the one who knows the correct size of the graphic so in principle if I produce a svg should be enough but in this way I need to produce a new svg every time the data change Correct - if the input data changes, you have to generate the graph again manually, or, if the "Converter file cache" is disabled, you just have to close the document and open it again. Hope this helps, Rainer
Re: paper accepted for publication, but need help!
10/06/2014 13:49, Neal Becker: The problem is triggered by my .bib entry, which includes a non-ascii character: author = {Wojciech Bruzda and Wojciech Tadej and Karol Życzkowski}, By playing with lyx Document/Settings/Encoding, selecting unicode XeTeX (utf-8), I seem to be able to export dvi and then convert dvipdf OK. So is this a "good" procedure, or is something else recommended here? You should use the same encoding for your document and the LyX output encoding. A workaround is to use LaTeX markup in the .bib file so that it is compatible with any encoding. JMarc
Re: Insets that don't mess up text flow.
Thanks for the tip! While not what I intended, it indeed results in much less intrusive multi-line footnotes, especially when combined with Richard Heck's local layout. - Klaus 2014-05-27 16:42 GMT+02:00 Liviu Andronic: > On Tue, May 27, 2014 at 3:19 PM, Klaus-Dieter Bauer > wrote: > > Hello! > > > > When creating a lengthy footnote and not folding it (Ctrl+I), it will > > invariably mess up the text-flow, causing the last line before the > footnote > > to be stretched to paragraph width regardless of contents. I sometimes > End > > up with situations like > > > Maybe this can help: > http://wiki.lyx.org/LyX.NewInLyX21#misc > > "Users can now decide for every document in the menu > Document→Settings→Text Layout if LyX justifies the document text or > not. (This setting has no effect on the output.)" > > Liviu > > > > > > : Sampletext Sampletext Sampletext Sampletext > > : Sampletext Sampletext Sampletext Sampletext > > : Sampletext Sampletext Sampletext Sampletext > > : Sample ~ H U G E E M P T Y S P A C E ~ Text > > : [foot1] > > : |Here is the footnote text that goes over > > : |several lines, just because. > > : +-- > > : RestOfPar RestOfPar RestOfPar RestOfPar > > : RestOfPar RestOfPar RestOfPar RestOfPar > > : RestOfPar RestOfPar. > > > > Yet the footnote may contain information that, while not important > enough to > > clutter the output text, may be important enough for me not to fold the > > footnote away. > > > > Would it be possible to get with custom formats either > > > > 1. Footnotes that look like normal text, except for a different > formatting, > > i.e. > > > > : Sampletext Sampletext Sampletext Sampletext > > : Sampletext Sampletext [foot1][Foot Foot Foot > > : Foot Foot Foot Foot Foot Foot Foot Foot] Rest > > : OfPar RestOfPar RestOfPar. > > > > 2. Footnotes to show the beginning of the text, like ERT does, i.e. > > > > : Sampletext Sampletext Sampletext Sampletext Sampletext > > : Sampletext Sampletext [foot1][This is the footn...] > > : RestOfPar RestOfPar RestOfPar. > > > > > > - Klaus > > > > > > -- > Do you know how to read? > http://www.alienetworks.com/srtest.cfm > http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader > Do you know how to write? > http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail >
Re: Python Graphics in LyX [was: Python bindings]
Dear all I have rewritten a little the procedure using recommendations from several users that doesn´t understand the original one. I hope this time everyone can understand the procedure. Regards Alex - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Tuesday, June 10, 2014 2:56 AM Subject: Re: Python Graphics in LyX [was: Python bindings] I retryed again and now got the PythonGraphics>LyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of view>pdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?--> Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in tools>preferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang __ Información de ESET NOD32 Antivirus, versión de la base de firmas de virus 9900 (20140605) __ ESET NOD32 Antivirus ha comprobado este mensaje. http://www.eset.com Python Graphics.lyx Description: Binary data
Re: Inserting text (instead of graphics) from code into LyX?
- Original Message - From: "Rainer M Krug"Sent: Tuesday, June 10, 2014 3:26 AM Hi In the thread "Python Graphics in LyX" it was shown nicely how other programming languages can be used to include grahics generated by these into a LyX Document. That made me thinking: How can I do the same for text files generated by these external code blocks? Obviously, this depends on the format of the text (ascii, LaTeX, others?). What would be the workflow? Does the text has to be in a file (I assume) or could it be redirected directly into LyX? Somehow I have the feeling I am missing something trivial here... Cheers, Rainer Indeed! It can be produced as well, just define a python normal text file format type (as pytxt) and in the converter just add from the pytxt format to simple text format as python $$i $$o in the python script you have to output everything to a text file using the lines import sys outputfile = open(sys.argv[1]) outputfile.write('testing') outputfile.close Voilá! it works with text too Moreover in the converter you can define a csv output format and python handles well with csv, so I give you the rod, now fish something ;) Cheers, Alex
Re: Inserting text (instead of graphics) from code into LyX?
"Alex Vergara Gil"writes: > - Original Message - From: "Rainer M Krug" Sent: > Tuesday, June 10, 2014 3:26 AM > > Hi > > In the thread "Python Graphics in LyX" it was shown nicely how other > programming languages can be used to include grahics generated by these > into a LyX Document. That made me thinking: How can I do the same for > text files generated by these external code blocks? > > Obviously, this depends on the format of the text (ascii, LaTeX, > others?). What would be the workflow? Does the text has to be in a file > (I assume) or could it be redirected directly into LyX? > > Somehow I have the feeling I am missing something trivial here... > > Cheers, > > Rainer > Indeed! It can be produced as well, just define a python normal text > file format type (as pytxt) and in the converter just add from the > pytxt format to simple text format as python $$i $$o > in the python script you have to output everything to a text file using the > lines > import sys > outputfile = open(sys.argv[1]) > outputfile.write('testing') > outputfile.close > > Voilá! it works with text too > Moreover in the converter you can define a csv output format and > python handles well with csv, so I give you the rod, now fish > something ;) As I said - I have missed something trivial. Suggestion: could you add these cases to your document about graphs from Python? Especially the csv might be very useful. Cheers, Rainer > > Cheers, Alex -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpfDFEEurWzn.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
Better than ever I've found that the pandas package in python handles with excel files and produces tables in csv too, so it can be used to read excel files as input, process a little and output csv tables which can be read by LyX as external documents (child) The panorama becomes interesting! Alex
Re: reconfiguration fails (miktex)
Fabian Wilde icloud.com> writes: > > Paul A. Rubin msu.edu> writes: > > > > > I don't have ready access to a Windows partition with LyX 2.1 any more, so > > I'm winging this a bit. I noticed your path to lyx.exe contained "cygdrive": > > > > > $ /cygdrive/c/Program\ Files\ \(x86\)/LyX\ 2.1/bin/lyx.exe -x reconfigure > > > > By any chance does that mean you have LyX installed on a machine running > > Cygwin? Years ago I had problems with reconfiguring LyX because Cygwin had a > > (broken, as I recall) version of latex that appeared on the command path > > ahead of the MiKTeX version. If that's the case for you, moving MiKTeX's bin > > directory ahead of the Cygwin bin directory on the system command path might > > help. (I would put LyX's bin directory ahead of Cygwin's as well.) > > > > Paul > > > > > Hi Paul, > > thanks for your help! Yes, there is cygwin install on the computer. I now > looked for the cygwin directory in system path variable, but there was only > the miktex path, so I'm not sure if that is the problem or if I looked at > the wrong variable. This is what's in the path variable: > > C:\Windows\system32 > C:\Windows > C:\Windows\System32\Wbem > C:\Windows\System32\WindowsPowerShell\v1.0\ > C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\ > C:\Program Files\OpenAFS\Common > C:\Program Files\OpenAFS\Client\Program > C:\Program Files (x86)\OpenAFS\Common > C:\Program Files (x86)\OpenAFS\Client\Program > C:\Program Files (x86)\Heimdal\bin\ > C:\Program Files\Heimdal\bin\ > > and these are the paths from LyX: > > $LyXDir\bin; > $LyXDir\Python; > $LyXDir\Python\Lib; > $LyXDir\Perl\bin; > $LyXDir\imagemagick; > C:\Program Files (x86)\MiKTeX 2.9\miktex\tex\latex; > C:\Program Files (x86)\MiKTeX 2.9\miktex\bin; > C:\Program Files (x86)\Vim\vim74; > C:\Program Files (x86)\LyX 2.1\ghostscript\bin > > Cheers, > Fabian > > Hi Paul and everyone! I found the solution to my problem on the LyX troubleshoot wiki. I had a problem with an UNC path. Here is a copy of the solution: LyX does not start and gives the error message: unable to find textclass file This problem may come into existence if you use LyX on a windows-pc where your windows/application profile is not stored local but on an UNC path (i.e. \\Username\Applications\LyX). One solution I have found is the following: Uninstall LyX from your PC if you have used an installation folder whose name exists of seperate words like C:\Program Files. Reinstall LyX and consider, that you use a folder whose name exists of just one word like C:\Lyx15 Start the Command Prompt in windows (Start -> All Programs -> Accessories -> Command Prompt) Change directory to C:\ (type c:) Type "c:/lyx15/python/python.exe c:/lyx15/resources/configure.py" in the Command Prompt and press "return" After the configuration has been finished you will find 4 files in the directory c:\ -> configure.log, lyxrc.defaults, textclass.lst and packages.lst Cut these 4 files and paste them into the \\Username\Application Data\LyX folder. If a directory for Lyx does not exist create a new one. Start Lyx The problem can arise even if you do not use a UNC path for the windows profile. In this case steps 5-8 are sufficient and can be carried out using the default Program Files location. Sorry for troubling you and again thanks for your help! Cheers, Fabian
Re: Inserting text (instead of graphics) from code into LyX?
"Alex Vergara Gil"writes: > - Original Message - From: "Rainer M Krug" Sent: > Tuesday, June 10, 2014 8:39 AM > > As I said - I have missed something trivial. > > Suggestion: could you add these cases to your document about graphs from > Python? Especially the csv might be very useful. > > Cheers, > > Rainer > I see, you have to insert them as external files, like they were child > documents! LyX will try to open them and in the process they will be > converted But then it is inserted statically - this is not what I was thinking about. I guess the approach to use would be to use the "external Material" approach - but for this, one would have to define a new type. Or is there a way of dynamically linking a non-LyX or LaTeX file into a LyX document, preferably with preview? Cheers, Rainer > > Alex > -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpqznLyv_flf.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
"Alex Vergara Gil"writes: > Better than ever > I've found that the pandas package in python handles with excel files > and produces tables in csv too, so it can be used to read excel files > as input, process a little and output csv tables which can be read by > LyX as external documents (child) > The panorama becomes interesting! OK - spreadsheets work via the "external documents". But have you found a way of including "normal" txt files as verbatim? One could always use good old ert (e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=verbfile) But this would not provide preview. Rainer > Alex > > -- Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D):+49 - (0)3 21 21 25 22 44 email: rai...@krugs.de Skype: RMkrug PGP: 0x0F52F982 pgpcbPC3_TwLk.pgp Description: PGP signature
Re: Inserting text (instead of graphics) from code into LyX?
- Original Message - From: "Rainer M Krug" Sent: Tuesday, June 10, 2014 9:09 AM OK - spreadsheets work via the "external documents". But have you found a way of including "normal" txt files as verbatim? One could always use good old ert (e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=verbfile) But this would not provide preview. Rainer No, no preview in the case of text I fear. It should be implemented in the LyX code. Developers should handle this kind of things, if they already support image preview, why not supporting external material preview as well? They should answer this. TAIK! Cheers Alex
pick out all graphics from a lyx file?
Anyone know an easy way to pick out all the pdfs that are included in my lyx file? Before you answer, some are multipage pdfs, and are included using page=option. I want to just pick the correct pages of those.
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 4:54 PM, Neal Beckerwrote: > Anyone know an easy way to pick out all the pdfs that are included in my lyx > file? > Try to export to archive bundle, and then check what was included in there. LyX should collect all files necessary for the compilation. Liviu > Before you answer, some are multipage pdfs, and are included using > page=option. > I want to just pick the correct pages of those. > -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: pick out all graphics from a lyx file?
Liviu Andronic wrote: > On Tue, Jun 10, 2014 at 4:54 PM, Neal Beckerwrote: >> Anyone know an easy way to pick out all the pdfs that are included in my lyx >> file? >> > Try to export to archive bundle, and then check what was included in > there. LyX should collect all files necessary for the compilation. > > Liviu > > > > >> Before you answer, some are multipage pdfs, and are included using >> page=option. I want to just pick the correct pages of those. >> > > > Helpful, but does not pick out a page from a multi-page pdf
Re: How to include child documents in Lyx
On Mon, Jun 9, 2014 at 1:46 PM, umair durraniwrote: > I have asked this question on tex.stackexchange but got no answer so far. I > am new to LaTeX and LyX. For writing my thesis I got 2 files from > university: uw_masters_thesis.sty and sample_thesis.tex. The sample file > contains \usepackage{uw_masters_thesis} in preamble. If I use LaTex I > simply put both files in same directory and include child documents by > using \include or \input in the sample_thesis.tex document. > The embedded objects manual in LyX suggests to specify the Document Class of > master document in child document. But in my case the document class is Report > (Standard Class). In my understanding, what uses the style file is the > \usepackage{uw_masters_thesis} in preamble. > I am creating thesis chapters (child documents) in lyx without specifying > any thing in Document Stettings. I want them to use the style provided by > .sty file and finally include all of them in master document. How can I > achieve this in Lyx. Please suggest a step by step solution. > It's a little bit tough to provide a step-by-step solution because I'm not sure you've described your problem completely enough. Nonetheless, I will make some assumptions and do my best. From the title of your message, you appear to be asking about how to include child documents in LyX. I will answer that first, but I don't think that is actually the main problem you are having. I think the main problem you are having has to do with creating a layout file for your thesis template. *How to include child documents in LyX:* This is described in Section 7.2 of the Embedded Objects manual. 1. Go to insert->File->Child Documents. If you select "include", then this will do the same as the LaTeX \include, and if you choose \input, it will do the same as the LaTeX \input which you mentioned above. 2. Select the same document class for child documents as the master document. To do this, go to Document->Settings->Document Class, and select the appropriate document class. Please do NOT use your university template when attempting this for the first time. Use one of the built-in classes, like the default article class. If you've got that working fine, then the problem does not lie in the inclusion of child documents, but in the use of your custom class file. I sense that's your real problem. *How to get your custom university thesis template to work:* This has been asked here before, and I will answer specific questions once you read the previous posts and wiki on how to do that. The wiki page on this can be found at: http://wiki.lyx.org/Examples/Thesis One recent post from the mailing list is: http://thread.gmane.org/gmane.editors.lyx.general/82099 Good luck, and please check back after trying the above. -Jacob
Re: How to include child documents in Lyx
*How to get your custom university thesis template to work:* > > This has been asked here before, and I will answer specific questions once > you read the previous posts and wiki on how to do that. The wiki page on > this can be found at: > http://wiki.lyx.org/Examples/Thesis > One recent post from the mailing list is: > http://thread.gmane.org/gmane.editors.lyx.general/82099 > > Good luck, and please check back after trying the above. > I have one additional reference, and a correction to what I wrote previously. The above link to the wiki is a list of example thesis templates, not how to create one. The link for how to create a custom layout from an existing style file is: http://wiki.lyx.org/Layouts/CreatingLayouts -Jacob
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 11:35 AM, Neal Beckerwrote: > Helpful, but does not pick out a page from a multi-page pdf > If you want to export a single page from a multi-page pdf then one possibility is to use a .pdf split/merge program such as pdfsam ( http://www.pdfsam.org/ ) or pdftk ( http://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/ ). I have nothing to do with either them, I just use those programs sometimes to get just what I need from a multipage pdf, and it's convenient for me since both are in the package repositories for my OS. pdfsam has a graphical interface, whereas pdftk is commandline only as far as I know. This isn't a very elegant or completely automated solution based on the LyX file which sounds like what you are really looking for, but it's the best way I am aware of. I hope this helps. Jacob
Re: Python Graphics in LyX [was: Python bindings]
Am 10.06.2014 15:52, schrieb Alex Vergara Gil: Thanks, Alex, for the new lyx file. I now realized, that I had to load the matplotlib and pandas packages, which I did. I followed your advices Define a new file format in tools>preferences, name it Python graphics, extension pygr and vector image format ticked Define a new converter from the format Python graphics to the format EPS as ... After reconfigure (necessary?) and making sure the two example graphics (in pygr format) are found in the path I get this error LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.eps' not found on input line 83. Why is it expecting an eps file instead of taking the pygr files? What am I missing? Wolfgang Dear all I have rewritten a little the procedure using recommendations from several users that doesn´t understand the original one. I hope this time everyone can understand the procedure. Regards Alex - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Tuesday, June 10, 2014 2:56 AM Subject: Re: Python Graphics in LyX [was: Python bindings] I retryed again and now got the PythonGraphics>LyX converter after reconfiguring, but running it gives me: LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found on inp ut line 80. shouldn't it load example.pygr, which I selected in my folder PhytonGraphics containing all the files supplied by Alex? Do I have to use instead of view>pdflatex something else for export? Wolfgang ! Package pdftex.def Error: File `0_home_we_Lyx_PhytonGraphics_example.pdf' not found. See the pdftex.def package documentation for explanation. Type H for immediate help. ... Am 10.06.2014 09:00, schrieb Wolfgang Engelmann: Am 09.06.2014 21:42, schrieb Alex Vergara Gil: - Original Message - From: Wolfgang Engelmann To: lyx-users@lists.lyx.org Sent: Monday, June 09, 2014 12:55 PM Subject: Re: Python Graphics in LyX [was: Python bindings] where in lyx is this done?--> Define a new converter from Python graphics to EPS as python $$i $$o Wolfgang If you have followed the little manual you know in tools - preferences there is two options, one that says file types and the other says converters in the first you define the Python graphics file type in the second you define the converter regards Alex Thanks Alex, still not there. First: Could one change in the instruction of the PythonGraphics.lyx Define a new file format, name it Python graphics, extension pygr and vector image format ticked to: Define a new file format in tools>preferences, name it Python graphics, extension pygr and vector image format ticked Second: in Converters - Converter Definitions I guess I have to add python $$i $$o in the Converter: line. However, Add on the right side of the Converter Definitions is greyed out. So, how do I do that? Wolfgang __ Información de ESET NOD32 Antivirus, versión de la base de firmas de virus 9900 (20140605) __ ESET NOD32 Antivirus ha comprobado este mensaje. http://www.eset.com
Re: Python Graphics in LyX [was: Python bindings]
- Original Message - From: Wolfgang Engelmann Sent: Tuesday, June 10, 2014 2:19 PM Thanks, Alex, for the new lyx file. I now realized, that I had to load the matplotlib and pandas packages, which I did. I followed your advices Define a new file format in tools>preferences, name it Python graphics, extension pygr and vector image format ticked Define a new converter from the format Python graphics to the format EPS as ... After reconfigure (necessary?) and making sure the two example graphics (in pygr format) are found in the path I get this error No, reconfigure is not necessary LaTeX Warning: File `0_home_we_Lyx_PhytonGraphics_example.eps' not found on input line 83. Why is it expecting an eps file instead of taking the pygr files? indeed a eps file is expected What am I missing? Wolfgang Did you can see the graphic within LyX? Did LyX display it correctly in your system? if not the case check that the example script is located at the same path than the lyx file, another way is to click in the inserted graphic and look for the example.pygr path Another possible explanation is that your system doesn't handle with eps, in this case you should change the definition and instead of eps, put pdf or png as final format, whichever work for you, you can check that because it will display the graphic within LyX even before you export anything! Regards Alex
Re: pick out all graphics from a lyx file?
On Tue, Jun 10, 2014 at 7:35 PM, Neal Beckerwrote: > Helpful, but does not pick out a page from a multi-page pdf > Oh, then (on Linux) I would recommend: PDF Mod: https://wiki.gnome.org/Apps/PdfMod PDF Chain: http://pdfchain.sourceforge.net/ PDF-Shuffler: http://sourceforge.net/projects/pdfshuffler/ Either of these would allow to extract individual pages from a PDF. Liviu -- Do you know how to read? http://www.alienetworks.com/srtest.cfm http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader Do you know how to write? http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
Re: Backspacing at the start of an inset occupying a paragraph
On 10/06/2014 8:38 p.m., Jean-Marc Lasgouttes wrote: 08/06/2014 22:57, Richard Heck: I think the reason this happens is that the layout in effect in the inset becomes the layout in effect in the paragraph, if the inset is the only thing there. I'm not sure exactly why it works that way, though. This is is probably the case indeed. This makes sense when the note contains a Section environment for example. The behavior should be dependent on whether the layout is the default one or not. I have no idea of where this code lives, though. I think this deserves a bug report. JMarc Alas, you have confused me now. I'm not sure what to report -- my original posting or something else. Since standard is the default layout, that is indeed what the inset dissolves to if it contains normal text but, having been prompted to try a section heading in a note, it dissolves into a section heading (even within a list -- I see that it is perfectly possible to put a section heading, numbered, bolded, larger type, within a list or sublist or subsublist, and have it indented accordingly). Andrew