Re: and instead of und in german reference citation

2014-11-15 Thread Julien Rioux

On 15/11/2014 4:20 AM, Wolfgang Engelmann wrote:

Hello,
I get in a German document
and instead of und in the german reference citation.
Style file is spbasic.
I am using natbib author/year as the citation style and language German
with encoding default
PS, this really should be more explicit for the Lyx people to document,
since biblatex is a really good package, but requires a lot of tweaking
to work.

I guess I have either to change the bst file from spbasic to a german
spbasic or whatever (which one?),
or to change the and to und (but probably more issues) in the spbasic.
Could I share the bst file with somebody who has already done theses
changes?

Wolfgang




The file spbasic.bst is a plain text file which you can edit with a 
simple editor. You can locate it on the command line using


kpsewhich spbasic.bst

which will give you its path. Make a local copy of spbasic.bst in the 
same folder as your LyX file (I recommend also giving it a different 
name). Open the file and you will find


FUNCTION {bbl.and}
{ and}

followed by many more short functions for edited by, chap, etc. The 
part {bbl.and} defines the name of the function, and should be left as 
is. The part { and} is the return value of the function, which you 
want to change. Simply replace and to und and also translate any of 
the other functions as necessary. Use this translated copy in your LyX file.


Cheers,
Julien



Re: and instead of und in german reference citation

2014-11-15 Thread Julien Rioux

On 15/11/2014 4:20 AM, Wolfgang Engelmann wrote:

Hello,
I get in a German document
and instead of und in the german reference citation.
Style file is spbasic.
I am using natbib author/year as the citation style and language German
with encoding default
PS, this really should be more explicit for the Lyx people to document,
since biblatex is a really good package, but requires a lot of tweaking
to work.

I guess I have either to change the bst file from spbasic to a german
spbasic or whatever (which one?),
or to change the and to und (but probably more issues) in the spbasic.
Could I share the bst file with somebody who has already done theses
changes?

Wolfgang




The file spbasic.bst is a plain text file which you can edit with a 
simple editor. You can locate it on the command line using


kpsewhich spbasic.bst

which will give you its path. Make a local copy of spbasic.bst in the 
same folder as your LyX file (I recommend also giving it a different 
name). Open the file and you will find


FUNCTION {bbl.and}
{ and}

followed by many more short functions for edited by, chap, etc. The 
part {bbl.and} defines the name of the function, and should be left as 
is. The part { and} is the return value of the function, which you 
want to change. Simply replace and to und and also translate any of 
the other functions as necessary. Use this translated copy in your LyX file.


Cheers,
Julien



Re: and instead of und in german reference citation

2014-11-15 Thread Julien Rioux

On 15/11/2014 4:20 AM, Wolfgang Engelmann wrote:

Hello,
I get in a German document
and instead of und in the german reference citation.
Style file is spbasic.
I am using natbib author/year as the citation style and language German
with encoding default
PS, this really should be more explicit for the Lyx people to document,
since biblatex is a really good package, but requires a lot of tweaking
to work.

I guess I have either to change the bst file from spbasic to a german
spbasic or whatever (which one?),
or to change the and to und (but probably more issues) in the spbasic.
Could I share the bst file with somebody who has already done theses
changes?

Wolfgang




The file spbasic.bst is a plain text file which you can edit with a 
simple editor. You can locate it on the command line using


kpsewhich spbasic.bst

which will give you its path. Make a local copy of spbasic.bst in the 
same folder as your LyX file (I recommend also giving it a different 
name). Open the file and you will find


FUNCTION {bbl.and}
{ "and"}

followed by many more short functions for "edited by", "chap", etc. The 
part {bbl.and} defines the name of the function, and should be left as 
is. The part { "and"} is the return value of the function, which you 
want to change. Simply replace "and" to "und" and also translate any of 
the other functions as necessary. Use this translated copy in your LyX file.


Cheers,
Julien



Re: Weird compilation issue: identical files give different results.

2014-10-05 Thread Julien Rioux

On 05/10/2014 1:38 PM, stefano franchi wrote:



On Sun, Oct 5, 2014 at 11:42 AM, Jürgen Spitzmüller sp...@lyx.org
mailto:sp...@lyx.org wrote:

Am Sonntag 05 Oktober 2014, 10:49:47 schrieb stefano franchi:
 I have no idea what is going on. The only logical answer, in my mind, is
 that there are some cached results still lying somewhere. But where?

I think biber is also caching things.



That may be the case, as I have now solved the problem (but not found an
explanation yet).
So it turns out I had a bunch of auxiliary files related to the failing
document in the document's own directory. But none related to  its
successful twin. (These files were left over from the command line
compilations). Once I deleted those, compilation finally succeeded.


I think the explanation is that you suffered from this issue: 
http://www.lyx.org/trac/ticket/8000


Cheers,
Julien



Re: Weird compilation issue: identical files give different results.

2014-10-05 Thread Julien Rioux

On 05/10/2014 1:38 PM, stefano franchi wrote:



On Sun, Oct 5, 2014 at 11:42 AM, Jürgen Spitzmüller sp...@lyx.org
mailto:sp...@lyx.org wrote:

Am Sonntag 05 Oktober 2014, 10:49:47 schrieb stefano franchi:
 I have no idea what is going on. The only logical answer, in my mind, is
 that there are some cached results still lying somewhere. But where?

I think biber is also caching things.



That may be the case, as I have now solved the problem (but not found an
explanation yet).
So it turns out I had a bunch of auxiliary files related to the failing
document in the document's own directory. But none related to  its
successful twin. (These files were left over from the command line
compilations). Once I deleted those, compilation finally succeeded.


I think the explanation is that you suffered from this issue: 
http://www.lyx.org/trac/ticket/8000


Cheers,
Julien



Re: Weird compilation issue: identical files give different results.

2014-10-05 Thread Julien Rioux

On 05/10/2014 1:38 PM, stefano franchi wrote:



On Sun, Oct 5, 2014 at 11:42 AM, Jürgen Spitzmüller > wrote:

Am Sonntag 05 Oktober 2014, 10:49:47 schrieb stefano franchi:
> I have no idea what is going on. The only logical answer, in my mind, is
> that there are some cached results still lying somewhere. But where?

I think biber is also caching things.



That may be the case, as I have now solved the problem (but not found an
explanation yet).
So it turns out I had a bunch of auxiliary files related to the failing
document in the document's own directory. But none related to  its
successful twin. (These files were left over from the command line
compilations). Once I deleted those, compilation finally succeeded.


I think the explanation is that you suffered from this issue: 
http://www.lyx.org/trac/ticket/8000


Cheers,
Julien



Re: Failed compilation succeeds from command line: two problems

2014-10-04 Thread Julien Rioux

On 04/10/2014 3:23 PM, Scott Kostyshak wrote:

I understand your argument, Stefano. It is a reasonable one and also a
common one. For example, if you have a deadline to meet and a certain
error that you think might not even affect the output of the PDF (and
even if there is a chance, you could proof check the PDF manually),
you just want your PDF and don't have time to think about fixing a
possibly minor error. However, I think this is a feature request and
not a bug. You might want to open a trac ticket because this type of
conversation comes up from time to time and is likely to come up very
often in 2.2 if we start stopping compilation when BibTeX errors occur
(see http://www.lyx.org/trac/ticket/2757). Input from your side of the
debate is important since we don't have any developer currently
defending that (popular) feature request and it is important to
understand and try to accommodate all workflows.


FWIW I also think we should have a compilation mode which keeps going as 
far as possible. Of course, it would be a opt-in setting (could be a 
dialog asking to continue in the GUI and a --force option on the command 
line).


Cheers,
Julien



Re: copy and paste of latex insert

2014-10-04 Thread Julien Rioux

On 04/10/2014 4:35 AM, emile lunardon wrote:

I confirm that the bug I observed with LyX 2.1.2 running on Windows 8.1
is not present on the same version of LyX compilled on Linux Mint LMDE
(Debian based distribution).



I've seen similar strange behavior with copy/paste in LyX on Windows 7: 
Copy-pasting insets inserts only the inner text, copy-pasting math would 
paste the latex commands, etc. It seems to happen when I restart from 
hibernation mode, but I never could narrow	it down further to reproduce 
it consistently. The earliest instance dates back to LyX 2.0.x but I 
can't remember if it happened even before.


--
Julien



Re: Failed compilation succeeds from command line: two problems

2014-10-04 Thread Julien Rioux

On 04/10/2014 3:23 PM, Scott Kostyshak wrote:

I understand your argument, Stefano. It is a reasonable one and also a
common one. For example, if you have a deadline to meet and a certain
error that you think might not even affect the output of the PDF (and
even if there is a chance, you could proof check the PDF manually),
you just want your PDF and don't have time to think about fixing a
possibly minor error. However, I think this is a feature request and
not a bug. You might want to open a trac ticket because this type of
conversation comes up from time to time and is likely to come up very
often in 2.2 if we start stopping compilation when BibTeX errors occur
(see http://www.lyx.org/trac/ticket/2757). Input from your side of the
debate is important since we don't have any developer currently
defending that (popular) feature request and it is important to
understand and try to accommodate all workflows.


FWIW I also think we should have a compilation mode which keeps going as 
far as possible. Of course, it would be a opt-in setting (could be a 
dialog asking to continue in the GUI and a --force option on the command 
line).


Cheers,
Julien



Re: copy and paste of latex insert

2014-10-04 Thread Julien Rioux

On 04/10/2014 4:35 AM, emile lunardon wrote:

I confirm that the bug I observed with LyX 2.1.2 running on Windows 8.1
is not present on the same version of LyX compilled on Linux Mint LMDE
(Debian based distribution).



I've seen similar strange behavior with copy/paste in LyX on Windows 7: 
Copy-pasting insets inserts only the inner text, copy-pasting math would 
paste the latex commands, etc. It seems to happen when I restart from 
hibernation mode, but I never could narrow	it down further to reproduce 
it consistently. The earliest instance dates back to LyX 2.0.x but I 
can't remember if it happened even before.


--
Julien



Re: Failed compilation succeeds from command line: two problems

2014-10-04 Thread Julien Rioux

On 04/10/2014 3:23 PM, Scott Kostyshak wrote:

I understand your argument, Stefano. It is a reasonable one and also a
common one. For example, if you have a deadline to meet and a certain
error that you think might not even affect the output of the PDF (and
even if there is a chance, you could proof check the PDF manually),
you just want your PDF and don't have time to think about fixing a
possibly minor error. However, I think this is a feature request and
not a bug. You might want to open a trac ticket because this type of
conversation comes up from time to time and is likely to come up very
often in 2.2 if we start stopping compilation when BibTeX errors occur
(see http://www.lyx.org/trac/ticket/2757). Input from your side of the
debate is important since we don't have any developer currently
defending that (popular) feature request and it is important to
understand and try to accommodate all workflows.


FWIW I also think we should have a compilation mode which keeps going as 
far as possible. Of course, it would be a opt-in setting (could be a 
dialog asking to continue in the GUI and a --force option on the command 
line).


Cheers,
Julien



Re: copy and paste of latex insert

2014-10-04 Thread Julien Rioux

On 04/10/2014 4:35 AM, emile lunardon wrote:

I confirm that the bug I observed with LyX 2.1.2 running on Windows 8.1
is not present on the same version of LyX compilled on Linux Mint LMDE
(Debian based distribution).



I've seen similar strange behavior with copy/paste in LyX on Windows 7: 
Copy-pasting insets inserts only the inner text, copy-pasting math would 
paste the latex commands, etc. It seems to happen when I restart from 
hibernation mode, but I never could narrow	it down further to reproduce 
it consistently. The earliest instance dates back to LyX 2.0.x but I 
can't remember if it happened even before.


--
Julien



Re: how to restrict cited authors to 3 in the Bibliography

2014-09-26 Thread Julien Rioux

On 26/09/2014 9:38 AM, Wolfgang Engelmann wrote:


Am 26.09.2014 um 15:34 schrieb Wolfgang Engelmann:

I use spbasic (Springer Publ) as the bibstyle
(Koma script book)
and get the citations in the text right (Author1, X et al)
However, in the references all Coauthors are cited. How can I resrict
it to 3?
I tried to find an answer in the net, adding
\usepackage{natbib} to the preamble did not help.
Anybody who could help with a pointer?

Wolfgang

p.S.
In the references it should read like
Author1,X, Author2,X Author3,X et al
where X is the prenome abbreviation





To stick to bibtex, you would have to slightly modify the .bst style 
file, namely the format.names function, maybe something like this:


$ diff -u spbasic.bst spbasic3.bst
--- spbasic.bst 2014-09-26 16:17:29.093778700 -0400
+++ spbasic3.bst2014-09-26 16:25:46.120207000 -0400
@@ -490,6 +490,12 @@
   if$
   nameptr #1 + 'nameptr :=
   namesleft #1 - 'namesleft :=
+  nameptr #3 
+  namesleft #0 
+  and
+{  * bbl.etal * #0 'namesleft :=}
+{}
+  if$
 }
   while$
   } if$

The above says, if 3 names have already been printed, and the number of 
names remaining to be printed is greater than zero, than print   and 
et al and set the number of remaining names to zero.


Attached is spbasic3.bst, a style file based on spbasic.bst with the 
above change.


Cheers,
Julien

--
Julien
%%
%% This is file `spbasic.bst',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% merlin.mbs  (with options: 
`ay,nat,seq-lab,vonx,nm-rvx,ed-rev,jnrlst,dt-beg,yr-par,yrp-x,yrpp-xsp,note-yr,jxper,jttl-rm,thtit-a,pgsep-c,num-xser,ser-vol,jnm-x,btit-rm,bt-rm,pre-pub,doi,edparxc,blk-tit,in-col,fin-bare,pp,ed,abr,mth-bare,ord,jabr,xand,eprint,url,url-blk,em-x,nfss,')
%% 
%%
%%%%
%%  
  %%
%% For Springer medical, life sciences, chemistry, geology, engineering and 
  %%
%%   computer science publications. 
  %%
%% For use with the natbib package (see below). Default is author-year 
citations. %%
%%   When citations are numbered, please use \usepackage[numbers]{natbib}.  
  %%
%% A lack of punctuation is the key feature. Springer-Verlag 2004/10/15 
  %%
%% Report bugs and improvements to: Joylene Vette-Guillaume or Frank Holzwarth  
  %%
%%  
  %%
%%%%
%%
%% Copyright 1994-2004 Patrick W Daly
 % ===
 % IMPORTANT NOTICE:
 % This bibliographic style (bst) file has been generated from one or
 % more master bibliographic style (mbs) files, listed above.
 %
 % This generated file can be redistributed and/or modified under the terms
 % of the LaTeX Project Public License Distributed from CTAN
 % archives in directory macros/latex/base/lppl.txt; either
 % version 1 of the License, or any later version.
 % ===
 % Name and version information of the main mbs file:
 % \ProvidesFile{merlin.mbs}[2004/02/09 4.13 (PWD, AO, DPC)]
 %   For use with BibTeX version 0.99a or later
 %---
 % This bibliography style file is intended for texts in ENGLISH
 % This is an author-year citation style bibliography. As such, it is
 % non-standard LaTeX, and requires a special package file to function properly.
 % Such a package isnatbib.sty   by Patrick W. Daly
 % The form of the \bibitem entries is
 %   \bibitem[Jones et al.(1990)]{key}...
 %   \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}...
 % The essential feature is that the label (the part in brackets) consists
 % of the author names, as they should appear in the citation, with the year
 % in parentheses following. There must be no space before the opening
 % parenthesis!
 % With natbib v5.3, a full list of authors may also follow the year.
 % In natbib.sty, it is possible to define the type of enclosures that is
 % really wanted (brackets or parentheses), but in either case, there must
 % be parentheses in the label.
 % The \cite command functions as follows:
 %   \citet{key} ==Jones et al. (1990)
 %   \citet*{key} ==   Jones, Baker, and Smith (1990)
 %   \citep{key} ==(Jones et al., 1990)
 %   \citep*{key} ==   (Jones, Baker, and Smith, 1990)
 %   \citep[chap. 2]{key} ==   (Jones et al., 1990, chap. 2)
 %   \citep[e.g.][]{key} ==(e.g. Jones et al., 1990)
 %   \citep[e.g.][p. 32]{key} ==   (e.g. Jones et al., p. 32)
 %   \citeauthor{key} ==   Jones et al.
 %   \citeauthor*{key} ==  

Re: how to restrict cited authors to 3 in the Bibliography

2014-09-26 Thread Julien Rioux

On 26/09/2014 5:07 PM, Benedict Holland wrote:

Wouldn't that change the default for every document using that
particular style though? If this is only for one journal, modification
of style files would not only be overkill, but would impact future work
in unexpected ways. To get the desired results, it would be best to
limit it to document specific changes. For that, configuring biblatex or
biber or biblatex using biber would be the much more prefered approach.
A philosophy of don't change more than you need to is demanded when
using lyx and latex, at least to me. That said, yes. Changing the format
of how bibtex writes out the references in the document would work but
from a technical standpoint, that does far more than just change the
reference output for a single document so would best be avoided.

~Ben



Your concern is true only if one saves the modified file under the same 
name as the original and somewhere in the tex tree. Good practice 
dictates that if one modifies a style file, then a different name is 
also given to it, as I did. And one can decide whether to have this new 
style available in the tex tree or to keep it local, since it is 
sufficient to have it saved in the current document's directory.


I can understand that bibtex has deep issues which are only really 
addressed by moving on to a different system, but the concern you raise 
does not appear to me to be one of them.


Cheers,
Julien


Re: how to restrict cited authors to 3 in the Bibliography

2014-09-26 Thread Julien Rioux

On 26/09/2014 9:38 AM, Wolfgang Engelmann wrote:


Am 26.09.2014 um 15:34 schrieb Wolfgang Engelmann:

I use spbasic (Springer Publ) as the bibstyle
(Koma script book)
and get the citations in the text right (Author1, X et al)
However, in the references all Coauthors are cited. How can I resrict
it to 3?
I tried to find an answer in the net, adding
\usepackage{natbib} to the preamble did not help.
Anybody who could help with a pointer?

Wolfgang

p.S.
In the references it should read like
Author1,X, Author2,X Author3,X et al
where X is the prenome abbreviation





To stick to bibtex, you would have to slightly modify the .bst style 
file, namely the format.names function, maybe something like this:


$ diff -u spbasic.bst spbasic3.bst
--- spbasic.bst 2014-09-26 16:17:29.093778700 -0400
+++ spbasic3.bst2014-09-26 16:25:46.120207000 -0400
@@ -490,6 +490,12 @@
   if$
   nameptr #1 + 'nameptr :=
   namesleft #1 - 'namesleft :=
+  nameptr #3 
+  namesleft #0 
+  and
+{  * bbl.etal * #0 'namesleft :=}
+{}
+  if$
 }
   while$
   } if$

The above says, if 3 names have already been printed, and the number of 
names remaining to be printed is greater than zero, than print   and 
et al and set the number of remaining names to zero.


