Conversion of pictures: which path is taken?

2013-01-21 Thread Rainer M Krug

Hi

I am using plantuml to create uml charts in a document, defined formats and converters and it works 
nicely. Plantuml has different output formats, among others png, eps and svg.


I have converters from eps to pdf (epstopdf) and from svg to pdf (rsvg-convert).

Both these go through to steps:

|- .eps - .pdf(pstopdf)
.plantuml -|
|- .svg - .pdf(pstopdf)

Now LyX chooses to go via .svg, which, based on the internals of plantuml, does not make much sense. 
I can obviously delete the conversion plantuml - svg, and LyX will go the other way, but then the 
preview in LyX is of much worse quality (no idea why).


So why does LyX choose to go via svg?
Is there a way to trick it into going via eps?

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


Re: Paste under 2.0.5.1

2013-01-21 Thread Eran Kaplinsky
It was suggested to me that Installer 2 might solve the problem.
It did.

Many thanks,

Eran



Am 18.01.2013 21:06, schrieb Eran Kaplinsky:


 After installing the latest (using the Installer-1 binary on a Win 7
 system) paste is broken.


I cannot reproduce.
Does the problem persists if you restart LyX?

regards Uwe


Re: Conversion of pictures: which path is taken?

2013-01-21 Thread Julien Rioux

On 21/01/2013 8:31 AM, Rainer M Krug wrote:

Hi

I am using plantuml to create uml charts in a document, defined formats
and converters and it works nicely. Plantuml has different output
formats, among others png, eps and svg.

I have converters from eps to pdf (epstopdf) and from svg to pdf
(rsvg-convert).

Both these go through to steps:

 |- .eps - .pdf(pstopdf)
..plantuml -|
 |- .svg - .pdf(pstopdf)

Now LyX chooses to go via .svg, which, based on the internals of
plantuml, does not make much sense. I can obviously delete the
conversion plantuml - svg, and LyX will go the other way, but then the
preview in LyX is of much worse quality (no idea why).

So why does LyX choose to go via svg?


Because it uses .svg in the editor view if possible, otherwise .png or 
something else.



Is there a way to trick it into going via eps?



Given two paths, LyX will choose a path that only goes through vector 
formats if possible, and the shortest path. Given that both your paths 
are equivalent based on these two points, I am not sure what breaks the 
tie in the end. You can probably trick LyX by marking .svg as a 
non-vector format.


Cheers,
Julien


Re: Lyx integration of lilypond, Windows 7

2013-01-21 Thread Julien Rioux

On 20/01/2013 7:02 PM, Uwe Stöhr wrote:

Am 16.01.2013 02:49, schrieb Uwe Stöhr:


One of the 2 current limitations of the LyX for Windows installer is
the missing support for LilyPond.
Implementing this is the current item on my ToDo list.


Today I had again a look and are still suffering from this bug:
http://code.google.com/p/lilypond/issues/detail?id=1815



The bug is different, it looks like you didn't set up the path.


Therefore Lilypond does not work with LyX on Windows.

regards Uwe



I got it working with lilypond 2.15.40 on windows 7. The instant 
previews in the LyX window do not work, but the pdf output works (and is 
very nice!). I remember for sure that I had to set up the PATH, but I 
cannot remember if more needed to be done. I'll try again with 2.16.2 if 
I can find the time. So it does not work out-of-the-box, and it has 
glitches, but I know that lilypond with LyX on windows does work.


Cheers,
Julien


Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Jerry

On Jan 18, 2013, at 6:15 AM, Steve Litt wrote:

 On Thu, 17 Jan 2013 21:17:28 -0700, Jerry said:
 
 On Jan 17, 2013, at 2:30 AM, Alex Fernandez wrote:
 
 Hi Jerry,
 
 I am the primary author of eLyXer.
 
 On Thu, Jan 17, 2013 at 4:49 AM, Jerry lancebo...@qwest.net wrote:
 Thanks for that tip. I checked it out. It's just a Python thing so
 it works fine on OS X, and LyX picked it up as advertised.
 
 Yes, I can confirm that OS X is fully supported.
 
 The output on my simple test case does look nice in a browser, but
 I get the same error opening with Word as I first described: The
 XML file bla bla bla cannot be opened... etc. I thought maybe my
 copy of Word was broken but it reads other HTML files fine--I'm
 guessing they don't have the XML stuff in them, however.
 
 Word does not like XHTML very much; you need to export to HTML 4,
 using the --html option.
 http://elyxer.nongnu.org/userguide.html#sub:HTML-Code If you are
 doing the conversion inside LyX, instead of on the command line,
 you have to add the --html in the conversion interface. I checked
 the HTML file that eLyXer made with the W3C page and got: The
 uploaded document - was successfully checked as XHTML 1.0
 Transitional.
 
 Yes, eLyXer outputs pure XHTML.
 
 Also--eLyXer does not appear to use MathML so I don't think there
 is any hope of getting editable math into Word using this method.
 (But I haven't read all of the eLyXer docs.)
 
 eLyXer has several options for Math output:
  http://elyxer.nongnu.org/userguide.html#sub:Math
 Sadly, none of them is MathML, since at the time eLyXer was
 conceived it was not very widely supported, and I have not found
 the time to add it.
 
 Hope this helps,
 
 Alex Fernández.
 
 Hi, Alex,
 
 Thanks for the comments and for the great tool. It does what it
 claims to to, convert LyX to HTML, with lots of math options. The
 default conversion looks great in a browser.
 
 I tried your --html suggestion and indeed Word opens it, and displays
 it much as a browser does. Unfortunately, the HTML limitations are
 apparent; this is probably as good as a HTML-only conversion can get.
 
 In my slow-witted way, I'm starting to understand why Word will not
 open the various XML formats that I'm throwing at it. (I also played
 with TeXht today (and the Mac GUI over it, SimpleTeXht. This method
 also makes XML in some variations, and .odt.) So Word isn't
 broken—it's just not made to recognize this particular kind of XML.
 (I want to use the word schema but don't really know what I'm
 talking about.) So What is missing, as has been stated in previous
 threads, is a converter from the XML that we're seeing to .docx, it
 seems.
 
 Jerry
 
 Hi Jerry,
 
 Did you ever consider trying to open the LyXML or whatever it's called
 in LibreOffice, and then from LibreOffice exporting it to MSWord
 format? That just might work.
 
 Thanks
 
 SteveT

I also found xhtml2odt at http://xhtml2odt.org/ but I can't get it to work for 
some reason. Also, the docs say that it will not convert graphics--these must 
be imported and linked in LibreOffice manually.

In any case, it looks like any path through (X)HTML is going to convert any 
vector graphics to something else, probably png, which is not a good service to 
e.g. PDFs.

Jerry

Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Nico Williams
I've been using LyXHTML and writing an XSL to convert from that.
That's left me unsatisfied.

I think the right approach is to have a LyX XML schema, export to
that, then apply an XSL to convert to whatever format you want.  I've
written a script to convert .lyx to XML using a very simple-minded
approach; I don't have a schema defined for this, just well-formed XML
output.  I'm still writing an XSL to replace the one I have that uses
LyXHTML input.

There was a thread about this a while back and the conclusion was that
I'm on my own with this, that for now my lyx2xml is not to be part of
LyX.  Partly there's a desire to consider making XML a native thing in
LyX, and partly there's a desire to not add more things into the LyX
source tree that might break when new features are added elsewhere in
the tree.

Dear LyX dev team: eventually you *really* do need to go the XML
route.  It's getting painful to not have a LyX XML format.  I know
this is a volunteer organization, so it's not like this can be made a
priority, but if you want LyX to be more relevant, then you need to do
this.

Nico
--


Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Jerry

On Jan 18, 2013, at 1:44 AM, Rainer M Krug wrote:

 On 18/01/13 09:10, Rainer M Krug wrote:
 On 18/01/13 05:17, Jerry wrote:
 
 On Jan 17, 2013, at 2:30 AM, Alex Fernandez wrote:
 
 Hi Jerry,
 
 I am the primary author of eLyXer.
 
 On Thu, Jan 17, 2013 at 4:49 AM, Jerry lancebo...@qwest.net
 mailto:lancebo...@qwest.net wrote:
 
 Thanks for that tip. I checked it out. It's just a Python thing so it 
 works fine on OS X, 
 and LyX picked it up as advertised.
 
 
 Yes, I can confirm that OS X is fully supported.
 
 
 The output on my simple test case does look nice in a browser, but I get 
 the same error 
 opening with Word as I first described: The XML file bla bla bla cannot 
 be opened...
 etc. I thought maybe my copy of Word was broken but it reads other HTML 
 files fine--I'm
 guessing they don't have the XML stuff in them, however.
 
 
 Word does not like XHTML very much; you need to export to HTML 4, using 
 the --html option.
 http://elyxer.nongnu.org/userguide.html#sub:HTML-Code If you are doing the 
 conversion
 inside LyX, instead of on the command line, you have to add the --html in 
 the conversion
 interface.
 
 
 I checked the HTML file that eLyXer made with the W3C page and got: The 
 uploaded document 
 - was successfully checked as XHTML 1.0 Transitional.
 
 
 Yes, eLyXer outputs pure XHTML.
 
 
 Also--eLyXer does not appear to use MathML so I don't think there is any 
 hope of getting 
 editable math into Word using this method. (But I haven't read all of the 
 eLyXer docs.)
 
 
 eLyXer has several options for Math output:
 http://elyxer.nongnu.org/userguide.html#sub:Math Sadly, none of them is 
 MathML, since at
 the time eLyXer was conceived it was not very widely supported, and I have 
 not found the
 time to add it.
 
 Hope this helps,
 
 Alex Fernández.
 
 Hi, Alex,
 
 Thanks for the comments and for the great tool. It does what it claims to 
 to, convert LyX to 
 HTML, with lots of math options. The default conversion looks great in a 
 browser.
 
 I tried your --html suggestion and indeed Word opens it, and displays it 
 much as a browser 
 does. Unfortunately, the HTML limitations are apparent; this is probably as 
 good as a
 HTML-only conversion can get.
 
 In my slow-witted way, I'm starting to understand why Word will not open 
 the various XML 
 formats that I'm throwing at it. (I also played with TeXht today (and the 
 Mac GUI over it, 
 SimpleTeXht. This method also makes XML in some variations, and .odt.) So 
 Word isn't 
 broken—it's just not made to recognize this particular kind of XML. (I want 
 to use the word 
 schema but don't really know what I'm talking about.) So What is missing, 
 as has been
 stated in previous threads, is a converter from the XML that we're seeing 
 to .docx, it
 seems.
 
 check pandoc - I am using pandoc to convert xhtml to docx and odt - works 
 perfect for me. I
 just
 
 Ups - should have been:
 ###
 I just added the following converter:
 
 \converter xhtml msdocx pandoc -o $$o $$i 
 \converter xhtml odt lo pandoc -o $$o $$i 
 ###