Attached is spbasic3.bst, a style file based on spbasic.bst with the 
above change.


Cheers,
Julien

--
Julien
%%
%% This is file `spbasic.bst',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% merlin.mbs  (with options: 
`ay,nat,seq-lab,vonx,nm-rvx,ed-rev,jnrlst,dt-beg,yr-par,yrp-x,yrpp-xsp,note-yr,jxper,jttl-rm,thtit-a,pgsep-c,num-xser,ser-vol,jnm-x,btit-rm,bt-rm,pre-pub,doi,edparxc,blk-tit,in-col,fin-bare,pp,ed,abr,mth-bare,ord,jabr,xand,eprint,url,url-blk,em-x,nfss,')
%% 
%%
%%%%
%%  
  %%
%% For Springer medical, life sciences, chemistry, geology, engineering and 
  %%
%%   computer science publications. 
  %%
%% For use with the natbib package (see below). Default is author-year 
citations. %%
%%   When citations are numbered, please use \usepackage[numbers]{natbib}.  
  %%
%% A lack of punctuation is the key feature. Springer-Verlag 2004/10/15 
  %%
%% Report bugs and improvements to: Joylene Vette-Guillaume or Frank Holzwarth  
  %%
%%  
  %%
%%%%
%%
%% Copyright 1994-2004 Patrick W Daly
 % ===
 % IMPORTANT NOTICE:
 % This bibliographic style (bst) file has been generated from one or
 % more master bibliographic style (mbs) files, listed above.
 %
 % This generated file can be redistributed and/or modified under the terms
 % of the LaTeX Project Public License Distributed from CTAN
 % archives in directory macros/latex/base/lppl.txt; either
 % version 1 of the License, or any later version.
 % ===
 % Name and version information of the main mbs file:
 % \ProvidesFile{merlin.mbs}[2004/02/09 4.13 (PWD, AO, DPC)]
 %   For use with BibTeX version 0.99a or later
 %---
 % This bibliography style file is intended for texts in ENGLISH
 % This is an author-year citation style bibliography. As such, it is
 % non-standard LaTeX, and requires a special package file to function properly.
 % Such a package isnatbib.sty   by Patrick W. Daly
 % The form of the \bibitem entries is
 %   \bibitem[Jones et al.(1990)]{key}...
 %   \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}...
 % The essential feature is that the label (the part in brackets) consists
 % of the author names, as they should appear in the citation, with the year
 % in parentheses following. There must be no space before the opening
 % parenthesis!
 % With natbib v5.3, a full list of authors may also follow the year.
 % In natbib.sty, it is possible to define the type of enclosures that is
 % really wanted (brackets or parentheses), but in either case, there must
 % be parentheses in the label.
 % The \cite command functions as follows:
 %   \citet{key} ==Jones et al. (1990)
 %   \citet*{key} ==   Jones, Baker, and Smith (1990)
 %   \citep{key} ==(Jones et al., 1990)
 %   \citep*{key} ==   (Jones, Baker, and Smith, 1990)
 %   \citep[chap. 2]{key} ==   (Jones et al., 1990, chap. 2)
 %   \citep[e.g.][]{key} ==(e.g. Jones et al., 1990)
 %   \citep[e.g.][p. 32]{key} ==   (e.g. Jones et al., p. 32)
 %   \citeauthor{key} ==   Jones et al.
 %   \citeauthor*{key} ==  

Re: how to restrict cited authors to 3 in the Bibliography

2014-09-26 Thread Julien Rioux

On 26/09/2014 5:07 PM, Benedict Holland wrote:

Wouldn't that change the default for every document using that
particular style though? If this is only for one journal, modification
of style files would not only be overkill, but would impact future work
in unexpected ways. To get the desired results, it would be best to
limit it to document specific changes. For that, configuring biblatex or
biber or biblatex using biber would be the much more prefered approach.
A philosophy of don't change more than you need to is demanded when
using lyx and latex, at least to me. That said, yes. Changing the format
of how bibtex writes out the references in the document would work but
from a technical standpoint, that does far more than just change the
reference output for a single document so would best be avoided.

~Ben



Your concern is true only if one saves the modified file under the same 
name as the original and somewhere in the tex tree. Good practice 
dictates that if one modifies a style file, then a different name is 
also given to it, as I did. And one can decide whether to have this new 
style available in the tex tree or to keep it local, since it is 
sufficient to have it saved in the current document's directory.


I can understand that bibtex has deep issues which are only really 
addressed by moving on to a different system, but the concern you raise 
does not appear to me to be one of them.


Cheers,
Julien


Re: how to restrict cited authors to 3 in the Bibliography

2014-09-26 Thread Julien Rioux

On 26/09/2014 9:38 AM, Wolfgang Engelmann wrote:


Am 26.09.2014 um 15:34 schrieb Wolfgang Engelmann:

I use spbasic (Springer Publ) as the bibstyle
(Koma script book)
and get the citations in the text right (Author1, X et al)
However, in the references all Coauthors are cited. How can I resrict
it to 3?
I tried to find an answer in the net, adding
\usepackage{natbib} to the preamble did not help.
Anybody who could help with a pointer?

Wolfgang

p.S.
In the references it should read like
Author1,X, Author2,X Author3,X et al
where X is the prenome abbreviation





To stick to bibtex, you would have to slightly modify the .bst style 
file, namely the format.names function, maybe something like this:


$ diff -u spbasic.bst spbasic3.bst
--- spbasic.bst 2014-09-26 16:17:29.093778700 -0400
+++ spbasic3.bst2014-09-26 16:25:46.120207000 -0400
@@ -490,6 +490,12 @@
   if$
   nameptr #1 + 'nameptr :=
   namesleft #1 - 'namesleft :=
+  nameptr #3 >
+  namesleft #0 >
+  and
+{" " * bbl.etal * #0 'namesleft :=}
+{}
+  if$
 }
   while$
   } if$

The above says, if 3 names have already been printed, and the number of 
names remaining to be printed is greater than zero, than print " " and 
"et al" and set the number of remaining names to zero.


Attached is spbasic3.bst, a style file based on spbasic.bst with the 
above change.


Cheers,
Julien

--
Julien
%%
%% This is file `spbasic.bst',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% merlin.mbs  (with options: 
`ay,nat,seq-lab,vonx,nm-rvx,ed-rev,jnrlst,dt-beg,yr-par,yrp-x,yrpp-xsp,note-yr,jxper,jttl-rm,thtit-a,pgsep-c,num-xser,ser-vol,jnm-x,btit-rm,bt-rm,pre-pub,doi,edparxc,blk-tit,in-col,fin-bare,pp,ed,abr,mth-bare,ord,jabr,xand,eprint,url,url-blk,em-x,nfss,')
%% 
%%
%%%%
%%  
  %%
%% For Springer medical, life sciences, chemistry, geology, engineering and 
  %%
%%   computer science publications. 
  %%
%% For use with the natbib package (see below). Default is author-year 
citations. %%
%%   When citations are numbered, please use \usepackage[numbers]{natbib}.  
  %%
%% A lack of punctuation is the key feature. Springer-Verlag 2004/10/15 
  %%
%% Report bugs and improvements to: Joylene Vette-Guillaume or Frank Holzwarth  
  %%
%%  
  %%
%%%%
%%
%% Copyright 1994-2004 Patrick W Daly
 % ===
 % IMPORTANT NOTICE:
 % This bibliographic style (bst) file has been generated from one or
 % more master bibliographic style (mbs) files, listed above.
 %
 % This generated file can be redistributed and/or modified under the terms
 % of the LaTeX Project Public License Distributed from CTAN
 % archives in directory macros/latex/base/lppl.txt; either
 % version 1 of the License, or any later version.
 % ===
 % Name and version information of the main mbs file:
 % \ProvidesFile{merlin.mbs}[2004/02/09 4.13 (PWD, AO, DPC)]
 %   For use with BibTeX version 0.99a or later
 %---
 % This bibliography style file is intended for texts in ENGLISH
 % This is an author-year citation style bibliography. As such, it is
 % non-standard LaTeX, and requires a special package file to function properly.
 % Such a package isnatbib.sty   by Patrick W. Daly
 % The form of the \bibitem entries is
 %   \bibitem[Jones et al.(1990)]{key}...
 %   \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}...
 % The essential feature is that the label (the part in brackets) consists
 % of the author names, as they should appear in the citation, with the year
 % in parentheses following. There must be no space before the opening
 % parenthesis!
 % With natbib v5.3, a full list of authors may also follow the year.
 % In natbib.sty, it is possible to define the type of enclosures that is
 % really wanted (brackets or parentheses), but in either case, there must
 % be parentheses in the label.
 % The \cite command functions as follows:
 %   \citet{key} ==>>Jones et al. (1990)
 %   \citet*{key} ==>>   Jones, Baker, and Smith (1990)
 %   \citep{key} ==>>(Jones et al., 1990)
 %   \citep*{key} ==>>   (Jones, Baker, and Smith, 1990)
 %   \citep[chap. 2]{key} ==>>   (Jones et al., 1990, chap. 2)
 %   \citep[e.g.][]{key} ==>>(e.g. Jones et al., 1990)
 %   \citep[e.g.][p. 32]{key} ==>>   (e.g. Jones et al., p. 32)
 %   \citeauthor{key} ==>>   Jones et al.
 %   

Re: how to restrict cited authors to 3 in the Bibliography

2014-09-26 Thread Julien Rioux

On 26/09/2014 5:07 PM, Benedict Holland wrote:

Wouldn't that change the default for every document using that
particular style though? If this is only for one journal, modification
of style files would not only be overkill, but would impact future work
in unexpected ways. To get the desired results, it would be best to
limit it to document specific changes. For that, configuring biblatex or
biber or biblatex using biber would be the much more prefered approach.
A philosophy of "don't change more than you need to" is demanded when
using lyx and latex, at least to me. That said, yes. Changing the format
of how bibtex writes out the references in the document would work but
from a technical standpoint, that does far more than just change the
reference output for a single document so would best be avoided.

~Ben



Your concern is true only if one saves the modified file under the same 
name as the original and somewhere in the tex tree. Good practice 
dictates that if one modifies a style file, then a different name is 
also given to it, as I did. And one can decide whether to have this new 
style available in the tex tree or to keep it local, since it is 
sufficient to have it saved in the current document's directory.


I can understand that bibtex has deep issues which are only really 
addressed by moving on to a different system, but the concern you raise 
does not appear to me to be one of them.


Cheers,
Julien


Re: Koma(book) question

2013-12-19 Thread Julien Rioux

On 19/12/2013 6:16 AM, Wolfgang Engelmann wrote:

On Thursday 19 December 2013 10:53:21 Dr Eberhard Lisse wrote:

This is what I found and tried:

\setkomafont{chapter}{\uppercase}

\setkomafont{section}{\uppercase}

(or \setkomafont{section}{\normalfont\uppercase})

It does, what it should;

however, the

\setkomafont{section}{\uppercase}

prevents the crossreference to other sections in the text

and the pdf output shows ?? instead, such as

Cyanobacteria (Section ??),

Using your proposal

\usepackage[explicit]{titlesec}

\titleformat{\section}

{\normalfont}{\thesection}{1em}{\MakeUppercase{#1}}

gives me for all sec: crossreferences this:

LaTeX Warning: Reference `sec:LIGHT-AND-THE-HUMAN' on page 2 undefined
on input

line 152.

! Undefined control sequence.

\label #1-\@bsphack \begingroup \def \label@name

{#1}\label@hook \protected...

l.158 ...ical Clocks\label{sec:BIOLOGICAL-CLOCKS}}



It looks like you have labels inside the section titles, and now the 
labels are being capitalized. They probably should be moved outside, 
exactly after the section title on a Standard line.


--
Julien



Re: Koma(book) question

2013-12-19 Thread Julien Rioux

On 19/12/2013 6:16 AM, Wolfgang Engelmann wrote:

On Thursday 19 December 2013 10:53:21 Dr Eberhard Lisse wrote:

This is what I found and tried:

\setkomafont{chapter}{\uppercase}

\setkomafont{section}{\uppercase}

(or \setkomafont{section}{\normalfont\uppercase})

It does, what it should;

however, the

\setkomafont{section}{\uppercase}

prevents the crossreference to other sections in the text

and the pdf output shows ?? instead, such as

Cyanobacteria (Section ??),

Using your proposal

\usepackage[explicit]{titlesec}

\titleformat{\section}

{\normalfont}{\thesection}{1em}{\MakeUppercase{#1}}

gives me for all sec: crossreferences this:

LaTeX Warning: Reference `sec:LIGHT-AND-THE-HUMAN' on page 2 undefined
on input

line 152.

! Undefined control sequence.

\label #1-\@bsphack \begingroup \def \label@name

{#1}\label@hook \protected...

l.158 ...ical Clocks\label{sec:BIOLOGICAL-CLOCKS}}



It looks like you have labels inside the section titles, and now the 
labels are being capitalized. They probably should be moved outside, 
exactly after the section title on a Standard line.


--
Julien



Re: Koma(book) question

2013-12-19 Thread Julien Rioux

On 19/12/2013 6:16 AM, Wolfgang Engelmann wrote:

On Thursday 19 December 2013 10:53:21 Dr Eberhard Lisse wrote:

This is what I found and tried:

\setkomafont{chapter}{\uppercase}

\setkomafont{section}{\uppercase}

(or \setkomafont{section}{\normalfont\uppercase})

It does, what it should;

however, the

\setkomafont{section}{\uppercase}

prevents the crossreference to other sections in the text

and the pdf output shows ?? instead, such as

Cyanobacteria (Section ??),

Using your proposal

\usepackage[explicit]{titlesec}

\titleformat{\section}

{\normalfont}{\thesection}{1em}{\MakeUppercase{#1}}

gives me for all sec: crossreferences this:

LaTeX Warning: Reference `sec:LIGHT-AND-THE-HUMAN' on page 2 undefined
on input

line 152.

! Undefined control sequence.

\label #1->\@bsphack \begingroup \def \label@name

{#1}\label@hook \protected...

l.158 ...ical Clocks\label{sec:BIOLOGICAL-CLOCKS}}



It looks like you have labels inside the section titles, and now the 
labels are being capitalized. They probably should be moved outside, 
exactly after the section title on a Standard line.


--
Julien



Re: Comment écrire en Quôc Ngu' avec LyX ?

2013-12-18 Thread Julien Rioux

On 17/12/2013 8:31 PM, Robert Adolle wrote:

Merci de m'aider.

Sous Linux, je n'arrive même pas à me servir de X-Unikey, alors que,
hélas, j'y arrive avec cette horreur de Windows.
Normalement, on devrait pouvoir écrire en toutes les langues avec LyX,
et le viêtnamien est une langue alphabétique.

Merci !



Bonjour Robert: Cette liste est en anglais, je traduit pour que tout le 
monde puisse te comprendre et avec chance quelqu'un connait la réponse.


Hi Robert: This list is in English, I'll translate so that everyone can 
understand you and hopefully someone knows the answer.


Robert is asking how to write vietnamese using LyX. He says he doesn't 
succeed in using X-Unikey under Linux, whereas he could use it under 
Windows (but, reading between the lines, he would rather not use Windows 
OS). Normally, one should be able to write in any language with LyX, and 
vietnamese is an alphabetical language.


--
Julien


Re: Comment écrire en Quôc Ngu' avec LyX ?

2013-12-18 Thread Julien Rioux

On 17/12/2013 8:31 PM, Robert Adolle wrote:

Merci de m'aider.

Sous Linux, je n'arrive même pas à me servir de X-Unikey, alors que,
hélas, j'y arrive avec cette horreur de Windows.
Normalement, on devrait pouvoir écrire en toutes les langues avec LyX,
et le viêtnamien est une langue alphabétique.

Merci !



Bonjour Robert: Cette liste est en anglais, je traduit pour que tout le 
monde puisse te comprendre et avec chance quelqu'un connait la réponse.


Hi Robert: This list is in English, I'll translate so that everyone can 
understand you and hopefully someone knows the answer.


Robert is asking how to write vietnamese using LyX. He says he doesn't 
succeed in using X-Unikey under Linux, whereas he could use it under 
Windows (but, reading between the lines, he would rather not use Windows 
OS). Normally, one should be able to write in any language with LyX, and 
vietnamese is an alphabetical language.


--
Julien


Re: Comment écrire en Quôc Ngu' avec LyX ?

2013-12-18 Thread Julien Rioux

On 17/12/2013 8:31 PM, Robert Adolle wrote:

Merci de m'aider.

Sous Linux, je n'arrive même pas à me servir de X-Unikey, alors que,
hélas, j'y arrive avec cette horreur de Windows.
Normalement, on devrait pouvoir écrire en toutes les langues avec LyX,
et le viêtnamien est une langue alphabétique.

Merci !



Bonjour Robert: Cette liste est en anglais, je traduit pour que tout le 
monde puisse te comprendre et avec chance quelqu'un connait la réponse.


Hi Robert: This list is in English, I'll translate so that everyone can 
understand you and hopefully someone knows the answer.


Robert is asking how to write vietnamese using LyX. He says he doesn't 
succeed in using X-Unikey under Linux, whereas he could use it under 
Windows (but, reading between the lines, he would rather not use Windows 
OS). Normally, one should be able to write in any language with LyX, and 
vietnamese is an alphabetical language.


--
Julien


Re: Missing package lilypond-book-latex

2013-12-06 Thread Julien Rioux

On 06/12/2013 8:42 AM, Maurits Lamers wrote:

Hi all,

I am trying to get the LilypondBook module to work under Mac OSX Mountain Lion 
(10.8), but it complains about not being able to find a package named 
lilypond-book-latex.
I used the Tex Live Utility to find a package with that name, but haven't been 
able to find it, and anything else lilypond-related is already installed.

The Lyx log says:

14:28:45.466: (dialog-show document)Warning: Package not available

The module lilypond requires a package that is not
available in your LaTeX installation, or a converter that
you have not installed. LaTeX output may not be possible.
Missing prerequisites:
lilypond-book-latex
See section 3.1.2.3 (Modules) of the User's Guide for more information.



It's missing the converter from the lilypond format to the latex format. 
This converter is a python script called lilypond-book (it might have a 
.py extension or not, depending on the OS) and it comes installed with 
lilypond.



I have tried to put lilypond-book and lilypond in the PATH, checked on 
permissions, but nothing seems to make a conversion to PDF available in the 
Edit menu.
Running TexLive 2013, Lyx 2.0.6, Lilypond 2.16.1.



First thought: Did you reconfigure LyX? (menu Tools  Reconfigure)

Cheers,
Julien


Re: Missing package lilypond-book-latex

2013-12-06 Thread Julien Rioux

On 06/12/2013 8:42 AM, Maurits Lamers wrote:

Hi all,

I am trying to get the LilypondBook module to work under Mac OSX Mountain Lion 
(10.8), but it complains about not being able to find a package named 
lilypond-book-latex.
I used the Tex Live Utility to find a package with that name, but haven't been 
able to find it, and anything else lilypond-related is already installed.

The Lyx log says:

14:28:45.466: (dialog-show document)Warning: Package not available

The module lilypond requires a package that is not
available in your LaTeX installation, or a converter that
you have not installed. LaTeX output may not be possible.
Missing prerequisites:
lilypond-book-latex
See section 3.1.2.3 (Modules) of the User's Guide for more information.



It's missing the converter from the lilypond format to the latex format. 
This converter is a python script called lilypond-book (it might have a 
.py extension or not, depending on the OS) and it comes installed with 
lilypond.



I have tried to put lilypond-book and lilypond in the PATH, checked on 
permissions, but nothing seems to make a conversion to PDF available in the 
Edit menu.
Running TexLive 2013, Lyx 2.0.6, Lilypond 2.16.1.



First thought: Did you reconfigure LyX? (menu Tools  Reconfigure)

Cheers,
Julien


Re: Missing package lilypond-book->latex

2013-12-06 Thread Julien Rioux

On 06/12/2013 8:42 AM, Maurits Lamers wrote:

Hi all,

I am trying to get the LilypondBook module to work under Mac OSX Mountain Lion 
(10.8), but it complains about not being able to find a package named 
lilypond-book->latex.
I used the Tex Live Utility to find a package with that name, but haven't been 
able to find it, and anything else lilypond-related is already installed.

The Lyx log says:

14:28:45.466: (dialog-show document)Warning: Package not available

The module lilypond requires a package that is not
available in your LaTeX installation, or a converter that
you have not installed. LaTeX output may not be possible.
Missing prerequisites:
lilypond-book->latex
See section 3.1.2.3 (Modules) of the User's Guide for more information.



It's missing the converter from the lilypond format to the latex format. 
This converter is a python script called lilypond-book (it might have a 
.py extension or not, depending on the OS) and it comes installed with 
lilypond.



I have tried to put lilypond-book and lilypond in the PATH, checked on 
permissions, but nothing seems to make a conversion to PDF available in the 
Edit menu.
Running TexLive 2013, Lyx 2.0.6, Lilypond 2.16.1.



First thought: Did you reconfigure LyX? (menu Tools > Reconfigure)

Cheers,
Julien


Re: fancy footer

2013-12-04 Thread Julien Rioux

On 04/12/2013 10:28 AM, Ignacio Martinez wrote:

Can somebody help me write a fancy footer like the one in this paper
http://curry.virginia.edu/uploads/resourceLibrary/17_Castleman_All_or_Nothing.pdf
?


Something like this in your document preamble?

\usepackage{fancyhdr}
\fancyfoot[c]{%
  \footnotesize\centering%
  CEPWC Working Paper Series No. 17. November 2013.\\%
  Available at
  http://curry.virginia.edu/research/centers/cepwc/publications\\%
  Curry School of Education |
  Frank Batten School of Leadership and Public Policy |
  \textbf{University of Virginia}%
}

--
Julien



Re: fancy footer

2013-12-04 Thread Julien Rioux

On 04/12/2013 10:28 AM, Ignacio Martinez wrote:

Can somebody help me write a fancy footer like the one in this paper
http://curry.virginia.edu/uploads/resourceLibrary/17_Castleman_All_or_Nothing.pdf
?


Something like this in your document preamble?

\usepackage{fancyhdr}
\fancyfoot[c]{%
  \footnotesize\centering%
  CEPWC Working Paper Series No. 17. November 2013.\\%
  Available at
  http://curry.virginia.edu/research/centers/cepwc/publications\\%
  Curry School of Education |
  Frank Batten School of Leadership and Public Policy |
  \textbf{University of Virginia}%
}

--
Julien



Re: fancy footer

2013-12-04 Thread Julien Rioux

On 04/12/2013 10:28 AM, Ignacio Martinez wrote:

Can somebody help me write a fancy footer like the one in this paper
http://curry.virginia.edu/uploads/resourceLibrary/17_Castleman_All_or_Nothing.pdf
?


Something like this in your document preamble?

\usepackage{fancyhdr}
\fancyfoot[c]{%
  \footnotesize\centering%
  CEPWC Working Paper Series No. 17. November 2013.\\%
  Available at
  http://curry.virginia.edu/research/centers/cepwc/publications\\%
  Curry School of Education |
  Frank Batten School of Leadership and Public Policy |
  \textbf{University of Virginia}%
}

--
Julien



Re: layout for osa-revtex

2013-12-03 Thread Julien Rioux

On 02/12/2013 12:17 PM, Patrick Dupre wrote:

Hello,

I did not find a layout for osa-revtex style:
(http://www.opticsinfobase.org/josab/submit/templates/default.cfm)
Maybe some can tell me if he already built up or how I should
buid up one.

Thank.


Hi Patrick,

I've made a revtex4-1 layout that you can find at 
http://theorie.physik.uni-konstanz.de/jrioux/lyx/


Class options that are specific to the OSA can be entered in Document 
Settings  Document Class  Class options. Let us know if that works for 
you.


Cheers,
Julien



Re: layout for osa-revtex

2013-12-03 Thread Julien Rioux

On 02/12/2013 12:17 PM, Patrick Dupre wrote:

Hello,

I did not find a layout for osa-revtex style:
(http://www.opticsinfobase.org/josab/submit/templates/default.cfm)
Maybe some can tell me if he already built up or how I should
buid up one.

Thank.


Hi Patrick,

I've made a revtex4-1 layout that you can find at 
http://theorie.physik.uni-konstanz.de/jrioux/lyx/


Class options that are specific to the OSA can be entered in Document 
Settings  Document Class  Class options. Let us know if that works for 
you.


Cheers,
Julien



Re: layout for osa-revtex

2013-12-03 Thread Julien Rioux

On 02/12/2013 12:17 PM, Patrick Dupre wrote:

Hello,

I did not find a layout for osa-revtex style:
(http://www.opticsinfobase.org/josab/submit/templates/default.cfm)
Maybe some can tell me if he already built up or how I should
buid up one.

Thank.


Hi Patrick,

I've made a revtex4-1 layout that you can find at 
http://theorie.physik.uni-konstanz.de/jrioux/lyx/


Class options that are specific to the OSA can be entered in Document 
Settings > Document Class > Class options. Let us know if that works for 
you.


Cheers,
Julien



Re: Bibliographies with sections and preambles

2013-10-14 Thread Julien Rioux

On 13/10/2013 1:13 PM, s.no...@free.fr wrote:

Hello List Members,

Please bear with me as I'm a newcomer.

I have a question about sections  preambles in a bibliography to which I just
can't figure out the answer.

I'm working with the Koma Script book class (LyX 2.0.6 on OS X 10.7). At the end
of the book, I have to (1) have a bibliography with 3 different sections. Also,
(2) I have to insert text preambles, preferably after the bibliography section
titles and before the actual references themselves. At the very least, I could
settle for just one text preamble after the main title Bibliography, and
before the first bibliography section title. (See below for crude examples of
the desired result).

Also#8212;and this seems to be important#8212;I'm doing the bibliography
manually, i.e. I'm not generating it automatically with any external databases.

I discovered the setting Sectioned Bibliography in Document Settings /
Bibliography. And I've read the PDF entitled LyX Extended Features, esp.
§3.1.2., and other messages on this list. However, I just can't figure out how
to implement this manually. Any solutions seem to rely on the use of an external
database, which I don't use. But it doesn't seem as if it should be that
complicated, especially for someone not averse to using ERT.

Any help would be greatly appreciated.

Regards, and many thanks to anyone who'd have any ideas about this.

Sebastien




Example of the desired result:

BIBLIOGRAPHY

All Published Works by An Author
Some text preamble about the published works
Published Work 1
Published Work 2
Etc.

All Unpublished Works by An Author
Some text preamble about the unpublished works
Unpublished Work 1
Unpublished Work 2
Etc.

All Other Sources
Source 1
Source 2
Etc.
--


-
At the very least, this would be acceptable:
-
BIBLIOGRAPHY

Some text preamble about the bibliography

All Published Works by An Author
Published Work 1
Published Work 2
Etc.

All Unpublished Works by An Author
Unpublished Work 1
Unpublished Work 2
Etc.

All Other Sources
Source 1
Source 2
Etc.
--



Hi,

The bibliography preamble is the content of the macro \bibpreamble. It's 
empty by default, but you can set it using \def\bibpreamble{This text is 
the preamble.} in ERT. Since you are using Koma-Script, you can use 
\setbibpreamble{Text} to achieve the same. Koma-Script additionally 
offers the \BreakBibliography command to insert text fragments (or even 
section titles) between bibliographic entries. See the attached example 
and the Koma-Script documentation (scrguien.pdf) for more.


Cheers,
Julien


koma-sectioned-bib.lyx
Description: application/lyx


Re: Bibliographies with sections and preambles

2013-10-14 Thread Julien Rioux

On 13/10/2013 1:13 PM, s.no...@free.fr wrote:

Hello List Members,

Please bear with me as I'm a newcomer.

I have a question about sections  preambles in a bibliography to which I just
can't figure out the answer.

I'm working with the Koma Script book class (LyX 2.0.6 on OS X 10.7). At the end
of the book, I have to (1) have a bibliography with 3 different sections. Also,
(2) I have to insert text preambles, preferably after the bibliography section
titles and before the actual references themselves. At the very least, I could
settle for just one text preamble after the main title Bibliography, and
before the first bibliography section title. (See below for crude examples of
the desired result).

Also#8212;and this seems to be important#8212;I'm doing the bibliography
manually, i.e. I'm not generating it automatically with any external databases.

I discovered the setting Sectioned Bibliography in Document Settings /
Bibliography. And I've read the PDF entitled LyX Extended Features, esp.
§3.1.2., and other messages on this list. However, I just can't figure out how
to implement this manually. Any solutions seem to rely on the use of an external
database, which I don't use. But it doesn't seem as if it should be that
complicated, especially for someone not averse to using ERT.

Any help would be greatly appreciated.

Regards, and many thanks to anyone who'd have any ideas about this.

Sebastien




Example of the desired result:

BIBLIOGRAPHY

All Published Works by An Author
Some text preamble about the published works
Published Work 1
Published Work 2
Etc.

All Unpublished Works by An Author
Some text preamble about the unpublished works
Unpublished Work 1
Unpublished Work 2
Etc.

All Other Sources
Source 1
Source 2
Etc.
--


-
At the very least, this would be acceptable:
-
BIBLIOGRAPHY

Some text preamble about the bibliography

All Published Works by An Author
Published Work 1
Published Work 2
Etc.

All Unpublished Works by An Author
Unpublished Work 1
Unpublished Work 2
Etc.

All Other Sources
Source 1
Source 2
Etc.
--



Hi,

The bibliography preamble is the content of the macro \bibpreamble. It's 
empty by default, but you can set it using \def\bibpreamble{This text is 
the preamble.} in ERT. Since you are using Koma-Script, you can use 
\setbibpreamble{Text} to achieve the same. Koma-Script additionally 
offers the \BreakBibliography command to insert text fragments (or even 
section titles) between bibliographic entries. See the attached example 
and the Koma-Script documentation (scrguien.pdf) for more.


Cheers,
Julien


koma-sectioned-bib.lyx
Description: application/lyx


Re: Bibliographies with sections and preambles

2013-10-14 Thread Julien Rioux

On 13/10/2013 1:13 PM, s.no...@free.fr wrote:

Hello List Members,

Please bear with me as I'm a newcomer.

I have a question about sections & preambles in a bibliography to which I just
can't figure out the answer.

I'm working with the Koma Script book class (LyX 2.0.6 on OS X 10.7). At the end
of the book, I have to (1) have a bibliography with 3 different sections. Also,
(2) I have to insert text preambles, preferably after the bibliography section
titles and before the actual references themselves. At the very least, I could
settle for just one text preamble after the main title "Bibliography", and
before the first bibliography section title. (See below for crude examples of
the desired result).

Alsoand this seems to be importantI'm doing the bibliography
manually, i.e. I'm not generating it automatically with any external databases.

I discovered the setting "Sectioned Bibliography" in Document Settings /
Bibliography. And I've read the PDF entitled "LyX Extended Features", esp.
§3.1.2., and other messages on this list. However, I just can't figure out how
to implement this manually. Any solutions seem to rely on the use of an external
database, which I don't use. But it doesn't seem as if it should be that
complicated, especially for someone not averse to using ERT.

Any help would be greatly appreciated.

Regards, and many thanks to anyone who'd have any ideas about this.

Sebastien




Example of the desired result:

BIBLIOGRAPHY

All Published Works by An Author
Some text preamble about the published works
Published Work 1
Published Work 2
Etc.

All Unpublished Works by An Author
Some text preamble about the unpublished works
Unpublished Work 1
Unpublished Work 2
Etc.

All Other Sources
Source 1
Source 2
Etc.
--


-
At the very least, this would be acceptable:
-
BIBLIOGRAPHY

Some text preamble about the bibliography

All Published Works by An Author
Published Work 1
Published Work 2
Etc.

All Unpublished Works by An Author
Unpublished Work 1
Unpublished Work 2
Etc.

All Other Sources
Source 1
Source 2
Etc.
--



Hi,

The bibliography preamble is the content of the macro \bibpreamble. It's 
empty by default, but you can set it using \def\bibpreamble{This text is 
the preamble.} in ERT. Since you are using Koma-Script, you can use 
\setbibpreamble{Text} to achieve the same. Koma-Script additionally 
offers the \BreakBibliography command to insert text fragments (or even 
section titles) between bibliographic entries. See the attached example 
and the Koma-Script documentation (scrguien.pdf) for more.


Cheers,
Julien


koma-sectioned-bib.lyx
Description: application/lyx


Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux
Hi,

On Wed, Sep 4, 2013 at 11:08 PM, Jane Shevtsov jane@gmail.com wrote:

 Hi Julien,

 On Wed, Sep 4, 2013 at 5:33 PM, Julien Rioux jri...@lyx.org wrote:

 On 03/09/2013 11:54 PM, Jane Shevtsov wrote:

 Also, PLoS provides a template for LaTeX users.
 (http://www.plosone.org/**static/plos_template.texhttp://www.plosone.org/static/plos_template.tex)
 What do I do with that
 thing? I tried just importing the template into LyX and copying my text
 into it, but it's not at all clear what to do with the figure legends
 and tables. Do I edit the ERT directly?


 These probably shouldn't come out as ERT. The reason is probably because
 there is no .layout file for this LaTeX class. Creating a layout file is
 explained in the Customization manual and might be as simple as copying the
 standard article.layout. With a layout in place, the import from LaTeX
 should do a better job.


 The file that PLoS provides is just a template, NOT a class. (Click the
 link.) How do I make a layout from a template?


Sorry, I should have had a look. It i using the article class, so that's
fine. In the template, the LaTeX code for inserting figure and table floats
are commented out with % characters at the beginning of the lines, that's
why it gets imported as ERT. Just insert figure and table floats in the
usual way using the LyX frontend, it will generate the LaTeX code for you.
LyX generates standard LaTeX for this, and the template also uses standard
LaTeX here (as opposed to their formatting for the title and authors), so
this should not be a problem.

Cheers,
Julien




 Thanks,
 Jane

 --
 -
 Jane Shevtsov, Ph.D.
 Mathematical Biology Curriculum Writer, UCLA
 co-founder, www.worldbeyondborders.org

 “Those who say it cannot be done should not interfere with those who are
 doing it.” --attributed to Robert Heinlein, George Bernard Shaw and others



Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux

On 05/09/2013 5:08 AM, Csikos Bela wrote:

Jane Shevtsov jane@gmail.com írta:

Hello:


I#39;m trying to format an article for submission to PLoS One.
I#39;m using their BiBTeX style sheet (http://www.plosone.org/static/
plos2009.bst) and the bibliography works fine but I get quot;
(author?)quot; errors in the text when trying to cite an article as
Author [ID]. Apparently, this is because their style file isn#39;t a
Natbib style,


No, this is not correct. That style is a natbib style. It was made by
custom bib which supports natbib. The beginning  of the bst file indicates
this:

%%

%% This is file `PLoS.bst',

%% generated with the docstrip utility.

%%

%% The original source files were:

%%

%% merlin.mbs  (with options: ...



Hmm? The fact that it is generated by a tool that /can/ produce fully 
compatible natbib styles does not make this style a natbib style. It is 
a plain LaTeX style, with no additional packages required, just like 
plain.bst or unsrt.bst, so let's not call it something else. Natbib 
/will/ be able to use it to produce purely numerical citations, but the 
same is true for the standard plain.bst or unsrt.bst, and one wouldn't 
call those natbib styles.


Regards,
Julien



Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux

On 05/09/2013 5:59 AM, Csikos Bela wrote:

Julien Rioux jri...@lyx.org írta:


On 05/09/2013 5:08 AM, Csikos Bela wrote:

Jane Shevtsov jane@gmail.com írta:


Hello:

I#39;m trying to format an article for submission to PLoS One.
I#39;m using their BiBTeX style sheet (http://www.plosone.org/static/
plos2009.bst) and the bibliography works fine but I get quot;
(author?)quot; errors in the text when trying to cite an article as
Author [ID]. Apparently, this is because their style file isn#39;t a
Natbib style,


No, this is not correct. That style is a natbib style. It was made by
custom bib which supports natbib. The beginning  of the bst file indicates
this:

%%

%% This is file `PLoS.bst',

%% generated with the docstrip utility.

%%

%% The original source files were:

%%

%% merlin.mbs  (with options: ...




Hmm? The fact that it is generated by a tool that /can/ produce fully
compatible natbib styles does not make this style a natbib style. It is
a plain LaTeX style, with no additional packages required, just like
plain.bst or unsrt.bst, so let's not call it something else. Natbib
/will/ be able to use it to produce purely numerical citations, but the
same is true for the standard plain.bst or unsrt.bst, and one wouldn't
call those natbib styles.


OK, of course you're right in that sense. I only wanted to emphasize
that this bst works with natbib package. It is a natbib compatible
style.

Let me ask which styles would you call then natib style? Only those
ones which come packed with the natbib package?



Rough answer: those that require \usepackage{natbib} (and nothing else 
will do).


Technical answer: those that produce \bibitem in natbib's syntax:

\bibitem[Author 1 et al.(2013)Author 1, Author 2 and Author 3]{...}

That includes not only the styles shipped with the natbib package, also 
generated ones.


There are many other syntaxes for \bibitem, invented by other packages: 
natbib will understand most of them, but it then might be feature-limited.


Cheers,
Julien



Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux
Hi,

On Wed, Sep 4, 2013 at 11:08 PM, Jane Shevtsov jane@gmail.com wrote:

 Hi Julien,

 On Wed, Sep 4, 2013 at 5:33 PM, Julien Rioux jri...@lyx.org wrote:

 On 03/09/2013 11:54 PM, Jane Shevtsov wrote:

 Also, PLoS provides a template for LaTeX users.
 (http://www.plosone.org/**static/plos_template.texhttp://www.plosone.org/static/plos_template.tex)
 What do I do with that
 thing? I tried just importing the template into LyX and copying my text
 into it, but it's not at all clear what to do with the figure legends
 and tables. Do I edit the ERT directly?


 These probably shouldn't come out as ERT. The reason is probably because
 there is no .layout file for this LaTeX class. Creating a layout file is
 explained in the Customization manual and might be as simple as copying the
 standard article.layout. With a layout in place, the import from LaTeX
 should do a better job.


 The file that PLoS provides is just a template, NOT a class. (Click the
 link.) How do I make a layout from a template?


Sorry, I should have had a look. It i using the article class, so that's
fine. In the template, the LaTeX code for inserting figure and table floats
are commented out with % characters at the beginning of the lines, that's
why it gets imported as ERT. Just insert figure and table floats in the
usual way using the LyX frontend, it will generate the LaTeX code for you.
LyX generates standard LaTeX for this, and the template also uses standard
LaTeX here (as opposed to their formatting for the title and authors), so
this should not be a problem.

Cheers,
Julien




 Thanks,
 Jane

 --
 -
 Jane Shevtsov, Ph.D.
 Mathematical Biology Curriculum Writer, UCLA
 co-founder, www.worldbeyondborders.org

 “Those who say it cannot be done should not interfere with those who are
 doing it.” --attributed to Robert Heinlein, George Bernard Shaw and others



Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux

On 05/09/2013 5:08 AM, Csikos Bela wrote:

Jane Shevtsov jane@gmail.com írta:

Hello:


I#39;m trying to format an article for submission to PLoS One.
I#39;m using their BiBTeX style sheet (http://www.plosone.org/static/
plos2009.bst) and the bibliography works fine but I get quot;
(author?)quot; errors in the text when trying to cite an article as
Author [ID]. Apparently, this is because their style file isn#39;t a
Natbib style,


No, this is not correct. That style is a natbib style. It was made by
custom bib which supports natbib. The beginning  of the bst file indicates
this:

%%

%% This is file `PLoS.bst',

%% generated with the docstrip utility.

%%

%% The original source files were:

%%

%% merlin.mbs  (with options: ...



Hmm? The fact that it is generated by a tool that /can/ produce fully 
compatible natbib styles does not make this style a natbib style. It is 
a plain LaTeX style, with no additional packages required, just like 
plain.bst or unsrt.bst, so let's not call it something else. Natbib 
/will/ be able to use it to produce purely numerical citations, but the 
same is true for the standard plain.bst or unsrt.bst, and one wouldn't 
call those natbib styles.


Regards,
Julien



Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux

On 05/09/2013 5:59 AM, Csikos Bela wrote:

Julien Rioux jri...@lyx.org írta:


On 05/09/2013 5:08 AM, Csikos Bela wrote:

Jane Shevtsov jane@gmail.com írta:


Hello:

I#39;m trying to format an article for submission to PLoS One.
I#39;m using their BiBTeX style sheet (http://www.plosone.org/static/
plos2009.bst) and the bibliography works fine but I get quot;
(author?)quot; errors in the text when trying to cite an article as
Author [ID]. Apparently, this is because their style file isn#39;t a
Natbib style,


No, this is not correct. That style is a natbib style. It was made by
custom bib which supports natbib. The beginning  of the bst file indicates
this:

%%

%% This is file `PLoS.bst',

%% generated with the docstrip utility.

%%

%% The original source files were:

%%

%% merlin.mbs  (with options: ...




Hmm? The fact that it is generated by a tool that /can/ produce fully
compatible natbib styles does not make this style a natbib style. It is
a plain LaTeX style, with no additional packages required, just like
plain.bst or unsrt.bst, so let's not call it something else. Natbib
/will/ be able to use it to produce purely numerical citations, but the
same is true for the standard plain.bst or unsrt.bst, and one wouldn't
call those natbib styles.


OK, of course you're right in that sense. I only wanted to emphasize
that this bst works with natbib package. It is a natbib compatible
style.

Let me ask which styles would you call then natib style? Only those
ones which come packed with the natbib package?



Rough answer: those that require \usepackage{natbib} (and nothing else 
will do).


Technical answer: those that produce \bibitem in natbib's syntax:

\bibitem[Author 1 et al.(2013)Author 1, Author 2 and Author 3]{...}

That includes not only the styles shipped with the natbib package, also 
generated ones.


There are many other syntaxes for \bibitem, invented by other packages: 
natbib will understand most of them, but it then might be feature-limited.


Cheers,
Julien



Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux
Hi,

On Wed, Sep 4, 2013 at 11:08 PM, Jane Shevtsov <jane@gmail.com> wrote:

> Hi Julien,
>
> On Wed, Sep 4, 2013 at 5:33 PM, Julien Rioux <jri...@lyx.org> wrote:
>
>> On 03/09/2013 11:54 PM, Jane Shevtsov wrote:
>>
>>> Also, PLoS provides a template for LaTeX users.
>>> (http://www.plosone.org/**static/plos_template.tex<http://www.plosone.org/static/plos_template.tex>)
>>> What do I do with that
>>> thing? I tried just importing the template into LyX and copying my text
>>> into it, but it's not at all clear what to do with the figure legends
>>> and tables. Do I edit the ERT directly?
>>>
>>>
>> These probably shouldn't come out as ERT. The reason is probably because
>> there is no .layout file for this LaTeX class. Creating a layout file is
>> explained in the Customization manual and might be as simple as copying the
>> standard article.layout. With a layout in place, the import from LaTeX
>> should do a better job.
>>
>
> The file that PLoS provides is just a template, NOT a class. (Click the
> link.) How do I make a layout from a template?
>

Sorry, I should have had a look. It i using the article class, so that's
fine. In the template, the LaTeX code for inserting figure and table floats
are commented out with % characters at the beginning of the lines, that's
why it gets imported as ERT. Just insert figure and table floats in the
usual way using the LyX frontend, it will generate the LaTeX code for you.
LyX generates standard LaTeX for this, and the template also uses standard
LaTeX here (as opposed to their formatting for the title and authors), so
this should not be a problem.

Cheers,
Julien



>
> Thanks,
> Jane
>
> --
> -
> Jane Shevtsov, Ph.D.
> Mathematical Biology Curriculum Writer, UCLA
> co-founder, www.worldbeyondborders.org
>
> “Those who say it cannot be done should not interfere with those who are
> doing it.” --attributed to Robert Heinlein, George Bernard Shaw and others
>


Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux

On 05/09/2013 5:08 AM, Csikos Bela wrote:

Jane Shevtsov  írta:

Hello:


Im trying to format an article for submission to PLoS One.
Im using their BiBTeX style sheet (http://www.plosone.org/static/
plos2009.bst) and the bibliography works fine but I get 
(author?) errors in the text when trying to cite an article as
Author [ID]. Apparently, this is because their style file isnt a
Natbib style,


No, this is not correct. That style is a natbib style. It was made by
custom bib which supports natbib. The beginning  of the bst file indicates
this:

"%%

%% This is file `PLoS.bst',

%% generated with the docstrip utility.

%%

%% The original source files were:

%%

%% merlin.mbs  (with options: ..."



Hmm? The fact that it is generated by a tool that /can/ produce fully 
compatible natbib styles does not make this style a natbib style. It is 
a plain LaTeX style, with no additional packages required, just like 
plain.bst or unsrt.bst, so let's not call it something else. Natbib 
/will/ be able to use it to produce purely numerical citations, but the 
same is true for the standard plain.bst or unsrt.bst, and one wouldn't 
call those "natbib" styles.


Regards,
Julien



Re: Formatting Article for PLoS One

2013-09-05 Thread Julien Rioux

On 05/09/2013 5:59 AM, Csikos Bela wrote:

Julien Rioux <jri...@lyx.org> írta:


On 05/09/2013 5:08 AM, Csikos Bela wrote:

Jane Shevtsov <jane@gmail.com> írta:


Hello:

Im trying to format an article for submission to PLoS One.
Im using their BiBTeX style sheet (http://www.plosone.org/static/
plos2009.bst) and the bibliography works fine but I get 
(author?) errors in the text when trying to cite an article as
Author [ID]. Apparently, this is because their style file isnt a
Natbib style,


No, this is not correct. That style is a natbib style. It was made by
custom bib which supports natbib. The beginning  of the bst file indicates
this:

"%%

%% This is file `PLoS.bst',

%% generated with the docstrip utility.

%%

%% The original source files were:

%%

%% merlin.mbs  (with options: ..."




Hmm? The fact that it is generated by a tool that /can/ produce fully
compatible natbib styles does not make this style a natbib style. It is
a plain LaTeX style, with no additional packages required, just like
plain.bst or unsrt.bst, so let's not call it something else. Natbib
/will/ be able to use it to produce purely numerical citations, but the
same is true for the standard plain.bst or unsrt.bst, and one wouldn't
call those "natbib" styles.


OK, of course you're right in that sense. I only wanted to emphasize
that this bst works with natbib package. It is a natbib compatible
style.

Let me ask which styles would you call then natib style? Only those
ones which come packed with the natbib package?



Rough answer: those that require \usepackage{natbib} (and nothing else 
will do).


Technical answer: those that produce \bibitem in natbib's syntax:

\bibitem[Author 1 et al.(2013)Author 1, Author 2 and Author 3]{...}

That includes not only the styles shipped with the natbib package, also 
generated ones.


There are many other syntaxes for \bibitem, invented by other packages: 
natbib will understand most of them, but it then might be feature-limited.


Cheers,
Julien



Re: Formatting Article for PLoS One

2013-09-04 Thread Julien Rioux

On 03/09/2013 11:54 PM, Jane Shevtsov wrote:

I'm trying to format an article for submission to PLoS One. I'm using
their BiBTeX style sheet (http://www.plosone.org/static/plos2009.bst)
and the bibliography works fine but I get (author?) errors in the text
when trying to cite an article as Author [ID]. Apparently, this is
because their style file isn't a Natbib style, but changing the
bibliography style to default or Jurabib doesn't work. Is there anything
I can do short of typing authors' names by hand?



Ask them to provide a natbib-compatible style, or create one yourself. 
As it is, their style is meant to be used with the default 
bibliography mode. You can use it with natbib, but you won't be able to 
use natbib's features.



Also, PLoS provides a template for LaTeX users.
(http://www.plosone.org/static/plos_template.tex) What do I do with that
thing? I tried just importing the template into LyX and copying my text
into it, but it's not at all clear what to do with the figure legends
and tables. Do I edit the ERT directly?



These probably shouldn't come out as ERT. The reason is probably because 
there is no .layout file for this LaTeX class. Creating a layout file is 
explained in the Customization manual and might be as simple as copying 
the standard article.layout. With a layout in place, the import from 
LaTeX should do a better job.



Thanks,
Jane



Cheers,
Julien



Re: Cross-reference to subeq. within subequations environ

2013-09-04 Thread Julien Rioux

On 04/09/2013 9:45 AM, Rudi Gaelzer wrote:

Ok, I know I should've first read the whole AMSmath documentation before
asking this but... this is faster...

Say I have a bunch of equations within a labeled subequations
environment. Something like (in LaTeX):

...

\begin{subequations}

\label{eq:eq1}

\begin{equation}

Some math

\end{equation}

Some text

\begin{align}

Some math \\

Some math \\

Some math

\end{align}

\end{subequations}

... \ref{eq:eq1} ...

The equations are all labeled with the same number and with the roman
subnumbers from a through d.

As long as I'm aware, I can only \ref{} the main label. I can not make
an automatic reference to a particular subequation unless I label it as
well.

If I don't do it, I have to write the roman subnumber manually. However,
if I later on insert another equation within the subequations, I'll have
to scan the whole document and fix the subnumbers in all cross references...

Does anyone know of a way to automatize this process? Without having to
label individual eqs, I mean. Perhaps there's a package in CTAN that I
don't know of. And does LyX support it?



Why wouldn't you label the subequation that you specifically want to 
reference? That's exactly how you should do it, I think. That's how 
LaTeX handles this problem. Especially if you are worried about perhaps 
inserting or removing subequations before the referenced one.


Cheers,
Julien



Re: alignment of too-wide figures/tables

2013-09-04 Thread Julien Rioux

On 16/08/2013 8:09 AM, Andreas Hilboll wrote:

Hi LyX experts,

I have a twoside document, in which some Figures/Tables are wider than
my \textwidth. Is there a way to have these Tables/Figures automatically
align with the text body on the inner margin? Currently, they are
aligned with the text body on the left, which looks bad on left pages.

Any help is greatly appreciated :)
Cheers, Andreas.



Interesting problem, but it seems like nobody knows. You might have 
better luck on a LaTeX forum.


Cheers,
Julien



Re: FW: error on View [Ctrl-R]: The directory path to the document cannot contain spaces

2013-09-04 Thread Julien Rioux

On 28/08/2013 4:16 AM, Roel Schipper - CITG wrote:

If I export my file to LaTeX and compile it outside of LyX with my MikTeX it 
works, so the problem does not seem to be in the MikTeX installation. Btw, I 
did not change MikTeX during or after updating to LyX 2.0.6. The error also 
occurs *immediately* after pushing the View (CTRL-R) button, apparently even 
before calling MikTeX. Modifying all my path names is not a good solution, 
since all my earlier LyX-work would not be able to find images then.


Can you please add your issue to the bug tracker for LyX, so that we 
don't forget about it. Add a link to this discussion.


Thanks,
Cheers,
Julien



Re: Formatting Article for PLoS One

2013-09-04 Thread Julien Rioux

On 03/09/2013 11:54 PM, Jane Shevtsov wrote:

I'm trying to format an article for submission to PLoS One. I'm using
their BiBTeX style sheet (http://www.plosone.org/static/plos2009.bst)
and the bibliography works fine but I get (author?) errors in the text
when trying to cite an article as Author [ID]. Apparently, this is
because their style file isn't a Natbib style, but changing the
bibliography style to default or Jurabib doesn't work. Is there anything
I can do short of typing authors' names by hand?



Ask them to provide a natbib-compatible style, or create one yourself. 
As it is, their style is meant to be used with the default 
bibliography mode. You can use it with natbib, but you won't be able to 
use natbib's features.



Also, PLoS provides a template for LaTeX users.
(http://www.plosone.org/static/plos_template.tex) What do I do with that
thing? I tried just importing the template into LyX and copying my text
into it, but it's not at all clear what to do with the figure legends
and tables. Do I edit the ERT directly?



These probably shouldn't come out as ERT. The reason is probably because 
there is no .layout file for this LaTeX class. Creating a layout file is 
explained in the Customization manual and might be as simple as copying 
the standard article.layout. With a layout in place, the import from 
LaTeX should do a better job.



Thanks,
Jane



Cheers,
Julien



Re: Cross-reference to subeq. within subequations environ

2013-09-04 Thread Julien Rioux

On 04/09/2013 9:45 AM, Rudi Gaelzer wrote:

Ok, I know I should've first read the whole AMSmath documentation before
asking this but... this is faster...

Say I have a bunch of equations within a labeled subequations
environment. Something like (in LaTeX):

...

\begin{subequations}

\label{eq:eq1}

\begin{equation}

Some math

\end{equation}

Some text

\begin{align}

Some math \\

Some math \\

Some math

\end{align}

\end{subequations}

... \ref{eq:eq1} ...

The equations are all labeled with the same number and with the roman
subnumbers from a through d.

As long as I'm aware, I can only \ref{} the main label. I can not make
an automatic reference to a particular subequation unless I label it as
well.

If I don't do it, I have to write the roman subnumber manually. However,
if I later on insert another equation within the subequations, I'll have
to scan the whole document and fix the subnumbers in all cross references...

Does anyone know of a way to automatize this process? Without having to
label individual eqs, I mean. Perhaps there's a package in CTAN that I
don't know of. And does LyX support it?



Why wouldn't you label the subequation that you specifically want to 
reference? That's exactly how you should do it, I think. That's how 
LaTeX handles this problem. Especially if you are worried about perhaps 
inserting or removing subequations before the referenced one.


Cheers,
Julien



Re: alignment of too-wide figures/tables

2013-09-04 Thread Julien Rioux

On 16/08/2013 8:09 AM, Andreas Hilboll wrote:

Hi LyX experts,

I have a twoside document, in which some Figures/Tables are wider than
my \textwidth. Is there a way to have these Tables/Figures automatically
align with the text body on the inner margin? Currently, they are
aligned with the text body on the left, which looks bad on left pages.

Any help is greatly appreciated :)
Cheers, Andreas.



Interesting problem, but it seems like nobody knows. You might have 
better luck on a LaTeX forum.


Cheers,
Julien



Re: FW: error on View [Ctrl-R]: The directory path to the document cannot contain spaces

2013-09-04 Thread Julien Rioux

On 28/08/2013 4:16 AM, Roel Schipper - CITG wrote:

If I export my file to LaTeX and compile it outside of LyX with my MikTeX it 
works, so the problem does not seem to be in the MikTeX installation. Btw, I 
did not change MikTeX during or after updating to LyX 2.0.6. The error also 
occurs *immediately* after pushing the View (CTRL-R) button, apparently even 
before calling MikTeX. Modifying all my path names is not a good solution, 
since all my earlier LyX-work would not be able to find images then.


Can you please add your issue to the bug tracker for LyX, so that we 
don't forget about it. Add a link to this discussion.


Thanks,
Cheers,
Julien



Re: Formatting Article for PLoS One

2013-09-04 Thread Julien Rioux

On 03/09/2013 11:54 PM, Jane Shevtsov wrote:

I'm trying to format an article for submission to PLoS One. I'm using
their BiBTeX style sheet (http://www.plosone.org/static/plos2009.bst)
and the bibliography works fine but I get "(author?)" errors in the text
when trying to cite an article as Author [ID]. Apparently, this is
because their style file isn't a Natbib style, but changing the
bibliography style to default or Jurabib doesn't work. Is there anything
I can do short of typing authors' names by hand?



Ask them to provide a natbib-compatible style, or create one yourself. 
As it is, their style is meant to be used with the "default" 
bibliography mode. You can use it with natbib, but you won't be able to 
use natbib's features.



Also, PLoS provides a template for LaTeX users.
(http://www.plosone.org/static/plos_template.tex) What do I do with that
thing? I tried just importing the template into LyX and copying my text
into it, but it's not at all clear what to do with the figure legends
and tables. Do I edit the ERT directly?



These probably shouldn't come out as ERT. The reason is probably because 
there is no .layout file for this LaTeX class. Creating a layout file is 
explained in the Customization manual and might be as simple as copying 
the standard article.layout. With a layout in place, the import from 
LaTeX should do a better job.



Thanks,
Jane



Cheers,
Julien



Re: Cross-reference to subeq. within subequations environ

2013-09-04 Thread Julien Rioux

On 04/09/2013 9:45 AM, Rudi Gaelzer wrote:

Ok, I know I should've first read the whole AMSmath documentation before
asking this but... this is faster...

Say I have a bunch of equations within a labeled subequations
environment. Something like (in LaTeX):

...

\begin{subequations}

\label{eq:eq1}

\begin{equation}



\end{equation}



\begin{align}

 \\

 \\



\end{align}

\end{subequations}

... \ref{eq:eq1} ...

The equations are all labeled with the same number and with the roman
subnumbers from a through d.

As long as I'm aware, I can only \ref{} the main label. I can not make
an automatic reference to a particular subequation unless I label it as
well.

If I don't do it, I have to write the roman subnumber manually. However,
if I later on insert another equation within the subequations, I'll have
to scan the whole document and fix the subnumbers in all cross references...

Does anyone know of a way to automatize this process? Without having to
label individual eqs, I mean. Perhaps there's a package in CTAN that I
don't know of. And does LyX support it?



Why wouldn't you label the subequation that you specifically want to 
reference? That's exactly how you should do it, I think. That's how 
LaTeX handles this problem. Especially if you are worried about perhaps 
inserting or removing subequations before the referenced one.


Cheers,
Julien



Re: alignment of too-wide figures/tables

2013-09-04 Thread Julien Rioux

On 16/08/2013 8:09 AM, Andreas Hilboll wrote:

Hi LyX experts,

I have a twoside document, in which some Figures/Tables are wider than
my \textwidth. Is there a way to have these Tables/Figures automatically
align with the text body on the inner margin? Currently, they are
aligned with the text body on the left, which looks bad on left pages.

Any help is greatly appreciated :)
Cheers, Andreas.



Interesting problem, but it seems like nobody knows. You might have 
better luck on a LaTeX forum.


Cheers,
Julien



Re: FW: error on View [Ctrl-R]: The directory path to the document cannot contain spaces

2013-09-04 Thread Julien Rioux

On 28/08/2013 4:16 AM, Roel Schipper - CITG wrote:

If I export my file to LaTeX and compile it outside of LyX with my MikTeX it 
works, so the problem does not seem to be in the MikTeX installation. Btw, I 
did not change MikTeX during or after updating to LyX 2.0.6. The error also 
occurs *immediately* after pushing the View (CTRL-R) button, apparently even 
before calling MikTeX. Modifying all my path names is not a good solution, 
since all my earlier LyX-work would not be able to find images then.


Can you please add your issue to the bug tracker for LyX, so that we 
don't forget about it. Add a link to this discussion.


Thanks,
Cheers,
Julien



Re: Citation and reference style

2013-08-24 Thread Julien Rioux

On 24/08/2013 3:13 AM, Wolfgang Engelmann wrote:

Am Friday, 23. August 2013, 20:41:37 schrieb Csikos Bela:

  Wolfgang Engelmann engelm...@uni-tuebingen.de írta:

 

  I haven't tried 2.1 beta yet. 2.0.6 should work in your case perfectly.

 

  For clarification I include a small lyx file and bib file with which I

  tried out your authdate.bst file you had sent, but it did not work (??

  instead of citations, no references, no error message.

 

  It works perfectly. In your sample lyx file you have loaded natbib

  twice, probably that was the reason for fail. If you load natbib

  through lyx GUI you must not load it again in your preamble.

 

  I modified your sample lyx file and I attach it here with the output

  pdf.

 

  bcsikos

Thanks again, Csikos.

I do not quite understand

documentbibliography

there are only 3 citation styles:

default (numerical)

Natbib with style Author-year and numerical

and

Jurabib

How would I modify Natbib with something else besides Author-year (eg
round, comma)? In the preamble, and would this overwrite the
bibliography setting? (eg with your \setcitestyle{comma,aysep={}}?

Why is default only numerical? What if I want Kluwer style or something
else? I can't leave everything unchecked in Bibliography, I have to
check one.



The file kluwer.bst is used with harvard.sty or natbib.sty. If you watn 
to use harvard.sty, select the default bibliography and put


\usepackage{harvard}

in your document preamble. If you want to use natbib.sty instead 
(recommended), select the natbib author-year setting. If you need 
additional customization of natbib options, do it in the document 
preamble as Csikos explained.


kluwer.bst supports full author citation, so you're good to use it with 
all the natbib features.


Cheers,
Julien



Re: Citation and reference style

2013-08-24 Thread Julien Rioux

On 23/08/2013 3:08 AM, Wolfgang Engelmann wrote:

Am Thursday, 22. August 2013, 20:46:14 schrieb Csikos Bela:

  So I select under toolsoutputlatex Bibliography Processor  bibtex

  (or custom? or bibtex8?)

 

  It seems you are using an older lyx version. It should work with it,

  still I suggest upgrading lyx to version 2.x.

###Thanks for your answer.

I am using 2.0.6

May be I should upgrade, but I am always afraid I do something wrong and
can't work with it afterward. There is a deadline for a book chapter
waiting...

 

  Set bibliography processor to bibtex. bibtex8 might work as well, I

  never tried it. If you select bibtex, make sure those fields in the bib

  database file that will be in the output do have only ASCII or latin-1

  encoded characters. Special characters should be replaced by latex

  commands (eg. ö is \{o} etc.).

 

  Since I have over 700 citations, I used Jabref for my bibliography and

  clicked the references via the lyx-export of jabref to the

  corresponding places of my document. If I use \setcitestyle{aysep={}}

  instead of your proposed \setcitestyle{round,aysep={}}, and if I put

  () around the citation, I get what I need.

 

  Do not add manually '(' and ')' around citations. The opening and

  closing braces (rounded, square, or other) are part of the citation.

  And it is better to add the citations within lyx.

 

  I don't know if jabref can handle the two different types of citations:

  ' and 'text (Author year) text'. Can it make a

  difference? If you insert the citations within lyx you can select which

  type you want. If you look at the source you can see that the latex

  command for the two types are different, \citet and \citep.

 

  Also, if you have several citations in a group, lyx can handle it.

  Can jabref handle that?

###I do it via lyx (add)

 

  Unfortunately you have to go through all the citations and adjust them

  manually. Or you can work on the .lyx source file directly using a text

  editor and replacing all cite* command with citep. (Make a backup

  of the original file before editing!) After this open your edited file

  in lyx, find the few (I suppose) occasions of 'text Author (year) text'

  type citations and adjust them manually.

 

  The \setcitestyle{round,aysep={}} and \setcitestyle{aysep={}}

  commands in the preamble have the same effect, as round is the

  default option in case of author-year citation. Removing or adding it

  does not make any difference.

 

  But what about eg: (Praschak-Rieder and Willeit 2012) and in case

  of three authors and more (Crosthwait et al. 1997)?

 

  I don't understand what your question is.

### here I meant the 'et al' after more then 2 authors in a (one!)
reference:

author 1

author 1 and author 2

author 1 et all (3 authors or more)

  Unfortunately latex handles citations in goups. One group is all

  the citations selected and added at the same time. All these citations

  will be between the same pair of parentheses. If you add neighboring

  citations separately, they will be within different parentheses pairs.

 

  The source also shows the difference. For example.

 

  3 citations in one group:

 

  \citep{citation1,citation2,citaton3}

 

  The output will be:

 

  (author1 year1, author2 year2, author3 year3)

 

  However if you add them separately, like this:

 

  \citep{citation1} \citep{citation2} \cite{citaton3}

 

  the output will be:

 

  (author1 year1) (author2 year2) (author3 year3)

 

  You can adjust the opening and closing braces and the seperators

  between authors etc using \setcitestyle.

 

  Read the natbib manual (available at CTAN) section 2.9 Selecting

  citation punctuation.

 

  Where in the .lyx file (or elsewhere) would I place the authdate.bst

  file you kindly supplied?

 

  You can put it anywhere you want, but the best place is the directory

  where your .lyx file is. You select the bst file by clicking 'BibTeX

  Generated Bibliography' and browse for it.

### I guess there is a 'normal' place? I have it now in .lyx/layouts



The .bst file has to be found by *bibtex*, so .lyx/layouts isn't a 
particularly good choice (unless you additionally tell bibtex to look 
there). The document directory, as suggested by Csikos, works just fine.


Cheers,
Julien



Re: Citation and reference style

2013-08-24 Thread Julien Rioux

On 24/08/2013 3:13 AM, Wolfgang Engelmann wrote:

Am Friday, 23. August 2013, 20:41:37 schrieb Csikos Bela:

  Wolfgang Engelmann engelm...@uni-tuebingen.de írta:

 

  I haven't tried 2.1 beta yet. 2.0.6 should work in your case perfectly.

 

  For clarification I include a small lyx file and bib file with which I

  tried out your authdate.bst file you had sent, but it did not work (??

  instead of citations, no references, no error message.

 

  It works perfectly. In your sample lyx file you have loaded natbib

  twice, probably that was the reason for fail. If you load natbib

  through lyx GUI you must not load it again in your preamble.

 

  I modified your sample lyx file and I attach it here with the output

  pdf.

 

  bcsikos

Thanks again, Csikos.

I do not quite understand

documentbibliography

there are only 3 citation styles:

default (numerical)

Natbib with style Author-year and numerical

and

Jurabib

How would I modify Natbib with something else besides Author-year (eg
round, comma)? In the preamble, and would this overwrite the
bibliography setting? (eg with your \setcitestyle{comma,aysep={}}?

Why is default only numerical? What if I want Kluwer style or something
else? I can't leave everything unchecked in Bibliography, I have to
check one.



The file kluwer.bst is used with harvard.sty or natbib.sty. If you watn 
to use harvard.sty, select the default bibliography and put


\usepackage{harvard}

in your document preamble. If you want to use natbib.sty instead 
(recommended), select the natbib author-year setting. If you need 
additional customization of natbib options, do it in the document 
preamble as Csikos explained.


kluwer.bst supports full author citation, so you're good to use it with 
all the natbib features.


Cheers,
Julien



Re: Citation and reference style

2013-08-24 Thread Julien Rioux

On 23/08/2013 3:08 AM, Wolfgang Engelmann wrote:

Am Thursday, 22. August 2013, 20:46:14 schrieb Csikos Bela:

  So I select under toolsoutputlatex Bibliography Processor  bibtex

  (or custom? or bibtex8?)

 

  It seems you are using an older lyx version. It should work with it,

  still I suggest upgrading lyx to version 2.x.

###Thanks for your answer.

I am using 2.0.6

May be I should upgrade, but I am always afraid I do something wrong and
can't work with it afterward. There is a deadline for a book chapter
waiting...

 

  Set bibliography processor to bibtex. bibtex8 might work as well, I

  never tried it. If you select bibtex, make sure those fields in the bib

  database file that will be in the output do have only ASCII or latin-1

  encoded characters. Special characters should be replaced by latex

  commands (eg. ö is \{o} etc.).

 

  Since I have over 700 citations, I used Jabref for my bibliography and

  clicked the references via the lyx-export of jabref to the

  corresponding places of my document. If I use \setcitestyle{aysep={}}

  instead of your proposed \setcitestyle{round,aysep={}}, and if I put

  () around the citation, I get what I need.

 

  Do not add manually '(' and ')' around citations. The opening and

  closing braces (rounded, square, or other) are part of the citation.

  And it is better to add the citations within lyx.

 

  I don't know if jabref can handle the two different types of citations:

  ' and 'text (Author year) text'. Can it make a

  difference? If you insert the citations within lyx you can select which

  type you want. If you look at the source you can see that the latex

  command for the two types are different, \citet and \citep.

 

  Also, if you have several citations in a group, lyx can handle it.

  Can jabref handle that?

###I do it via lyx (add)

 

  Unfortunately you have to go through all the citations and adjust them

  manually. Or you can work on the .lyx source file directly using a text

  editor and replacing all cite* command with citep. (Make a backup

  of the original file before editing!) After this open your edited file

  in lyx, find the few (I suppose) occasions of 'text Author (year) text'

  type citations and adjust them manually.

 

  The \setcitestyle{round,aysep={}} and \setcitestyle{aysep={}}

  commands in the preamble have the same effect, as round is the

  default option in case of author-year citation. Removing or adding it

  does not make any difference.

 

  But what about eg: (Praschak-Rieder and Willeit 2012) and in case

  of three authors and more (Crosthwait et al. 1997)?

 

  I don't understand what your question is.

### here I meant the 'et al' after more then 2 authors in a (one!)
reference:

author 1

author 1 and author 2

author 1 et all (3 authors or more)

  Unfortunately latex handles citations in goups. One group is all

  the citations selected and added at the same time. All these citations

  will be between the same pair of parentheses. If you add neighboring

  citations separately, they will be within different parentheses pairs.

 

  The source also shows the difference. For example.

 

  3 citations in one group:

 

  \citep{citation1,citation2,citaton3}

 

  The output will be:

 

  (author1 year1, author2 year2, author3 year3)

 

  However if you add them separately, like this:

 

  \citep{citation1} \citep{citation2} \cite{citaton3}

 

  the output will be:

 

  (author1 year1) (author2 year2) (author3 year3)

 

  You can adjust the opening and closing braces and the seperators

  between authors etc using \setcitestyle.

 

  Read the natbib manual (available at CTAN) section 2.9 Selecting

  citation punctuation.

 

  Where in the .lyx file (or elsewhere) would I place the authdate.bst

  file you kindly supplied?

 

  You can put it anywhere you want, but the best place is the directory

  where your .lyx file is. You select the bst file by clicking 'BibTeX

  Generated Bibliography' and browse for it.

### I guess there is a 'normal' place? I have it now in .lyx/layouts



The .bst file has to be found by *bibtex*, so .lyx/layouts isn't a 
particularly good choice (unless you additionally tell bibtex to look 
there). The document directory, as suggested by Csikos, works just fine.


Cheers,
Julien



Re: Citation and reference style

2013-08-24 Thread Julien Rioux

On 24/08/2013 3:13 AM, Wolfgang Engelmann wrote:

Am Friday, 23. August 2013, 20:41:37 schrieb Csikos Bela:

 > Wolfgang Engelmann  írta:

 >

 > I haven't tried 2.1 beta yet. 2.0.6 should work in your case perfectly.

 >

 > >For clarification I include a small lyx file and bib file with which I

 > >tried out your authdate.bst file you had sent, but it did not work (??

 > >instead of citations, no references, no error message.

 >

 > It works perfectly. In your sample lyx file you have loaded natbib

 > twice, probably that was the reason for fail. If you load natbib

 > through lyx GUI you must not load it again in your preamble.

 >

 > I modified your sample lyx file and I attach it here with the output

 > pdf.

 >

 > bcsikos

Thanks again, Csikos.

I do not quite understand

document>bibliography

there are only 3 citation styles:

default (numerical)

Natbib with style Author-year and numerical

and

Jurabib

How would I modify Natbib with something else besides Author-year (eg
round, comma)? In the preamble, and would this overwrite the
bibliography setting? (eg with your \setcitestyle{comma,aysep={}}?

Why is default only numerical? What if I want Kluwer style or something
else? I can't leave everything unchecked in Bibliography, I have to
check one.



The file kluwer.bst is used with harvard.sty or natbib.sty. If you watn 
to use harvard.sty, select the "default" bibliography and put


\usepackage{harvard}

in your document preamble. If you want to use natbib.sty instead 
(recommended), select the "natbib author-year" setting. If you need 
additional customization of natbib options, do it in the document 
preamble as Csikos explained.


kluwer.bst supports full author citation, so you're good to use it with 
all the natbib features.


Cheers,
Julien



Re: Citation and reference style

2013-08-24 Thread Julien Rioux

On 23/08/2013 3:08 AM, Wolfgang Engelmann wrote:

Am Thursday, 22. August 2013, 20:46:14 schrieb Csikos Bela:

 > >So I select under tools>output>latex> Bibliography Processor > bibtex

 > >(or custom? or bibtex8?)

 >

 > It seems you are using an older lyx version. It should work with it,

 > still I suggest upgrading lyx to version 2.x.

###Thanks for your answer.

I am using 2.0.6

May be I should upgrade, but I am always afraid I do something wrong and
can't work with it afterward. There is a deadline for a book chapter
waiting...

 >

 > Set bibliography processor to bibtex. bibtex8 might work as well, I

 > never tried it. If you select bibtex, make sure those fields in the bib

 > database file that will be in the output do have only ASCII or latin-1

 > encoded characters. Special characters should be replaced by latex

 > commands (eg. ö is \"{o} etc.).

 >

 > >Since I have over 700 citations, I used Jabref for my bibliography and

 > >clicked the references via the lyx-export of jabref to the

 > >corresponding places of my document. If I use \setcitestyle{aysep={}}

 > >instead of your proposed \setcitestyle{round,aysep={}}, and if I put

 > >() around the citation, I get what I need.

 >

 > Do not add manually '(' and ')' around citations. The opening and

 > closing braces (rounded, square, or other) are part of the citation.

 > And it is better to add the citations within lyx.

 >

 > I don't know if jabref can handle the two different types of citations:

 > ' and 'text (Author year) text'. Can it make a

 > difference? If you insert the citations within lyx you can select which

 > type you want. If you look at the source you can see that the latex

 > command for the two types are different, \citet and \citep.

 >

 > Also, if you have several citations in a group, lyx can handle it.

 > Can jabref handle that?

###I do it via lyx (add)

 >

 > Unfortunately you have to go through all the citations and adjust them

 > manually. Or you can work on the .lyx source file directly using a text

 > editor and replacing all cite* command with citep. (Make a backup

 > of the original file before editing!) After this open your edited file

 > in lyx, find the few (I suppose) occasions of 'text Author (year) text'

 > type citations and adjust them manually.

 >

 > The \setcitestyle{round,aysep={}} and \setcitestyle{aysep={}}

 > commands in the preamble have the same effect, as round is the

 > default option in case of author-year citation. Removing or adding it

 > does not make any difference.

 >

 > >But what about eg: (Praschak-Rieder and Willeit 2012) and in case

 > >of three authors and more (Crosthwait et al. 1997)?

 >

 > I don't understand what your question is.

### here I meant the 'et al' after more then 2 authors in a (one!)
reference:

author 1

author 1 and author 2

author 1 et all (3 authors or more)

 > Unfortunately latex handles citations in goups. One group is all

 > the citations selected and added at the same time. All these citations

 > will be between the same pair of parentheses. If you add neighboring

 > citations separately, they will be within different parentheses pairs.

 >

 > The source also shows the difference. For example.

 >

 > 3 citations in one group:

 >

 > \citep{citation1,citation2,citaton3}

 >

 > The output will be:

 >

 > (author1 year1, author2 year2, author3 year3)

 >

 > However if you add them separately, like this:

 >

 > \citep{citation1} \citep{citation2} \cite{citaton3}

 >

 > the output will be:

 >

 > (author1 year1) (author2 year2) (author3 year3)

 >

 > You can adjust the opening and closing braces and the seperators

 > between authors etc using \setcitestyle.

 >

 > Read the natbib manual (available at CTAN) section 2.9 Selecting

 > citation punctuation.

 >

 > >Where in the .lyx file (or elsewhere) would I place the authdate.bst

 > >file you kindly supplied?

 >

 > You can put it anywhere you want, but the best place is the directory

 > where your .lyx file is. You select the bst file by clicking 'BibTeX

 > Generated Bibliography' and browse for it.

### I guess there is a 'normal' place? I have it now in .lyx/layouts



The .bst file has to be found by *bibtex*, so .lyx/layouts isn't a 
particularly good choice (unless you additionally tell bibtex to look 
there). The document directory, as suggested by Csikos, works just fine.


Cheers,
Julien



Re: Problem with citations (author?)

2013-08-03 Thread Julien Rioux

On 03/08/2013 9:25 AM, Ignacio Martinez wrote:

Hi everyone,

When I try to add a citation I get see for instance (author?) [1, 3, 5].

How can I fix this?

Thanks a lot

PS: All the files to replicate this problem are available in this
dropbox folder https://www.dropbox.com/sh/4y3wj5k1k6q0vfm/gskcO4QZkz


Hi,

You are using the bibliography style plain, which is intended for use 
with the default (and limited) citation capabilities of LaTeX; for full 
natbib support you should use plainnat (or any other ...nat 
variant). This is changed in the settings for the BibTeX bibliography inset.


Cheers,
Julien



Re: Problem with citations (author?)

2013-08-03 Thread Julien Rioux

On 03/08/2013 9:25 AM, Ignacio Martinez wrote:

Hi everyone,

When I try to add a citation I get see for instance (author?) [1, 3, 5].

How can I fix this?

Thanks a lot

PS: All the files to replicate this problem are available in this
dropbox folder https://www.dropbox.com/sh/4y3wj5k1k6q0vfm/gskcO4QZkz


Hi,

You are using the bibliography style plain, which is intended for use 
with the default (and limited) citation capabilities of LaTeX; for full 
natbib support you should use plainnat (or any other ...nat 
variant). This is changed in the settings for the BibTeX bibliography inset.


Cheers,
Julien



Re: Problem with citations (author?)

2013-08-03 Thread Julien Rioux

On 03/08/2013 9:25 AM, Ignacio Martinez wrote:

Hi everyone,

When I try to add a citation I get see for instance (author?) [1, 3, 5].

How can I fix this?

Thanks a lot

PS: All the files to replicate this problem are available in this
dropbox folder https://www.dropbox.com/sh/4y3wj5k1k6q0vfm/gskcO4QZkz


Hi,

You are using the bibliography style "plain", which is intended for use 
with the default (and limited) citation capabilities of LaTeX; for full 
natbib support you should use "plainnat" (or any other "...nat" 
variant). This is changed in the settings for the BibTeX bibliography inset.


Cheers,
Julien



Re: psfragfig

2013-07-02 Thread Julien Rioux
On Tue, Jul 2, 2013 at 2:50 PM, Michael Bach pha...@gmail.com wrote:

 Hi Julien,

 On 5/19/13 11:55 PM, Julien Rioux wrote:

 On 28/10/2012 6:01 AM, Michael Bach wrote:

 Ok, although I did not solve this in terms of LyX configuration: Just a
 quick notice for sake of completeness and in case someone is plagued by
 this issue and might be happy to find this.

 On 10/26/12 12:29 PM, Michael Bach wrote:

 Now when I try to compile the document, I see the line:
 === pstool: begin processing ===
 Error exporting to format
 pdf2/Users/Shared/LyX/lyx-2.0.**4/src/support/Systemcall.cpp(**273):
 Systemcall: 'pdflatex -synctex=-1 -shell-escape  skriptum.tex'
 finished with exit code 1

 in the messages pane and get the error:
 I can't write on file `figures/EulerExplizit-pstool.**tex'.

 Now I assume that the external command from pstool is run inside the
 temporary LyX directory and it thus cannot find the figures/ folder to
 write the .tex file to...

  AFAIK, LyX does not copy the .eps and .tex psfrag files to the
 temporary
 directory, because it does not parse the ERT for the psfragfig macro. I
 decided to reference the files under figures/ directly with absolute
 paths to the source dir. This does work via openout_any = a in
 texmf.cnf but then compiling foreign documents does not feel secure
 anymore...

 I read the LyX Customization manual under 'Copier' for a better
 solution, but could not find a reference to the LyX temporary directory
 and have no clue how to best solve this in terms of LyX policy.

 Michael



 The way I use psfrag is to insert the .eps into LyX using the standard
 way from the Insert menu, and put the psfrag code in ERT in the LyX
 document. This way, LyX handles the copying of the .eps file correctly.
 You obviously need the correct \usepackage line added to your preamble
 in document settings.


 Thanks for your comment. I somehow missed your answer after all this
 time...


Well, it took me quite some time to answer in the first place...


 I get how you mentioned the inclusion of the .eps file - I remember trying
 that initially. I also assume you mean `\usepackage{pstool}' as correct
 preamble line(?). However, I do not know what you mean by 'psfrag code'.


Actually, I just use \usepackage{psfrag} directly (\usepackage{pstool}
isn't necessary for pdf output via ps2pdf). The psfrag code that I refer to
is the content of the .tex file generated by matlabfrag alongside the .eps
file. I would be copy-pasting the content of the .tex file into an ERT, but
you could also input the .tex file via InsertFileChild Doc. What this
accomplishes corresponds to what is described at the beginning of section
4.2 of the matlabfrag userguide.pdf manual. If you need to use pdflatex,
you'll need the \usepackage{pstool} instead, but then I don't know how to
help you!

Hope this helps a bit more,
Cheers,
Julien


 Am I missing something?

 Michael




Re: Multiple citations

2013-07-02 Thread Julien Rioux

On 02/07/2013 11:17 AM, Elena Serioli wrote:

Ok, I created a little example, with a general father document, a
Chapter 1 and a Bibliography..

If you create a pdf of the general document I'll see that the second
citation isn't extended..


2013/7/2 Liviu Andronic landronim...@gmail.com
mailto:landronim...@gmail..com

Hello,


On Tue, Jul 2, 2013 at 3:18 PM, Elena serr...@gmail.com
mailto:serr...@gmail.com wrote:
  Hi everybody,
 
  I'm having some troubles with multiple citations in Lyx.
 
  When I have to cite more than one bibliographic note per time,
what I see in
  the PDF is the first citation extended and the other ones just as
the first
  author's letter..
 
  For example, if I cite Me et al, 2000; You et al, 2001; Them and
al, 2009,
  what I get is (Me and al, 2000, Y, T).
 
Could you provide us with a very small example of a LyX file and .bib
file that reproduce the issue? This way we can better investigate what
goes wrong.

Liviu




Hi,
Thanks for providing a small example. The problem is that you need to 
define the label correctly, according to the natbib style, in exactly 
the form Authors(2013). See the attached, corrected and simplified 
example.


Cheers,
Julien


example corrected.lyx
Description: application/lyx


Re: KOMA Script Letter 2: Continuation Page Headings

2013-07-02 Thread Julien Rioux

On 02/07/2013 11:17 AM, Rich Shepard wrote:

   In multipage business letters here in the US all continuation pages
should
have a header in the upper left of the page containing

Addressee's Name
Date as shown on page 1
Page number

   While I thought that the KOMA-Script Letter 2 configuration I use had
this
capability and how to do this was worked out years ago I don't have a
record
of how to do this in my saved messages and I am not finding the solution in
my Web searches.

   Please point me to a resource that explains how to add this continuation
page header.

Thanks in advance,

Rich



Hi Rich,

I could find this thread about it, where it seems that a solution was 
reached: 
http://lyx.475766.n2.nabble.com/Koma-Letter-2-Components-Sequence-td477936.html


Cheers,
Julien



Re: psfragfig

2013-07-02 Thread Julien Rioux
On Tue, Jul 2, 2013 at 2:50 PM, Michael Bach pha...@gmail.com wrote:

 Hi Julien,

 On 5/19/13 11:55 PM, Julien Rioux wrote:

 On 28/10/2012 6:01 AM, Michael Bach wrote:

 Ok, although I did not solve this in terms of LyX configuration: Just a
 quick notice for sake of completeness and in case someone is plagued by
 this issue and might be happy to find this.

 On 10/26/12 12:29 PM, Michael Bach wrote:

 Now when I try to compile the document, I see the line:
 === pstool: begin processing ===
 Error exporting to format
 pdf2/Users/Shared/LyX/lyx-2.0.**4/src/support/Systemcall.cpp(**273):
 Systemcall: 'pdflatex -synctex=-1 -shell-escape  skriptum.tex'
 finished with exit code 1

 in the messages pane and get the error:
 I can't write on file `figures/EulerExplizit-pstool.**tex'.

 Now I assume that the external command from pstool is run inside the
 temporary LyX directory and it thus cannot find the figures/ folder to
 write the .tex file to...

  AFAIK, LyX does not copy the .eps and .tex psfrag files to the
 temporary
 directory, because it does not parse the ERT for the psfragfig macro. I
 decided to reference the files under figures/ directly with absolute
 paths to the source dir. This does work via openout_any = a in
 texmf.cnf but then compiling foreign documents does not feel secure
 anymore...

 I read the LyX Customization manual under 'Copier' for a better
 solution, but could not find a reference to the LyX temporary directory
 and have no clue how to best solve this in terms of LyX policy.

 Michael



 The way I use psfrag is to insert the .eps into LyX using the standard
 way from the Insert menu, and put the psfrag code in ERT in the LyX
 document. This way, LyX handles the copying of the .eps file correctly.
 You obviously need the correct \usepackage line added to your preamble
 in document settings.


 Thanks for your comment. I somehow missed your answer after all this
 time...


Well, it took me quite some time to answer in the first place...


 I get how you mentioned the inclusion of the .eps file - I remember trying
 that initially. I also assume you mean `\usepackage{pstool}' as correct
 preamble line(?). However, I do not know what you mean by 'psfrag code'.


Actually, I just use \usepackage{psfrag} directly (\usepackage{pstool}
isn't necessary for pdf output via ps2pdf). The psfrag code that I refer to
is the content of the .tex file generated by matlabfrag alongside the .eps
file. I would be copy-pasting the content of the .tex file into an ERT, but
you could also input the .tex file via InsertFileChild Doc. What this
accomplishes corresponds to what is described at the beginning of section
4.2 of the matlabfrag userguide.pdf manual. If you need to use pdflatex,
you'll need the \usepackage{pstool} instead, but then I don't know how to
help you!

Hope this helps a bit more,
Cheers,
Julien


 Am I missing something?

 Michael




Re: Multiple citations

2013-07-02 Thread Julien Rioux

On 02/07/2013 11:17 AM, Elena Serioli wrote:

Ok, I created a little example, with a general father document, a
Chapter 1 and a Bibliography..

If you create a pdf of the general document I'll see that the second
citation isn't extended..


2013/7/2 Liviu Andronic landronim...@gmail.com
mailto:landronim...@gmail..com

Hello,


On Tue, Jul 2, 2013 at 3:18 PM, Elena serr...@gmail.com
mailto:serr...@gmail.com wrote:
  Hi everybody,
 
  I'm having some troubles with multiple citations in Lyx.
 
  When I have to cite more than one bibliographic note per time,
what I see in
  the PDF is the first citation extended and the other ones just as
the first
  author's letter..
 
  For example, if I cite Me et al, 2000; You et al, 2001; Them and
al, 2009,
  what I get is (Me and al, 2000, Y, T).
 
Could you provide us with a very small example of a LyX file and .bib
file that reproduce the issue? This way we can better investigate what
goes wrong.

Liviu




Hi,
Thanks for providing a small example. The problem is that you need to 
define the label correctly, according to the natbib style, in exactly 
the form Authors(2013). See the attached, corrected and simplified 
example.


Cheers,
Julien


example corrected.lyx
Description: application/lyx


Re: KOMA Script Letter 2: Continuation Page Headings

2013-07-02 Thread Julien Rioux

On 02/07/2013 11:17 AM, Rich Shepard wrote:

   In multipage business letters here in the US all continuation pages
should
have a header in the upper left of the page containing

Addressee's Name
Date as shown on page 1
Page number

   While I thought that the KOMA-Script Letter 2 configuration I use had
this
capability and how to do this was worked out years ago I don't have a
record
of how to do this in my saved messages and I am not finding the solution in
my Web searches.

   Please point me to a resource that explains how to add this continuation
page header.

Thanks in advance,

Rich



Hi Rich,

I could find this thread about it, where it seems that a solution was 
reached: 
http://lyx.475766.n2.nabble.com/Koma-Letter-2-Components-Sequence-td477936.html


Cheers,
Julien



Re: psfragfig

2013-07-02 Thread Julien Rioux
On Tue, Jul 2, 2013 at 2:50 PM, Michael Bach <pha...@gmail.com> wrote:

> Hi Julien,
>
> On 5/19/13 11:55 PM, Julien Rioux wrote:
>
>> On 28/10/2012 6:01 AM, Michael Bach wrote:
>>
>>> Ok, although I did not solve this in terms of LyX configuration: Just a
>>> quick notice for sake of completeness and in case someone is plagued by
>>> this issue and might be happy to find this.
>>>
>>> On 10/26/12 12:29 PM, Michael Bach wrote:
>>>
>>>> Now when I try to compile the document, I see the line:
>>>> === pstool: begin processing ===
>>>> Error exporting to format
>>>> pdf2/Users/Shared/LyX/lyx-2.0.**4/src/support/Systemcall.cpp(**273):
>>>> Systemcall: 'pdflatex -synctex=-1 -shell-escape  "skriptum.tex"'
>>>> finished with exit code 1
>>>>
>>>> in the messages pane and get the error:
>>>> I can't write on file `figures/EulerExplizit-pstool.**tex'.
>>>>
>>>> Now I assume that the external command from pstool is run inside the
>>>> temporary LyX directory and it thus cannot find the figures/ folder to
>>>> write the .tex file to...
>>>>
>>>>  AFAIK, LyX does not copy the .eps and .tex psfrag files to the
>>> temporary
>>> directory, because it does not parse the ERT for the psfragfig macro. I
>>> decided to reference the files under figures/ directly with absolute
>>> paths to the source dir. This does work via "openout_any = a" in
>>> texmf.cnf but then compiling foreign documents does not feel secure
>>> anymore...
>>>
>>> I read the LyX "Customization" manual under 'Copier' for a better
>>> solution, but could not find a reference to the LyX temporary directory
>>> and have no clue how to best solve this in terms of LyX policy.
>>>
>>> Michael
>>>
>>>
>>>
>> The way I use psfrag is to insert the .eps into LyX using the standard
>> way from the Insert menu, and put the psfrag code in ERT in the LyX
>> document. This way, LyX handles the copying of the .eps file correctly.
>> You obviously need the correct \usepackage line added to your preamble
>> in document settings.
>>
>>
> Thanks for your comment. I somehow missed your answer after all this
> time...
>
>
Well, it took me quite some time to answer in the first place...


> I get how you mentioned the inclusion of the .eps file - I remember trying
> that initially. I also assume you mean `\usepackage{pstool}' as correct
> preamble line(?). However, I do not know what you mean by 'psfrag code'.
>
>
Actually, I just use \usepackage{psfrag} directly (\usepackage{pstool}
isn't necessary for pdf output via ps2pdf). The psfrag code that I refer to
is the content of the .tex file generated by matlabfrag alongside the .eps
file. I would be copy-pasting the content of the .tex file into an ERT, but
you could also input the .tex file via "Insert>File>Child Doc". What this
accomplishes corresponds to what is described at the beginning of section
4.2 of the matlabfrag userguide.pdf manual. If you need to use pdflatex,
you'll need the \usepackage{pstool} instead, but then I don't know how to
help you!

Hope this helps a bit more,
Cheers,
Julien


> Am I missing something?
>
> Michael
>
>


Re: Multiple citations

2013-07-02 Thread Julien Rioux

On 02/07/2013 11:17 AM, Elena Serioli wrote:

Ok, I created a little example, with a general "father" document, a
"Chapter 1" and a Bibliography..

If you create a pdf of the general document I'll see that the second
citation isn't extended..


2013/7/2 Liviu Andronic >

Hello,


On Tue, Jul 2, 2013 at 3:18 PM, Elena > wrote:
 > Hi everybody,
 >
 > I'm having some troubles with multiple citations in Lyx.
 >
 > When I have to cite more than one bibliographic note per time,
what I see in
 > the PDF is the first citation extended and the other ones just as
the first
 > author's letter..
 >
 > For example, if I cite Me et al, 2000; You et al, 2001; Them and
al, 2009,
 > what I get is (Me and al, 2000, Y, T).
 >
Could you provide us with a very small example of a LyX file and .bib
file that reproduce the issue? This way we can better investigate what
goes wrong.

Liviu




Hi,
Thanks for providing a small example. The problem is that you need to 
define the label correctly, according to the natbib style, in exactly 
the form "Authors(2013)". See the attached, corrected and simplified 
example.


Cheers,
Julien


example corrected.lyx
Description: application/lyx


Re: KOMA Script Letter 2: Continuation Page Headings

2013-07-02 Thread Julien Rioux

On 02/07/2013 11:17 AM, Rich Shepard wrote:

   In multipage business letters here in the US all continuation pages
should
have a header in the upper left of the page containing

Addressee's Name
Date as shown on page 1
Page number

   While I thought that the KOMA-Script Letter 2 configuration I use had
this
capability and how to do this was worked out years ago I don't have a
record
of how to do this in my saved messages and I am not finding the solution in
my Web searches.

   Please point me to a resource that explains how to add this continuation
page header.

Thanks in advance,

Rich



Hi Rich,

I could find this thread about it, where it seems that a solution was 
reached: 
http://lyx.475766.n2.nabble.com/Koma-Letter-2-Components-Sequence-td477936.html


Cheers,
Julien



Re: hf-tikz.sty on fedora 16

2013-06-16 Thread Julien Rioux

On 06/06/2013 7:37 PM, Patrick Dupre wrote:

Hello,

I am trying to install hf-tikz.sty and colortbl.sty (from colortbl.zip) on a 
fedora 16.
Where should I installed them ?
I tried:
/usr/share/texmf/tex/latex/base
but there are not found.


Did you run texhash?


So I put them in a special directory where latex can read them, but
I get:
)) (/usr/share/texmf/tex/generic/pgf/frontendlayer/tikz.code.tex
Package: tikz 2006/10/17 v1.10 (rcs-revision 1.68)


This version of tikz is very old, and likely incompatible with hf-tikz.sty


(/usr/share/texmf/tex/generic/pgf/libraries/pgflibraryplothandlers.code.tex
File: pgflibraryplothandlers.code.tex 2006/10/16 v1.10 (rcs-revision 1.8)
\pgf@plot@mark@count=\count183
\pgfplotmarksize=\dimen232
)
\tikz@lastx=\dimen233
Normal \dimen register pool exhausted, switching to extended pool.
\tikz@lasty=\dimen256
\tikz@lastxsaved=\dimen257
\tikz@lastysaved=\dimen258
\tikzleveldistance=\dimen259
\tikzsiblingdistance=\dimen260
\tikz@figbox=\box84
\tikz@tempbox=\box85
\tikztreelevel=\count184
\tikznumberofchildren=\count185
\tikznumberofcurrentchild=\count186
\tikz@fig@count=\count187
\tikz@expandcount=\count188
(/usr/share/texmf/tex/generic/pgf/libraries/pgflibrarytikztopaths.code.tex
File: pgflibrarytikztopaths.code.tex 2006/10/16 v1.10 (rcs-revision 1.5)
)))
! I can't find file `pgflibrarytikzshadings.code.tex'.
argument ...t pgflibrarytikz\pgf@temp .code.tex
   \catcode `\@ =\csname tikz...
l.22 \usetikzlibrary{shadings}

Please type another input file name
! Emergency stop.
argument ...t pgflibrarytikz\pgf@temp .code.tex
   \catcode `\@ =\csname tikz...
l.22 \usetikzlibrary{shadings}

*** (job aborted, file error in nonstop mode)


I cannot find a pgflibrarytikzshadings.code.tex file.

What should I do?



Update your TeX distro.

--
Julien



Re: hf-tikz.sty on fedora 16

2013-06-16 Thread Julien Rioux

On 06/06/2013 7:37 PM, Patrick Dupre wrote:

Hello,

I am trying to install hf-tikz.sty and colortbl.sty (from colortbl.zip) on a 
fedora 16.
Where should I installed them ?
I tried:
/usr/share/texmf/tex/latex/base
but there are not found.


Did you run texhash?


So I put them in a special directory where latex can read them, but
I get:
)) (/usr/share/texmf/tex/generic/pgf/frontendlayer/tikz.code.tex
Package: tikz 2006/10/17 v1.10 (rcs-revision 1.68)


This version of tikz is very old, and likely incompatible with hf-tikz.sty


(/usr/share/texmf/tex/generic/pgf/libraries/pgflibraryplothandlers.code.tex
File: pgflibraryplothandlers.code.tex 2006/10/16 v1.10 (rcs-revision 1.8)
\pgf@plot@mark@count=\count183
\pgfplotmarksize=\dimen232
)
\tikz@lastx=\dimen233
Normal \dimen register pool exhausted, switching to extended pool.
\tikz@lasty=\dimen256
\tikz@lastxsaved=\dimen257
\tikz@lastysaved=\dimen258
\tikzleveldistance=\dimen259
\tikzsiblingdistance=\dimen260
\tikz@figbox=\box84
\tikz@tempbox=\box85
\tikztreelevel=\count184
\tikznumberofchildren=\count185
\tikznumberofcurrentchild=\count186
\tikz@fig@count=\count187
\tikz@expandcount=\count188
(/usr/share/texmf/tex/generic/pgf/libraries/pgflibrarytikztopaths.code.tex
File: pgflibrarytikztopaths.code.tex 2006/10/16 v1.10 (rcs-revision 1.5)
)))
! I can't find file `pgflibrarytikzshadings.code.tex'.
argument ...t pgflibrarytikz\pgf@temp .code.tex
   \catcode `\@ =\csname tikz...
l.22 \usetikzlibrary{shadings}

Please type another input file name
! Emergency stop.
argument ...t pgflibrarytikz\pgf@temp .code.tex
   \catcode `\@ =\csname tikz...
l.22 \usetikzlibrary{shadings}

*** (job aborted, file error in nonstop mode)


I cannot find a pgflibrarytikzshadings.code.tex file.

What should I do?



Update your TeX distro.

--
Julien



Re: hf-tikz.sty on fedora 16

2013-06-16 Thread Julien Rioux

On 06/06/2013 7:37 PM, Patrick Dupre wrote:

Hello,

I am trying to install hf-tikz.sty and colortbl.sty (from colortbl.zip) on a 
fedora 16.
Where should I installed them ?
I tried:
/usr/share/texmf/tex/latex/base
but there are not found.


Did you run texhash?


So I put them in a special directory where latex can read them, but
I get:
)) (/usr/share/texmf/tex/generic/pgf/frontendlayer/tikz.code.tex
Package: tikz 2006/10/17 v1.10 (rcs-revision 1.68)


This version of tikz is very old, and likely incompatible with hf-tikz.sty


(/usr/share/texmf/tex/generic/pgf/libraries/pgflibraryplothandlers.code.tex
File: pgflibraryplothandlers.code.tex 2006/10/16 v1.10 (rcs-revision 1.8)
\pgf@plot@mark@count=\count183
\pgfplotmarksize=\dimen232
)
\tikz@lastx=\dimen233
Normal \dimen register pool exhausted, switching to extended pool.
\tikz@lasty=\dimen256
\tikz@lastxsaved=\dimen257
\tikz@lastysaved=\dimen258
\tikzleveldistance=\dimen259
\tikzsiblingdistance=\dimen260
\tikz@figbox=\box84
\tikz@tempbox=\box85
\tikztreelevel=\count184
\tikznumberofchildren=\count185
\tikznumberofcurrentchild=\count186
\tikz@fig@count=\count187
\tikz@expandcount=\count188
(/usr/share/texmf/tex/generic/pgf/libraries/pgflibrarytikztopaths.code.tex
File: pgflibrarytikztopaths.code.tex 2006/10/16 v1.10 (rcs-revision 1.5)
)))
! I can't find file `pgflibrarytikzshadings.code.tex'.
 ...t pgflibrarytikz\pgf@temp .code.tex
   \catcode `\@ =\csname tikz...
l.22 \usetikzlibrary{shadings}

Please type another input file name
! Emergency stop.
 ...t pgflibrarytikz\pgf@temp .code.tex
   \catcode `\@ =\csname tikz...