Hi Ranier,

I added these two lines to my preferences file and now I see to additional 
items in the Export list, but I don't know how to use them. Converter implies 
feeding them xhtml files but all I can see to do is to select them in the 
Export list which merely creates e.g. a .msdocx file, whatever that is.

Also, I played with pandoc a while back and its conversion of a very simple LyX 
file to Word was not perfect. I went LyX - LaTeX - docx. I did not 
investigate setting options very much. I recall that equations made the trip 
and were editable in Word 2011 (Mac) built-in equation editor, but equation 
numbers were lost. Today's effort, also on a simple but different document, LyX 
- LaTeX - docx, one equation was not typeset (only the markup appeared), a 
.eps file was not found even though it was present, and section labels were 
translated as literal text. Converting to .odt was worse, and at least once 
caused it to crash when it was attempting to repair what it thought was a 
damaged converted file. (But what _doesn't_ cause LibreOffice to crash?)

Jerry
 
 
 \converter xhtml msdocx pandoc -o $$o $$i  \converter xhtml odt 
 lo pandoc -o $$o
 $$i added the following converter:
 
 You have to play with the LyX xhtml or the eLyXer xhtml - I used LyXHTRML 
 because it workded 
 better in my case.
 
 I really think that pandoc should be detected automatically by LyX (when 
 doing reconfigure)
 and added as it provides very usable conversions.
 
 
 Cheers,
 
 Rainer
 
 
 Jerry
 
 
 
 



Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Nico Williams
Hmm, the thought occurs that my lyx2xml script wouldn't be broken by any
changes to.lyx, not if it was always chained with lyx2lyx so that it's
input were always in a version supported by lyx2xml...


Conversion of pictures: which path is taken?

2013-01-21 Thread Rainer M Krug

Hi

I am using plantuml to create uml charts in a document, defined formats and converters and it works 
nicely. Plantuml has different output formats, among others png, eps and svg.


I have converters from eps to pdf (epstopdf) and from svg to pdf (rsvg-convert).

Both these go through to steps:

|- .eps - .pdf(pstopdf)
.plantuml -|
|- .svg - .pdf(pstopdf)

Now LyX chooses to go via .svg, which, based on the internals of plantuml, does not make much sense. 
I can obviously delete the conversion plantuml - svg, and LyX will go the other way, but then the 
preview in LyX is of much worse quality (no idea why).


So why does LyX choose to go via svg?
Is there a way to trick it into going via eps?

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


Re: Paste under 2.0.5.1

2013-01-21 Thread Eran Kaplinsky
It was suggested to me that Installer 2 might solve the problem.
It did.

Many thanks,

Eran



Am 18.01.2013 21:06, schrieb Eran Kaplinsky:


 After installing the latest (using the Installer-1 binary on a Win 7
 system) paste is broken.


I cannot reproduce.
Does the problem persists if you restart LyX?

regards Uwe


Re: Conversion of pictures: which path is taken?

2013-01-21 Thread Julien Rioux

On 21/01/2013 8:31 AM, Rainer M Krug wrote:

Hi

I am using plantuml to create uml charts in a document, defined formats
and converters and it works nicely. Plantuml has different output
formats, among others png, eps and svg.

I have converters from eps to pdf (epstopdf) and from svg to pdf
(rsvg-convert).

Both these go through to steps:

 |- .eps - .pdf(pstopdf)
..plantuml -|
 |- .svg - .pdf(pstopdf)

Now LyX chooses to go via .svg, which, based on the internals of
plantuml, does not make much sense. I can obviously delete the
conversion plantuml - svg, and LyX will go the other way, but then the
preview in LyX is of much worse quality (no idea why).

So why does LyX choose to go via svg?


Because it uses .svg in the editor view if possible, otherwise .png or 
something else.



Is there a way to trick it into going via eps?



Given two paths, LyX will choose a path that only goes through vector 
formats if possible, and the shortest path. Given that both your paths 
are equivalent based on these two points, I am not sure what breaks the 
tie in the end. You can probably trick LyX by marking .svg as a 
non-vector format.


Cheers,
Julien


Re: Lyx integration of lilypond, Windows 7

2013-01-21 Thread Julien Rioux

On 20/01/2013 7:02 PM, Uwe Stöhr wrote:

Am 16.01.2013 02:49, schrieb Uwe Stöhr:


One of the 2 current limitations of the LyX for Windows installer is
the missing support for LilyPond.
Implementing this is the current item on my ToDo list.


Today I had again a look and are still suffering from this bug:
http://code.google.com/p/lilypond/issues/detail?id=1815



The bug is different, it looks like you didn't set up the path.


Therefore Lilypond does not work with LyX on Windows.

regards Uwe



I got it working with lilypond 2.15.40 on windows 7. The instant 
previews in the LyX window do not work, but the pdf output works (and is 
very nice!). I remember for sure that I had to set up the PATH, but I 
cannot remember if more needed to be done. I'll try again with 2.16.2 if 
I can find the time. So it does not work out-of-the-box, and it has 
glitches, but I know that lilypond with LyX on windows does work.


Cheers,
Julien


Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Jerry

On Jan 18, 2013, at 6:15 AM, Steve Litt wrote:

 On Thu, 17 Jan 2013 21:17:28 -0700, Jerry said:
 
 On Jan 17, 2013, at 2:30 AM, Alex Fernandez wrote:
 
 Hi Jerry,
 
 I am the primary author of eLyXer.
 
 On Thu, Jan 17, 2013 at 4:49 AM, Jerry lancebo...@qwest.net wrote:
 Thanks for that tip. I checked it out. It's just a Python thing so
 it works fine on OS X, and LyX picked it up as advertised.
 
 Yes, I can confirm that OS X is fully supported.
 
 The output on my simple test case does look nice in a browser, but
 I get the same error opening with Word as I first described: The
 XML file bla bla bla cannot be opened... etc. I thought maybe my
 copy of Word was broken but it reads other HTML files fine--I'm
 guessing they don't have the XML stuff in them, however.
 
 Word does not like XHTML very much; you need to export to HTML 4,
 using the --html option.
 http://elyxer.nongnu.org/userguide.html#sub:HTML-Code If you are
 doing the conversion inside LyX, instead of on the command line,
 you have to add the --html in the conversion interface. I checked
 the HTML file that eLyXer made with the W3C page and got: The
 uploaded document - was successfully checked as XHTML 1.0
 Transitional.
 
 Yes, eLyXer outputs pure XHTML.
 
 Also--eLyXer does not appear to use MathML so I don't think there
 is any hope of getting editable math into Word using this method.
 (But I haven't read all of the eLyXer docs.)
 
 eLyXer has several options for Math output:
  http://elyxer.nongnu.org/userguide.html#sub:Math
 Sadly, none of them is MathML, since at the time eLyXer was
 conceived it was not very widely supported, and I have not found
 the time to add it.
 
 Hope this helps,
 
 Alex Fernández.
 
 Hi, Alex,
 
 Thanks for the comments and for the great tool. It does what it
 claims to to, convert LyX to HTML, with lots of math options. The
 default conversion looks great in a browser.
 
 I tried your --html suggestion and indeed Word opens it, and displays
 it much as a browser does. Unfortunately, the HTML limitations are
 apparent; this is probably as good as a HTML-only conversion can get.
 
 In my slow-witted way, I'm starting to understand why Word will not
 open the various XML formats that I'm throwing at it. (I also played
 with TeXht today (and the Mac GUI over it, SimpleTeXht. This method
 also makes XML in some variations, and .odt.) So Word isn't
 broken—it's just not made to recognize this particular kind of XML.
 (I want to use the word schema but don't really know what I'm
 talking about.) So What is missing, as has been stated in previous
 threads, is a converter from the XML that we're seeing to .docx, it
 seems.
 
 Jerry
 
 Hi Jerry,
 
 Did you ever consider trying to open the LyXML or whatever it's called
 in LibreOffice, and then from LibreOffice exporting it to MSWord
 format? That just might work.
 
 Thanks
 
 SteveT

I also found xhtml2odt at http://xhtml2odt.org/ but I can't get it to work for 
some reason. Also, the docs say that it will not convert graphics--these must 
be imported and linked in LibreOffice manually.

In any case, it looks like any path through (X)HTML is going to convert any 
vector graphics to something else, probably png, which is not a good service to 
e.g. PDFs.

Jerry

Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Nico Williams
I've been using LyXHTML and writing an XSL to convert from that.
That's left me unsatisfied.

I think the right approach is to have a LyX XML schema, export to
that, then apply an XSL to convert to whatever format you want.  I've
written a script to convert .lyx to XML using a very simple-minded
approach; I don't have a schema defined for this, just well-formed XML
output.  I'm still writing an XSL to replace the one I have that uses
LyXHTML input.

There was a thread about this a while back and the conclusion was that
I'm on my own with this, that for now my lyx2xml is not to be part of
LyX.  Partly there's a desire to consider making XML a native thing in
LyX, and partly there's a desire to not add more things into the LyX
source tree that might break when new features are added elsewhere in
the tree.

Dear LyX dev team: eventually you *really* do need to go the XML
route.  It's getting painful to not have a LyX XML format.  I know
this is a volunteer organization, so it's not like this can be made a
priority, but if you want LyX to be more relevant, then you need to do
this.

Nico
--


Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Jerry

On Jan 18, 2013, at 1:44 AM, Rainer M Krug wrote:

 On 18/01/13 09:10, Rainer M Krug wrote:
 On 18/01/13 05:17, Jerry wrote:
 
 On Jan 17, 2013, at 2:30 AM, Alex Fernandez wrote:
 
 Hi Jerry,
 
 I am the primary author of eLyXer.
 
 On Thu, Jan 17, 2013 at 4:49 AM, Jerry lancebo...@qwest.net
 mailto:lancebo...@qwest.net wrote:
 
 Thanks for that tip. I checked it out. It's just a Python thing so it 
 works fine on OS X, 
 and LyX picked it up as advertised.
 
 
 Yes, I can confirm that OS X is fully supported.
 
 
 The output on my simple test case does look nice in a browser, but I get 
 the same error 
 opening with Word as I first described: The XML file bla bla bla cannot 
 be opened...
 etc. I thought maybe my copy of Word was broken but it reads other HTML 
 files fine--I'm
 guessing they don't have the XML stuff in them, however.
 
 
 Word does not like XHTML very much; you need to export to HTML 4, using 
 the --html option.
 http://elyxer.nongnu.org/userguide.html#sub:HTML-Code If you are doing the 
 conversion
 inside LyX, instead of on the command line, you have to add the --html in 
 the conversion
 interface.
 
 
 I checked the HTML file that eLyXer made with the W3C page and got: The 
 uploaded document 
 - was successfully checked as XHTML 1.0 Transitional.
 
 
 Yes, eLyXer outputs pure XHTML.
 
 
 Also--eLyXer does not appear to use MathML so I don't think there is any 
 hope of getting 
 editable math into Word using this method. (But I haven't read all of the 
 eLyXer docs.)
 
 
 eLyXer has several options for Math output:
 http://elyxer.nongnu.org/userguide.html#sub:Math Sadly, none of them is 
 MathML, since at
 the time eLyXer was conceived it was not very widely supported, and I have 
 not found the
 time to add it.
 
 Hope this helps,
 
 Alex Fernández.
 
 Hi, Alex,
 
 Thanks for the comments and for the great tool. It does what it claims to 
 to, convert LyX to 
 HTML, with lots of math options. The default conversion looks great in a 
 browser.
 
 I tried your --html suggestion and indeed Word opens it, and displays it 
 much as a browser 
 does. Unfortunately, the HTML limitations are apparent; this is probably as 
 good as a
 HTML-only conversion can get.
 
 In my slow-witted way, I'm starting to understand why Word will not open 
 the various XML 
 formats that I'm throwing at it. (I also played with TeXht today (and the 
 Mac GUI over it, 
 SimpleTeXht. This method also makes XML in some variations, and .odt.) So 
 Word isn't 
 broken—it's just not made to recognize this particular kind of XML. (I want 
 to use the word 
 schema but don't really know what I'm talking about.) So What is missing, 
 as has been
 stated in previous threads, is a converter from the XML that we're seeing 
 to .docx, it
 seems.
 
 check pandoc - I am using pandoc to convert xhtml to docx and odt - works 
 perfect for me. I
 just
 
 Ups - should have been:
 ###
 I just added the following converter:
 
 \converter xhtml msdocx pandoc -o $$o $$i 
 \converter xhtml odt lo pandoc -o $$o $$i 
 ###