l.22 \usetikzlibrary{shadings}

*** (job aborted, file error in nonstop mode)


I cannot find a pgflibrarytikzshadings.code.tex file.

What should I do?



Update your TeX distro.

--
Julien



Re: Document class missing after installation

2013-06-09 Thread Julien Rioux

On 07/06/2013 3:18 PM, Y.A. Sharif wrote:








Dear Rubin
Thank you very much for your quick reply. I am sorry for the delayed
response to your email. I went step by step according to your suggestions.
1. I could not find any configure.log file under
C:\users\...\Roaming\LyX 2.0. There was only one folder named cache
and a file outside the folder named session.
2.I tried to run configuration script in DOS windows: C:\Program
Files(x86)\LyX20\Python\Python.exe , this one did not show any error.
But when I ran the other one with configure.py it showed the following
messages:
File C:\Program Files (x86)\LyX 2.0\Resources\configure.py, line 11,
in , module
import  sys, os, re , shutil, glob, logging, subprocess
File C:\python25\lib\subprocess.py, line375, inmodule
import threading
File C:\python25\lib\threading.py, line 13, in module
from collections import deque
Import error: No module named collections

I again apologize for being little late to reply to the group and rubin.

I really appreciate your help and time.

Thank you very much.

Regards
Sharif


*From:* Paul A. Rubin ru...@msu.edu
*To:* Y.A. Sharif yasha...@yahoo.com
*Sent:* Friday, June 7, 2013 9:37 AM
*Subject:* Re: Document class missing after installation