Hi Ranier,

I added these two lines to my preferences file and now I see to additional 
items in the Export list, but I don't know how to use them. Converter implies 
feeding them xhtml files but all I can see to do is to select them in the 
Export list which merely creates e.g. a .msdocx file, whatever that is.

Also, I played with pandoc a while back and its conversion of a very simple LyX 
file to Word was not perfect. I went LyX - LaTeX - docx. I did not 
investigate setting options very much. I recall that equations made the trip 
and were editable in Word 2011 (Mac) built-in equation editor, but equation 
numbers were lost. Today's effort, also on a simple but different document, LyX 
- LaTeX - docx, one equation was not typeset (only the markup appeared), a 
.eps file was not found even though it was present, and section labels were 
translated as literal text. Converting to .odt was worse, and at least once 
caused it to crash when it was attempting to repair what it thought was a 
damaged converted file. (But what _doesn't_ cause LibreOffice to crash?)

Jerry
 
 
 \converter xhtml msdocx pandoc -o $$o $$i  \converter xhtml odt 
 lo pandoc -o $$o
 $$i added the following converter:
 
 You have to play with the LyX xhtml or the eLyXer xhtml - I used LyXHTRML 
 because it workded 
 better in my case.
 
 I really think that pandoc should be detected automatically by LyX (when 
 doing reconfigure)
 and added as it provides very usable conversions.
 
 
 Cheers,
 
 Rainer
 
 
 Jerry
 
 
 
 



Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Nico Williams
Hmm, the thought occurs that my lyx2xml script wouldn't be broken by any
changes to.lyx, not if it was always chained with lyx2lyx so that it's
input were always in a version supported by lyx2xml...


Conversion of pictures: which path is taken?

2013-01-21 Thread Rainer M Krug

Hi

I am using plantuml to create uml charts in a document, defined formats and converters and it works 
nicely. Plantuml has different output formats, among others png, eps and svg.


I have converters from eps to pdf (epstopdf) and from svg to pdf (rsvg-convert).

Both these go through to steps:

|-> .eps -> .pdf(pstopdf)
.plantuml ->|
|-> .svg -> .pdf(pstopdf)

Now LyX chooses to go via .svg, which, based on the internals of plantuml, does not make much sense. 
I can obviously delete the conversion plantuml -> svg, and LyX will go the other way, but then the 
preview in LyX is of much worse quality (no idea why).


So why does LyX choose to go via svg?
Is there a way to trick it into going via eps?

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


Re: Paste under 2.0.5.1

2013-01-21 Thread Eran Kaplinsky
It was suggested to me that Installer 2 might solve the problem.
It did.

Many thanks,

Eran



Am 18.01.2013 21:06, schrieb Eran Kaplinsky:


> After installing the latest (using the Installer-1 binary on a Win 7
> system) paste is broken.


I cannot reproduce.
Does the problem persists if you restart LyX?

regards Uwe


Re: Conversion of pictures: which path is taken?

2013-01-21 Thread Julien Rioux

On 21/01/2013 8:31 AM, Rainer M Krug wrote:

Hi

I am using plantuml to create uml charts in a document, defined formats
and converters and it works nicely. Plantuml has different output
formats, among others png, eps and svg.

I have converters from eps to pdf (epstopdf) and from svg to pdf
(rsvg-convert).

Both these go through to steps:

 |-> .eps -> .pdf(pstopdf)
..plantuml ->|
 |-> .svg -> .pdf(pstopdf)

Now LyX chooses to go via .svg, which, based on the internals of
plantuml, does not make much sense. I can obviously delete the
conversion plantuml -> svg, and LyX will go the other way, but then the
preview in LyX is of much worse quality (no idea why).

So why does LyX choose to go via svg?


Because it uses .svg in the editor view if possible, otherwise .png or 
something else.



Is there a way to trick it into going via eps?



Given two paths, LyX will choose a path that only goes through vector 
formats if possible, and the shortest path. Given that both your paths 
are equivalent based on these two points, I am not sure what breaks the 
tie in the end. You can probably trick LyX by marking .svg as a 
non-vector format.


Cheers,
Julien


Re: Lyx integration of lilypond, Windows 7

2013-01-21 Thread Julien Rioux

On 20/01/2013 7:02 PM, Uwe Stöhr wrote:

Am 16.01.2013 02:49, schrieb Uwe Stöhr:


One of the 2 current limitations of the LyX for Windows installer is
the missing support for LilyPond.
Implementing this is the current item on my ToDo list.


Today I had again a look and are still suffering from this bug:
http://code.google.com/p/lilypond/issues/detail?id=1815



The bug is different, it looks like you didn't set up the path.


Therefore Lilypond does not work with LyX on Windows.

regards Uwe



I got it working with lilypond 2.15.40 on windows 7. The instant 
previews in the LyX window do not work, but the pdf output works (and is 
very nice!). I remember for sure that I had to set up the PATH, but I 
cannot remember if more needed to be done. I'll try again with 2.16.2 if 
I can find the time. So it does not work out-of-the-box, and it has 
glitches, but I know that lilypond with LyX on windows does work.


Cheers,
Julien


Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Jerry

On Jan 18, 2013, at 6:15 AM, Steve Litt wrote:

> On Thu, 17 Jan 2013 21:17:28 -0700, Jerry said:
>> 
>> On Jan 17, 2013, at 2:30 AM, Alex Fernandez wrote:
>> 
>>> Hi Jerry,
>>> 
>>> I am the primary author of eLyXer.
>>> 
>>> On Thu, Jan 17, 2013 at 4:49 AM, Jerry  wrote:
>>> Thanks for that tip. I checked it out. It's just a Python thing so
>>> it works fine on OS X, and LyX picked it up as advertised.
>>> 
>>> Yes, I can confirm that OS X is fully supported.
>>> 
>>> The output on my simple test case does look nice in a browser, but
>>> I get the same error opening with Word as I first described: "The
>>> XML file bla bla bla cannot be opened..." etc. I thought maybe my
>>> copy of Word was broken but it reads other HTML files fine--I'm
>>> guessing they don't have the XML stuff in them, however.
>>> 
>>> Word does not like XHTML very much; you need to export to HTML 4,
>>> using the --html option.
>>> http://elyxer.nongnu.org/userguide.html#sub:HTML-Code If you are
>>> doing the conversion inside LyX, instead of on the command line,
>>> you have to add the --html in the conversion interface. I checked
>>> the HTML file that eLyXer made with the W3C page and got: "The
>>> uploaded document "-" was successfully checked as XHTML 1.0
>>> Transitional."
>>> 
>>> Yes, eLyXer outputs pure XHTML.
>>> 
>>> Also--eLyXer does not appear to use MathML so I don't think there
>>> is any hope of getting editable math into Word using this method.
>>> (But I haven't read all of the eLyXer docs.)
>>> 
>>> eLyXer has several options for Math output:
>>>  http://elyxer.nongnu.org/userguide.html#sub:Math
>>> Sadly, none of them is MathML, since at the time eLyXer was
>>> conceived it was not very widely supported, and I have not found
>>> the time to add it.
>>> 
>>> Hope this helps,
>>> 
>>> Alex Fernández.
>>> 
>> Hi, Alex,
>> 
>> Thanks for the comments and for the great tool. It does what it
>> claims to to, convert LyX to HTML, with lots of math options. The
>> default conversion looks great in a browser.
>> 
>> I tried your --html suggestion and indeed Word opens it, and displays
>> it much as a browser does. Unfortunately, the HTML limitations are
>> apparent; this is probably as good as a HTML-only conversion can get.
>> 
>> In my slow-witted way, I'm starting to understand why Word will not
>> open the various XML formats that I'm throwing at it. (I also played
>> with TeXht today (and the Mac GUI over it, SimpleTeXht. This method
>> also makes XML in some variations, and .odt.) So Word isn't
>> broken—it's just not made to recognize this particular kind of XML.
>> (I want to use the word "schema" but don't really know what I'm
>> talking about.) So What is missing, as has been stated in previous
>> threads, is a converter from the XML that we're seeing to .docx, it
>> seems.
>> 
>> Jerry
> 
> Hi Jerry,
> 
> Did you ever consider trying to open the LyXML or whatever it's called
> in LibreOffice, and then from LibreOffice exporting it to MSWord
> format? That just might work.
> 
> Thanks
> 
> SteveT

I also found xhtml2odt at http://xhtml2odt.org/ but I can't get it to work for 
some reason. Also, the docs say that it will not convert graphics--these must 
be imported and linked in LibreOffice manually.

In any case, it looks like any path through (X)HTML is going to convert any 
vector graphics to something else, probably png, which is not a good service to 
e.g. PDFs.

Jerry

Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Nico Williams
I've been using LyXHTML and writing an XSL to convert from that.
That's left me unsatisfied.

I think the right approach is to have a LyX XML schema, export to
that, then apply an XSL to convert to whatever format you want.  I've
written a script to convert .lyx to XML using a very simple-minded
approach; I don't have a schema defined for this, just well-formed XML
output.  I'm still writing an XSL to replace the one I have that uses
LyXHTML input.

There was a thread about this a while back and the conclusion was that
I'm on my own with this, that for now my lyx2xml is not to be part of
LyX.  Partly there's a desire to consider making XML a native thing in
LyX, and partly there's a desire to not add more things into the LyX
source tree that might break when new features are added elsewhere in
the tree.

Dear LyX dev team: eventually you *really* do need to go the XML
route.  It's getting painful to not have a LyX XML format.  I know
this is a volunteer organization, so it's not like this can be made a
priority, but if you want LyX to be more relevant, then you need to do
this.

Nico
--


Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Jerry

On Jan 18, 2013, at 1:44 AM, Rainer M Krug wrote:

> On 18/01/13 09:10, Rainer M Krug wrote:
>> On 18/01/13 05:17, Jerry wrote:
>>> 
>>> On Jan 17, 2013, at 2:30 AM, Alex Fernandez wrote:
>>> 
 Hi Jerry,
 
 I am the primary author of eLyXer.
 
 On Thu, Jan 17, 2013 at 4:49 AM, Jerry > wrote:
 
 Thanks for that tip. I checked it out. It's just a Python thing so it 
 works fine on OS X, 
 and LyX picked it up as advertised.
 
 
 Yes, I can confirm that OS X is fully supported.
 
 
 The output on my simple test case does look nice in a browser, but I get 
 the same error 
 opening with Word as I first described: "The XML file bla bla bla cannot 
 be opened..."
 etc. I thought maybe my copy of Word was broken but it reads other HTML 
 files fine--I'm
 guessing they don't have the XML stuff in them, however.
 
 
 Word does not like XHTML very much; you need to export to HTML 4, using 
 the --html option.
 http://elyxer.nongnu.org/userguide.html#sub:HTML-Code If you are doing the 
 conversion
 inside LyX, instead of on the command line, you have to add the --html in 
 the conversion
 interface.
 
 
 I checked the HTML file that eLyXer made with the W3C page and got: "The 
 uploaded document 
 "-" was successfully checked as XHTML 1.0 Transitional."
 
 
 Yes, eLyXer outputs pure XHTML.
 
 
 Also--eLyXer does not appear to use MathML so I don't think there is any 
 hope of getting 
 editable math into Word using this method. (But I haven't read all of the 
 eLyXer docs.)
 
 
 eLyXer has several options for Math output:
 http://elyxer.nongnu.org/userguide.html#sub:Math Sadly, none of them is 
 MathML, since at
 the time eLyXer was conceived it was not very widely supported, and I have 
 not found the
 time to add it.
 
 Hope this helps,
 
 Alex Fernández.
 
>>> Hi, Alex,
>>> 
>>> Thanks for the comments and for the great tool. It does what it claims to 
>>> to, convert LyX to 
>>> HTML, with lots of math options. The default conversion looks great in a 
>>> browser.
>>> 
>>> I tried your --html suggestion and indeed Word opens it, and displays it 
>>> much as a browser 
>>> does. Unfortunately, the HTML limitations are apparent; this is probably as 
>>> good as a
>>> HTML-only conversion can get.
>>> 
>>> In my slow-witted way, I'm starting to understand why Word will not open 
>>> the various XML 
>>> formats that I'm throwing at it. (I also played with TeXht today (and the 
>>> Mac GUI over it, 
>>> SimpleTeXht. This method also makes XML in some variations, and .odt.) So 
>>> Word isn't 
>>> broken—it's just not made to recognize this particular kind of XML. (I want 
>>> to use the word 
>>> "schema" but don't really know what I'm talking about.) So What is missing, 
>>> as has been
>>> stated in previous threads, is a converter from the XML that we're seeing 
>>> to .docx, it
>>> seems.
>> 
>> check pandoc - I am using pandoc to convert xhtml to docx and odt - works 
>> perfect for me. I
>> just
> 
> Ups - should have been:
> ###
> I just added the following converter:
> 
> \converter "xhtml" "msdocx" "pandoc -o $$o $$i" ""
> \converter "xhtml" "odt lo" "pandoc -o $$o $$i" ""
> ###