Y.A.,

LyX creates a user directory for you, where it stores your preferences
and other local files. On my Windows 7 partition, the user directory
is C:\Users\Paul\AppData\Roaming\LyX2.0. If you have trouble finding it,
Help  About LyX should point you to it.

In that directory, there should be a text file named configure.log. (If
not, keep reading, I'll get to that case.) It's generated when the
Python configuration script runs. (This is script is both run at
installation and when you click Tools  Reconfigure in LyX.) In it, you
should see lines like the following:

INFO: checking for a Latex2e program...
INFO: +checking for latex...  yes
INFO: checking for a DVI postprocessing program...
INFO: +checking for pplatex...  yes

and eventually

INFO: checking for the pdflatex program...
INFO: +checking for pdflatex...  yes

If they read no, it means LyX failed to detect MiKTeX for some reason.
I've seen this happen when the user had Cygwin installed, for instance.
I don't know if it is still true, but Cygwin used to come with a broken
copy of LaTeX, and if Cygwin was in front of MiKTeX on the system
command path, LyX would test the Cygwin version of latex.exe and
conclude that there was no working LaTeX compiler on the system.

If the log shows that LyX found MiKTeX ('yes' responses), go back to a
DOS prompt and run 'kpsewhich article.cls' (if the article class is
missing according to LyX) and make sure that MiKTeX finds it. If that
looks correct, or if the log file is missing, then I suggest you cd to
your LyX user directory and run the configuration script in a DOS
window. The command line will look something like the following
(allowing for the possibility that your installation path is different):

C:\Program Files (x86)\LyX20\Python\python.exe C:\Program Files
(x86)\LyX20\Resources\configure.py

See if any error messages appear.

Paul

On 06/06/2013 06:44 PM, Y.A. Sharif wrote:


Thankk you Paul for your reply.
I have checked according to your suggestion. It shows in DOS prmopt
:this is pdfTeX, Version 3.14-...-1.40.13MiKTeX 2.9
But I could not understand your 2nd paragraph. Do you want me to check
the log generated by lyx ? Little confused, could you explain little more.
Thank you.


Y.A.Sharif



*From:* Paul Rubin ru...@msu.edu mailto:ru...@msu.edu
*To:* lyx-users@lists.lyx.org mailto:lyx-us...@lists..lyx.org
*Sent:* Thursday, June 6, 2013 3:11 PM
*Subject:* Re: Document class missing after installation

Is the MiKTeX bin directory on your system path? Can you run latex
--version
at a DOS prompt (without supplying a path to MiKTeX) and get a response
with a plausible version date?

If yes, take a look at the log generated by the installer (should be
in your user directory, I think) and see if it found a LaTeX installation.
You might want to publish the log to the list.

Paul












This looks to me like http://www.lyx.org/trac/ticket/8691 again.

--
Julien



Re: Document class missing after installation

2013-06-09 Thread Julien Rioux

On 07/06/2013 3:18 PM, Y.A. Sharif wrote:








Dear Rubin
Thank you very much for your quick reply. I am sorry for the delayed
response to your email. I went step by step according to your suggestions.
1. I could not find any configure.log file under
C:\users\...\Roaming\LyX 2.0. There was only one folder named cache
and a file outside the folder named session.
2.I tried to run configuration script in DOS windows: C:\Program
Files(x86)\LyX20\Python\Python.exe , this one did not show any error.
But when I ran the other one with configure.py it showed the following
messages:
File C:\Program Files (x86)\LyX 2.0\Resources\configure.py, line 11,
in , module
import  sys, os, re , shutil, glob, logging, subprocess
File C:\python25\lib\subprocess.py, line375, inmodule
import threading
File C:\python25\lib\threading.py, line 13, in module
from collections import deque
Import error: No module named collections

I again apologize for being little late to reply to the group and rubin.

I really appreciate your help and time.

Thank you very much.

Regards
Sharif


*From:* Paul A. Rubin ru...@msu.edu
*To:* Y.A. Sharif yasha...@yahoo.com
*Sent:* Friday, June 7, 2013 9:37 AM
*Subject:* Re: Document class missing after installation

Y.A.,

LyX creates a user directory for you, where it stores your preferences
and other local files. On my Windows 7 partition, the user directory
is C:\Users\Paul\AppData\Roaming\LyX2.0. If you have trouble finding it,
Help  About LyX should point you to it.

In that directory, there should be a text file named configure.log. (If
not, keep reading, I'll get to that case.) It's generated when the
Python configuration script runs. (This is script is both run at
installation and when you click Tools  Reconfigure in LyX.) In it, you
should see lines like the following:

INFO: checking for a Latex2e program...
INFO: +checking for latex...  yes
INFO: checking for a DVI postprocessing program...
INFO: +checking for pplatex...  yes

and eventually

INFO: checking for the pdflatex program...
INFO: +checking for pdflatex...  yes

If they read no, it means LyX failed to detect MiKTeX for some reason.
I've seen this happen when the user had Cygwin installed, for instance.
I don't know if it is still true, but Cygwin used to come with a broken
copy of LaTeX, and if Cygwin was in front of MiKTeX on the system
command path, LyX would test the Cygwin version of latex.exe and
conclude that there was no working LaTeX compiler on the system.

If the log shows that LyX found MiKTeX ('yes' responses), go back to a
DOS prompt and run 'kpsewhich article.cls' (if the article class is
missing according to LyX) and make sure that MiKTeX finds it. If that
looks correct, or if the log file is missing, then I suggest you cd to
your LyX user directory and run the configuration script in a DOS
window. The command line will look something like the following
(allowing for the possibility that your installation path is different):

C:\Program Files (x86)\LyX20\Python\python.exe C:\Program Files
(x86)\LyX20\Resources\configure.py

See if any error messages appear.

Paul

On 06/06/2013 06:44 PM, Y.A. Sharif wrote:


Thankk you Paul for your reply.
I have checked according to your suggestion. It shows in DOS prmopt
:this is pdfTeX, Version 3.14-...-1.40.13MiKTeX 2.9
But I could not understand your 2nd paragraph. Do you want me to check
the log generated by lyx ? Little confused, could you explain little more.
Thank you.


Y.A.Sharif



*From:* Paul Rubin ru...@msu.edu mailto:ru...@msu.edu
*To:* lyx-users@lists.lyx.org mailto:lyx-us...@lists..lyx.org
*Sent:* Thursday, June 6, 2013 3:11 PM
*Subject:* Re: Document class missing after installation

Is the MiKTeX bin directory on your system path? Can you run latex
--version
at a DOS prompt (without supplying a path to MiKTeX) and get a response
with a plausible version date?

If yes, take a look at the log generated by the installer (should be
in your user directory, I think) and see if it found a LaTeX installation.
You might want to publish the log to the list.

Paul












This looks to me like http://www.lyx.org/trac/ticket/8691 again.

--
Julien



Re: Document class missing after installation

2013-06-09 Thread Julien Rioux

On 07/06/2013 3:18 PM, Y.A. Sharif wrote:








Dear Rubin
Thank you very much for your quick reply. I am sorry for the delayed
response to your email. I went step by step according to your suggestions.
1. I could not find any configure.log file under
C:\users\...\Roaming\LyX 2.0. There was only one folder named "cache"
and a file outside the folder named "session".
2.I tried to run configuration script in DOS windows: C:\Program
Files(x86)\LyX20\Python\Python.exe , this one did not show any error.
But when I ran the other one with configure.py it showed the following
messages:
File "C:\Program Files (x86)\LyX 2.0\Resources\configure.py", line 11,
in , 
import  sys, os, re , shutil, glob, logging, subprocess
File "C:\python25\lib\subprocess.py", line375, in
import threading
File "C:\python25\lib\threading.py", line 13, in 
from collections import deque
Import error: No module named collections

I again apologize for being little late to reply to the group and rubin.

I really appreciate your help and time.

Thank you very much.

Regards
Sharif


*From:* Paul A. Rubin 
*To:* Y.A. Sharif 
*Sent:* Friday, June 7, 2013 9:37 AM
*Subject:* Re: Document class missing after installation

Y.A.,

LyX creates a user directory for you, where it stores your preferences
and other "local" files. On my Windows 7 partition, the user directory
is C:\Users\Paul\AppData\Roaming\LyX2.0. If you have trouble finding it,
Help > About LyX should point you to it.

In that directory, there should be a text file named configure.log. (If
not, keep reading, I'll get to that case.) It's generated when the
Python configuration script runs. (This is script is both run at
installation and when you click Tools > Reconfigure in LyX.) In it, you
should see lines like the following:

INFO: checking for a Latex2e program...
INFO: +checking for "latex"...  yes
INFO: checking for a DVI postprocessing program...
INFO: +checking for "pplatex"...  yes

and eventually

INFO: checking for the pdflatex program...
INFO: +checking for "pdflatex"...  yes

If they read "no", it means LyX failed to detect MiKTeX for some reason.
I've seen this happen when the user had Cygwin installed, for instance.
I don't know if it is still true, but Cygwin used to come with a broken
copy of LaTeX, and if Cygwin was in front of MiKTeX on the system
command path, LyX would test the Cygwin version of latex.exe and
conclude that there was no working LaTeX compiler on the system.

If the log shows that LyX found MiKTeX ('yes' responses), go back to a
DOS prompt and run 'kpsewhich article.cls' (if the article class is
"missing" according to LyX) and make sure that MiKTeX finds it. If that
looks correct, or if the log file is missing, then I suggest you cd to
your LyX user directory and run the configuration script in a DOS
window. The command line will look something like the following
(allowing for the possibility that your installation path is different):

"C:\Program Files (x86)\LyX20\Python\python.exe" "C:\Program Files
(x86)\LyX20\Resources\configure.py"

See if any error messages appear.

Paul

On 06/06/2013 06:44 PM, Y.A. Sharif wrote:


Thankk you Paul for your reply.
I have checked according to your suggestion. It shows in DOS prmopt
:"this is pdfTeX, Version 3.14-...-1.40.13
But I could not understand your 2nd paragraph. Do you want me to check
the log generated by lyx ? Little confused, could you explain little more.
Thank you.


Y.A.Sharif



*From:* Paul Rubin  
*To:* lyx-users@lists.lyx.org 
*Sent:* Thursday, June 6, 2013 3:11 PM
*Subject:* Re: Document class missing after installation

Is the MiKTeX bin directory on your system path? Can you run "latex
--version"
at a DOS prompt (without supplying a path to MiKTeX) and get a response
with a plausible version date?

If yes, take a look at the log generated by the installer (should be
in your user directory, I think) and see if it found a LaTeX installation.
You might want to publish the log to the list.

Paul












This looks to me like http://www.lyx.org/trac/ticket/8691 again.

--
Julien



Re: disable package

2013-05-21 Thread Julien Rioux

On 21/05/2013 11:21 AM, Patrick Dupre wrote:

Hello,

lyx (2.0.5) make a
\usepackage{bm} that I am unable to control. Why?

I need to make a
\usepackage{fourier,bm}
and not
\usepackage{bm,fourier}

How can I do it?

Thank.

===
  Patrick DUPRÉ | | email: pdu...@gmx.com
  Laboratoire de Physico-Chimie de l'Atmosphère | |
  Université du Littoral-Côte d'Opale   | |
  Tel.  (33)-(0)3 28 23 76 12   | | Fax: 03 28 65 82 44
  189A, avenue Maurice Schumann | | 59140 Dunkerque, France
===



In document settings:
Edit the local layout to tell LyX that we are providing bm ourself:

Format 35
Provides bm true

Edit the preamble to add our packages in the desired order:

\usepackage{fourier}
\usepackage{bm}

See attached :)

Cordialement,
Julien


newfile1.lyx
Description: application/lyx


Re: Specifying a path prefix in a LaTeX macro

2013-05-21 Thread Julien Rioux

On 09/05/2013 1:11 PM, Stephen Brooking wrote:

I've tried the same under Windows (I need this to work with LyX under
Windows), setting an environment variable to point to a path (and
reconfiguring and restarting LyX just in case), and specifying that path as
my \filepath, but I still get the same 'I can't write on file
`path/testreq1.tex' error.


Just to add a bit more information, if I try this from a Windows command
prompt I get the same error.
kpsewhich tells me that TEXMFOUTPUT is set to what I think it is set to:


kpsewhich --var-value=TEXMFOUTPUT

C:\docs

! I can't write on file `C:\docs\testreq1.tex'

If I remove the path setting from my test.tex file so I basically have this:


\newwrite\tempfile
\immediate\openout\tempfile=testreq1.tex
\immediate\write\tempfile{Some text}
\immediate\closeout\tempfile

\input{C:/docs/testreq1.tex}


and set the -output-directory command line option to pdflatex:


pdflatex -output-directory C:\docs test.tex


It all works, so I know that I can write files to that directory.  (Setting
the -output-directory like this though with LyX has the downside that LyX
then can't find the output PDF file as it isn't in the temp directory that
it expects.)

Also to note, it also works if I set -output-directory to %TEXMFOUTPUT%.

So, any clues as to why this doesn't work when just relying on the
TEXMFOUTPUT variable, without setting -output-directory?

Thanks and regards,

Steve




I think you need to set openout_any accordingly. In any case, first make 
sure this works with latex from the command line, only then should you 
try to do the same from within LyX.


Cheers,
Julien



Re: Export XHTML and Branches

2013-05-21 Thread Julien Rioux

On 02/05/2013 11:10 AM, Jean-Louis GALLINARI wrote:

I receive this message :

Signal SIGSEGV perçu

and I'm asked to send a bug-report then Lyx crashes when I close the
window by clicking ok





I also did not have any problem exporting to either HTML (with htlatex) 
or LyXHTML. Which converter are you using?


--
Julien



Re: ACM SIGPLAN class and template: problem with terms keywords

2013-05-21 Thread Julien Rioux

On 21/10/2012 2:51 AM, Gabi Kedma wrote:

Hi,
I have the following problem:
I am working with the ACM sigplan class and template.
It requires me to specify both 'General Terms' and 'Keywords'.
The template uses:
\begin_layout Terms
and
\begin_layout Keywords
However, when I convert this to PDF, both appear on the PDF as 'General
Terms'.
(It shows 'General Terms' twice, once with the terms, and once with the
keywords).
What should I do to solve this problem?
Thanks,
Gabi


This has been corrected: http://www.lyx.org/trac/ticket/8378
--
Julien



Re: disable package

2013-05-21 Thread Julien Rioux

On 21/05/2013 1:20 PM, Scott Kostyshak wrote:

On Tue, May 21, 2013 at 12:53 PM, Julien Rioux jri...@lyx.org wrote:

In document settings:
Edit the local layout to tell LyX that we are providing bm ourself:

Format 35
Provides bm true


Note that (on 2.1git) LyX gives the following warning:
LyX: Bad integer `true' [around line 2 of file
/tmp/lyx_tmpdir.rDYhXLs25464/convert_layout.ELJOAZs25464 current
token: 'true' context: '']

Changing true to 1 fixes this for me.
Should the layout validator in Document Settings catch this (it
currently does not)? I know it is not supposed to be too strict but
wanted to check anyway.

Scott



That's just me writing this layout snippet from memory. The correct 
documented usage is indeed 1 or 0.


Interestingly, if I replace by false, I get the same effect as if I 
had typed 1. LyX seems to accept anything different from 0 as true, 
while the script that updates the format from 35 to X seems stricter on 
this (X being, current LyX 2.1git format).


--
Julien



Re: LyX ; look up `weird error' in the index to The TeXbook.)

2013-05-21 Thread Julien Rioux

On 28/03/2013 1:58 PM, John Kane wrote:

LyX 2.0.5.1 Ubuntu 12.10

I am trying to import and run a LateX file in LyX. The problem arises
when I have a figure with subfigures.  A single figure processes with no
problem.

The file is fine in LaTeX but chokes in Lyx. I have seen a few
references to the problem on the internet but I have not seen any
solution that makes sense to me. The closest thing seems to be
http://tex.stackexchange.com/questions/19946/missing-number-treated-as-zero
but since it is referring to a LaTeX problem not a LyX problem it does
not help.

The original file produces 14 pages of pdf output with 12 figures both
single and multiple layouts with no problems and so I thought I'd see
how well it imports into LyX

I have attached a stripped-down .tex file and two png files that I am
using as a test case. I imported the .tex file into LyX using File 
Import  Latex(plain)...

The error message is :
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Missing number, treated as zero.
Illegal unit of measure (pt inserted).

Description:
\centering \begin{subfigure}{[}
b{]}{0.5\textwidth} \centering
A number should have been here; I inserted `0'.
(If you can't figure out why I needed to see a number,
look up `weird error' in the index to The TeXbook.)

When I look at the LaTeX Preamble in LyX I get:
\usepackage[hang,flushmargin]{footmisc}\usepackage[english]{babel}
\usepackage[font={small,it}]{caption}\usepackage{subcaption}\author{John
the Toucanite}
\title{The Scholar}

My LaTeX preamble is
\documentclass[12pt]{article}
\usepackage[margin = 4.0 cm]{geometry}
\usepackage[hang,flushmargin]{footmisc}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[english]{babel}
\usepackage{graphicx}
\usepackage[font={small,it}]{caption}
\usepackage{subcaption}
\author{John the Toucanite}
\title{The Scholar}
\date{}

I tried pasting the LaTeX preamble into LyX and removed
\documentclass[12pt]{article}
\usepackage[margin = 4.0 cm]{geometry}
since they were giving me conflicts.

I still get the same error.







Indeed, \begin{subfigure}[h]{0.5\textwidth} isn't parsed correctly by 
tex2lyx: It is put into ERT except that [h] ends up outside of ERT. On 
LaTeX output, LyX tries to protect the square brackets by outputting 
{[}h{]}, but this is incorrect LaTeX.


Just checked and this bug is also in the development version LyX 2.1

--
Julien



Re: using LyX to write AGU journal articles

2013-05-21 Thread Julien Rioux

On 10/07/2012 7:33 PM, Kristoffer Walker wrote:

Folks,

I am trying to write an AGU journal article using the AGU document class in 
LyX, a front-end to MacTex.  I have been able to generate a good looking 
manuscript with LyX, with one important caveat: the compiled manuscript fails 
to include the Abstract.  I have determined the problem is that the AGU 
document class expects the following missing statement just after the abstract 
definition:

/begin{article}

Similarly, a /end{article} is needed at the end of the document, just before 
the /end{document}.

I can of course write in LyX and then ultimately export to *.tex in the end, 
add the lines, recompile, and submit the manuscript, but is there a better way 
to fix this?  For example, can I edit a Layout file or similar to have these 
things done automatically so that the Abstract will show up from a compilation 
within LyX?

Thank you,
Kris Walker


I've just opened http://www.lyx.org/trac/ticket/8689 for this issue.

Cheers,
Julien



Re: LyX ; look up `weird error' in the index to The TeXbook.)

2013-05-21 Thread Julien Rioux

On 21/05/2013 2:26 PM, John Kane wrote:

Julian,
Thanks for the explanation.


I've just opened http://www.lyx.org/trac/ticket/8690 for this issue.

Cheers,
Julien



Re: conflict between LyX and Gimp for the use of python

2013-05-21 Thread Julien Rioux

On 11/05/2012 10:50 AM, Alex Vergara Gil wrote:

Hello LyXers!

I have a system with windows 7 which have previously installed python
2.6 for the use of GIMP, this sofware do use python for a lot of things
so I cannot remove it from the system. I want to install LyX in this
system but when I do that all goes wrong because all the python scripts
refers to the python 2.6 already installed instead of the correct python
inside LyX. Is there a way to tell LyX that he must use the python
located inside it and not the python of the system? I cannot found
anything such a python executable location variable neither in LyX nor
in registry.

My problem goes further than just converters, which behaves wrong in
almost all the cases, it refers to the entire LyX system which use a lot
of python scripts and there are a lot of errors when for example
reconfiguring.

LyX 2.0.0, GIMP 2.6.11, python 2.6 in the system, windows 7... if you
need anything else to answer let me know.

Greetings
~-o--{}--o-~
Alex Vergara Gil
MSc. Física Nuclear
Laboratorio Secundario de Calibración Dosimétrica
Centro de Protección e Higiene de las Radiaciones
Calle 20 No. 4113 e/ 18A y 47 Playa
La Habana, Cuba
A.P.6195 C.P.10600
Telf: (537)6824892, (537)6821803
Fax: (537)2030165





http://www.lyx.org/trac/ticket/8691

--
Julien



Re: Remove the automatically added amssymb

2013-05-21 Thread Julien Rioux

On 20/05/2013 7:54 PM, Uwe Stöhr wrote:

Am 20.05.2013 03:33, schrieb dianzi@gmail.com:


Removing the amssymb is the official solution to the conflict problem
between them. You can see it on the web of mtpro2.


I cannot test this because mtpro2 is not part of MiKTeX and TeXLive
because of its license. Seems it is not free.

However, it is a bug that a font package cannot handle the amsmath
packages. amsmath is the de-facto standard for years in the LaTeX world
and that is the first time I heard they cannot be handled. Please report
this as bug to the mtpro2 developers to get this fixed.

As amsmath is standard LyX does not offer a way to remove the amssymb
package. Maybe you can do it via the document preamble that is placed
after the call of amssymb.



As Paul Rubin commented (if you did not see his reply, concider 
subscribing to the list) there is indeed a way to suppress amssymb. You 
can use the module that he provided or directly put the following in 
document settings  local layout:


Format 35
Provides amssymb 1

But then it is up to you to make sure any needed macro is defined.

Cheers,
Julien



Re: Remove the automatically added amssymb

2013-05-21 Thread Julien Rioux

On 20/05/2013 7:54 PM, Uwe Stöhr wrote:

Am 20.05.2013 03:33, schrieb dianzi@gmail.com:


Removing the amssymb is the official solution to the conflict problem
between them. You can see it on the web of mtpro2.


I cannot test this because mtpro2 is not part of MiKTeX and TeXLive
because of its license. Seems it is not free.

However, it is a bug that a font package cannot handle the amsmath
packages. amsmath is the de-facto standard for years in the LaTeX world
and that is the first time I heard they cannot be handled. Please report
this as bug to the mtpro2 developers to get this fixed.

As amsmath is standard LyX does not offer a way to remove the amssymb
package. Maybe you can do it via the document preamble that is placed
after the call of amssymb.



As Paul Rubin commented (if you did not see his reply, concider 
subscribing to the list) there is indeed a way to suppress amssymb. You 
can use the module that he provided or directly put the following in 
document settings  local layout:


Format 35
Provides amssymb 1

But then it is up to you to make sure any needed macro is defined.

Cheers,
Julien


Re: using LyX to write AGU journal articles

2013-05-21 Thread Julien Rioux
On Tue, May 21, 2013 at 6:34 PM, Kristoffer Walker kwal...@ucsd.edu wrote:

 Thanks, but I've moved to a different Latex program already.  Your
 response may have been more helpful to me six months ago.

 Kris


Sorry to hear that. All the best in your endeavours!
Cheers,
Julien


Re: disable package

2013-05-21 Thread Julien Rioux

On 21/05/2013 11:21 AM, Patrick Dupre wrote:

Hello,

lyx (2.0.5) make a
\usepackage{bm} that I am unable to control. Why?

I need to make a
\usepackage{fourier,bm}
and not
\usepackage{bm,fourier}

How can I do it?

Thank.

===
  Patrick DUPRÉ | | email: pdu...@gmx.com
  Laboratoire de Physico-Chimie de l'Atmosphère | |
  Université du Littoral-Côte d'Opale   | |
  Tel.  (33)-(0)3 28 23 76 12   | | Fax: 03 28 65 82 44
  189A, avenue Maurice Schumann | | 59140 Dunkerque, France
===



In document settings:
Edit the local layout to tell LyX that we are providing bm ourself:

Format 35
Provides bm true

Edit the preamble to add our packages in the desired order:

\usepackage{fourier}
\usepackage{bm}

See attached :)

Cordialement,
Julien


newfile1.lyx
Description: application/lyx


Re: Specifying a path prefix in a LaTeX macro

2013-05-21 Thread Julien Rioux

On 09/05/2013 1:11 PM, Stephen Brooking wrote:

I've tried the same under Windows (I need this to work with LyX under
Windows), setting an environment variable to point to a path (and
reconfiguring and restarting LyX just in case), and specifying that path as
my \filepath, but I still get the same 'I can't write on file
`path/testreq1.tex' error.


Just to add a bit more information, if I try this from a Windows command
prompt I get the same error.
kpsewhich tells me that TEXMFOUTPUT is set to what I think it is set to:


kpsewhich --var-value=TEXMFOUTPUT

C:\docs

! I can't write on file `C:\docs\testreq1.tex'

If I remove the path setting from my test.tex file so I basically have this:


\newwrite\tempfile
\immediate\openout\tempfile=testreq1.tex
\immediate\write\tempfile{Some text}
\immediate\closeout\tempfile

\input{C:/docs/testreq1.tex}


and set the -output-directory command line option to pdflatex:


pdflatex -output-directory C:\docs test.tex


It all works, so I know that I can write files to that directory.  (Setting
the -output-directory like this though with LyX has the downside that LyX
then can't find the output PDF file as it isn't in the temp directory that
it expects.)

Also to note, it also works if I set -output-directory to %TEXMFOUTPUT%.

So, any clues as to why this doesn't work when just relying on the
TEXMFOUTPUT variable, without setting -output-directory?

Thanks and regards,

Steve




I think you need to set openout_any accordingly. In any case, first make 
sure this works with latex from the command line, only then should you 
try to do the same from within LyX.


Cheers,
Julien



Re: Export XHTML and Branches

2013-05-21 Thread Julien Rioux

On 02/05/2013 11:10 AM, Jean-Louis GALLINARI wrote:

I receive this message :

Signal SIGSEGV perçu

and I'm asked to send a bug-report then Lyx crashes when I close the
window by clicking ok





I also did not have any problem exporting to either HTML (with htlatex) 
or LyXHTML. Which converter are you using?


--
Julien



Re: ACM SIGPLAN class and template: problem with terms keywords

2013-05-21 Thread Julien Rioux

On 21/10/2012 2:51 AM, Gabi Kedma wrote:

Hi,
I have the following problem:
I am working with the ACM sigplan class and template.
It requires me to specify both 'General Terms' and 'Keywords'.
The template uses:
\begin_layout Terms
and
\begin_layout Keywords
However, when I convert this to PDF, both appear on the PDF as 'General
Terms'.
(It shows 'General Terms' twice, once with the terms, and once with the
keywords).
What should I do to solve this problem?
Thanks,
Gabi


This has been corrected: http://www.lyx.org/trac/ticket/8378
--
Julien



Re: disable package

2013-05-21 Thread Julien Rioux

On 21/05/2013 1:20 PM, Scott Kostyshak wrote:

On Tue, May 21, 2013 at 12:53 PM, Julien Rioux jri...@lyx.org wrote:

In document settings:
Edit the local layout to tell LyX that we are providing bm ourself:

Format 35
Provides bm true


Note that (on 2.1git) LyX gives the following warning:
LyX: Bad integer `true' [around line 2 of file
/tmp/lyx_tmpdir.rDYhXLs25464/convert_layout.ELJOAZs25464 current
token: 'true' context: '']

Changing true to 1 fixes this for me.
Should the layout validator in Document Settings catch this (it
currently does not)? I know it is not supposed to be too strict but
wanted to check anyway.

Scott



That's just me writing this layout snippet from memory. The correct 
documented usage is indeed 1 or 0.


Interestingly, if I replace by false, I get the same effect as if I 
had typed 1. LyX seems to accept anything different from 0 as true, 
while the script that updates the format from 35 to X seems stricter on 
this (X being, current LyX 2.1git format).


--
Julien



Re: LyX ; look up `weird error' in the index to The TeXbook.)

2013-05-21 Thread Julien Rioux

On 28/03/2013 1:58 PM, John Kane wrote:

LyX 2.0.5.1 Ubuntu 12.10

I am trying to import and run a LateX file in LyX. The problem arises
when I have a figure with subfigures.  A single figure processes with no
problem.

The file is fine in LaTeX but chokes in Lyx. I have seen a few
references to the problem on the internet but I have not seen any
solution that makes sense to me. The closest thing seems to be
http://tex.stackexchange.com/questions/19946/missing-number-treated-as-zero
but since it is referring to a LaTeX problem not a LyX problem it does
not help.

The original file produces 14 pages of pdf output with 12 figures both
single and multiple layouts with no problems and so I thought I'd see
how well it imports into LyX

I have attached a stripped-down .tex file and two png files that I am
using as a test case. I imported the .tex file into LyX using File 
Import  Latex(plain)...

The error message is :
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Illegal unit of measure (pt inserted).
Missing number, treated as zero.
Missing number, treated as zero.
Illegal unit of measure (pt inserted).

Description:
\centering \begin{subfigure}{[}
b{]}{0.5\textwidth} \centering
A number should have been here; I inserted `0'.
(If you can't figure out why I needed to see a number,
look up `weird error' in the index to The TeXbook.)

When I look at the LaTeX Preamble in LyX I get:
\usepackage[hang,flushmargin]{footmisc}\usepackage[english]{babel}
\usepackage[font={small,it}]{caption}\usepackage{subcaption}\author{John
the Toucanite}
\title{The Scholar}

My LaTeX preamble is
\documentclass[12pt]{article}
\usepackage[margin = 4.0 cm]{geometry}
\usepackage[hang,flushmargin]{footmisc}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[english]{babel}
\usepackage{graphicx}
\usepackage[font={small,it}]{caption}
\usepackage{subcaption}
\author{John the Toucanite}
\title{The Scholar}
\date{}

I tried pasting the LaTeX preamble into LyX and removed
\documentclass[12pt]{article}
\usepackage[margin = 4.0 cm]{geometry}
since they were giving me conflicts.

I still get the same error.







Indeed, \begin{subfigure}[h]{0.5\textwidth} isn't parsed correctly by 
tex2lyx: It is put into ERT except that [h] ends up outside of ERT. On 
LaTeX output, LyX tries to protect the square brackets by outputting 
{[}h{]}, but this is incorrect LaTeX.


Just checked and this bug is also in the development version LyX 2.1

--
Julien



Re: using LyX to write AGU journal articles

2013-05-21 Thread Julien Rioux

On 10/07/2012 7:33 PM, Kristoffer Walker wrote:

Folks,

I am trying to write an AGU journal article using the AGU document class in 
LyX, a front-end to MacTex.  I have been able to generate a good looking 
manuscript with LyX, with one important caveat: the compiled manuscript fails 
to include the Abstract.  I have determined the problem is that the AGU 
document class expects the following missing statement just after the abstract 
definition:

/begin{article}

Similarly, a /end{article} is needed at the end of the document, just before 
the /end{document}.

I can of course write in LyX and then ultimately export to *.tex in the end, 
add the lines, recompile, and submit the manuscript, but is there a better way 
to fix this?  For example, can I edit a Layout file or similar to have these 
things done automatically so that the Abstract will show up from a compilation 
within LyX?

Thank you,
Kris Walker


I've just opened http://www.lyx.org/trac/ticket/8689 for this issue.

Cheers,
Julien



  1   2   3   4   5   6   7   8   9   10   >