Hi Ranier,

I added these two lines to my preferences file and now I see to additional 
items in the Export list, but I don't know how to use them. "Converter" implies 
feeding them xhtml files but all I can see to do is to select them in the 
Export list which merely creates e.g. a .msdocx file, whatever that is.

Also, I played with pandoc a while back and its conversion of a very simple LyX 
file to Word was not perfect. I went LyX -> LaTeX -> docx. I did not 
investigate setting options very much. I recall that equations made the trip 
and were editable in Word 2011 (Mac) built-in equation editor, but equation 
numbers were lost. Today's effort, also on a simple but different document, LyX 
-> LaTeX -> docx, one equation was not typeset (only the markup appeared), a 
.eps file was not found even though it was present, and section labels were 
translated as literal text. Converting to .odt was worse, and at least once 
caused it to crash when it was attempting to repair what it thought was a 
damaged converted file. (But what _doesn't_ cause LibreOffice to crash?)

Jerry
> 
>> 
>> \converter "xhtml" "msdocx" "pandoc -o $$o $$i" "" \converter "xhtml" "odt 
>> lo" "pandoc -o $$o
>> $$i" ""added the following converter:
>> 
>> You have to play with the LyX xhtml or the eLyXer xhtml - I used LyXHTRML 
>> because it workded 
>> better in my case.
>> 
>> I really think that pandoc should be detected automatically by LyX (when 
>> doing reconfigure)
>> and added as it provides very usable conversions.
>> 
>> 
>> Cheers,
>> 
>> Rainer
>> 
>>> 
>>> Jerry
>> 

Re: Word won't open simplest LyXHTML file

2013-01-21 Thread Nico Williams
Hmm, the thought occurs that my lyx2xml script wouldn't be broken by any
changes to.lyx, not if it was always chained with lyx2lyx so that it's
input were always in a version supported by lyx2xml...