Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

rgheck wrote:

This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to 
the theorem
Try the attached. You'll get a warning about counter redefinition, but 
it works.


Thanks, but it works and it doesn't : The theorems are displayed in LyX 
with sequential numbering, but when I try to compile the file into dvi 
using Ctrl-D, I get the same error as before : \theoremstyle is not 
defined.


--Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

Geevarghese Philip wrote:

rgheck wrote:


...
Try the attached. You'll get a warning about counter redefinition, but 
it works.


Thanks, but it works and it doesn't snip


I made a small change to the layout file you sent, and it works 
wonderfully now. Except that I somehow have a feeling that it is an ugly 
hack... I have attached the layout that works -- both for the LyX 
display and for the generated outputs.


Thanks for your help.

-- Philip


#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input amsmaths-seq.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
Series  Bold
SizeHuge
EndFont
End

Style Standard
   Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{thm}{Theorem}
   EndPreamble
End


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Richard Heck

Geevarghese Philip wrote:

rgheck wrote:

This works as intended for the dvi/ps/pdf versions. I guess I am 
being greedy, but if only I could make LyX display the theorems with 
a sequential numbering, instead of prepending the subsection number 
to the theorem
Try the attached. You'll get a warning about counter redefinition, 
but it works.


Thanks, but it works and it doesn't : The theorems are displayed in 
LyX with sequential numbering, but when I try to compile the file into 
dvi using Ctrl-D, I get the same error as before : \theoremstyle is 
not defined.


That's very odd. I compiled it and it worked fine for me. Are you using 
at least one theorem? Or are you only using other things, like corollaries?


rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Richard Heck

Geevarghese Philip wrote:

Geevarghese Philip wrote:

rgheck wrote:


...
Try the attached. You'll get a warning about counter redefinition, 
but it works.


Thanks, but it works and it doesn't snip


I made a small change to the layout file you sent, and it works 
wonderfully now. Except that I somehow have a feeling that it is an 
ugly hack... I have attached the layout that works -- both for the LyX 
display and for the generated outputs.


It's a hack, but if it works, it works. Layout editing is a major 
hackfast anyway.


rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

Richard Heck wrote:

Geevarghese Philip wrote:


Thanks, but it works and it doesn't : The theorems are displayed in 
LyX with sequential numbering, but when I try to compile the file into 
dvi using Ctrl-D, I get the same error as before : \theoremstyle is 
not defined.


That's very odd. I compiled it and it worked fine for me. Are you using 
at least one theorem? Or are you only using other things, like corollaries?




I was using other things only, such as lemmas and definitions: no 
theorem per se.


Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

rgheck wrote:

This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to 
the theorem
Try the attached. You'll get a warning about counter redefinition, but 
it works.


Thanks, but it works and it doesn't : The theorems are displayed in LyX 
with sequential numbering, but when I try to compile the file into dvi 
using Ctrl-D, I get the same error as before : \theoremstyle is not 
defined.


--Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

Geevarghese Philip wrote:

rgheck wrote:


...
Try the attached. You'll get a warning about counter redefinition, but 
it works.


Thanks, but it works and it doesn't snip


I made a small change to the layout file you sent, and it works 
wonderfully now. Except that I somehow have a feeling that it is an ugly 
hack... I have attached the layout that works -- both for the LyX 
display and for the generated outputs.


Thanks for your help.

-- Philip


#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input amsmaths-seq.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
Series  Bold
SizeHuge
EndFont
End

Style Standard
   Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{thm}{Theorem}
   EndPreamble
End


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Richard Heck

Geevarghese Philip wrote:

rgheck wrote:

This works as intended for the dvi/ps/pdf versions. I guess I am 
being greedy, but if only I could make LyX display the theorems with 
a sequential numbering, instead of prepending the subsection number 
to the theorem
Try the attached. You'll get a warning about counter redefinition, 
but it works.


Thanks, but it works and it doesn't : The theorems are displayed in 
LyX with sequential numbering, but when I try to compile the file into 
dvi using Ctrl-D, I get the same error as before : \theoremstyle is 
not defined.


That's very odd. I compiled it and it worked fine for me. Are you using 
at least one theorem? Or are you only using other things, like corollaries?


rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Richard Heck

Geevarghese Philip wrote:

Geevarghese Philip wrote:

rgheck wrote:


...
Try the attached. You'll get a warning about counter redefinition, 
but it works.


Thanks, but it works and it doesn't snip


I made a small change to the layout file you sent, and it works 
wonderfully now. Except that I somehow have a feeling that it is an 
ugly hack... I have attached the layout that works -- both for the LyX 
display and for the generated outputs.


It's a hack, but if it works, it works. Layout editing is a major 
hackfast anyway.


rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

Richard Heck wrote:

Geevarghese Philip wrote:


Thanks, but it works and it doesn't : The theorems are displayed in 
LyX with sequential numbering, but when I try to compile the file into 
dvi using Ctrl-D, I get the same error as before : \theoremstyle is 
not defined.


That's very odd. I compiled it and it worked fine for me. Are you using 
at least one theorem? Or are you only using other things, like corollaries?




I was using other things only, such as lemmas and definitions: no 
theorem per se.


Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

rgheck wrote:

This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to 
the theorem
Try the attached. You'll get a warning about counter redefinition, but 
it works.


Thanks, but it works and it doesn't : The theorems are displayed in LyX 
with sequential numbering, but when I try to compile the file into dvi 
using Ctrl-D, I get the same error as before : \theoremstyle is not 
defined.


--Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

Geevarghese Philip wrote:

rgheck wrote:


...
Try the attached. You'll get a warning about counter redefinition, but 
it works.


Thanks, but it works and it doesn't 


I made a small change to the layout file you sent, and it works 
wonderfully now. Except that I somehow have a feeling that it is an ugly 
hack... I have attached the layout that works -- both for the LyX 
display and for the generated outputs.


Thanks for your help.

-- Philip


#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input amsmaths-seq.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   "Bibliography"
LabelFont
Series  Bold
SizeHuge
EndFont
End

Style Standard
   Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{thm}{Theorem}
   EndPreamble
End


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Richard Heck

Geevarghese Philip wrote:

rgheck wrote:

This works as intended for the dvi/ps/pdf versions. I guess I am 
being greedy, but if only I could make LyX display the theorems with 
a sequential numbering, instead of prepending the subsection number 
to the theorem
Try the attached. You'll get a warning about counter redefinition, 
but it works.


Thanks, but it works and it doesn't : The theorems are displayed in 
LyX with sequential numbering, but when I try to compile the file into 
dvi using Ctrl-D, I get the same error as before : \theoremstyle is 
not defined.


That's very odd. I compiled it and it worked fine for me. Are you using 
at least one theorem? Or are you only using other things, like corollaries?


rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Richard Heck

Geevarghese Philip wrote:

Geevarghese Philip wrote:

rgheck wrote:


...
Try the attached. You'll get a warning about counter redefinition, 
but it works.


Thanks, but it works and it doesn't 


I made a small change to the layout file you sent, and it works 
wonderfully now. Except that I somehow have a feeling that it is an 
ugly hack... I have attached the layout that works -- both for the LyX 
display and for the generated outputs.


It's a hack, but if it works, it works. Layout editing is a major 
hackfast anyway.


rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-31 Thread Geevarghese Philip

Richard Heck wrote:

Geevarghese Philip wrote:


Thanks, but it works and it doesn't : The theorems are displayed in 
LyX with sequential numbering, but when I try to compile the file into 
dvi using Ctrl-D, I get the same error as before : \theoremstyle is 
not defined.


That's very odd. I compiled it and it worked fine for me. Are you using 
at least one theorem? Or are you only using other things, like corollaries?




I was using other things only, such as lemmas and definitions: no 
theorem per se.


Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-28 Thread rgheck

Geevarghese Philip wrote:

Geevarghese Philip wrote:

Geevarghese Philip wrote:
the layout file you attached solves my problem of getting sequential 
theorems,


This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to 
the theorem
Try the attached. You'll get a warning about counter redefinition, but 
it works.


rh

#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End

Input amsdefs.inc
Input amsmaths-seq.inc


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-28 Thread rgheck

Geevarghese Philip wrote:

Geevarghese Philip wrote:

Geevarghese Philip wrote:
the layout file you attached solves my problem of getting sequential 
theorems,


This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to 
the theorem
Try the attached. You'll get a warning about counter redefinition, but 
it works.


rh

#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End

Input amsdefs.inc
Input amsmaths-seq.inc


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-28 Thread rgheck

Geevarghese Philip wrote:

Geevarghese Philip wrote:

Geevarghese Philip wrote:
the layout file you attached solves my problem of getting sequential 
theorems,


This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to 
the theorem
Try the attached. You'll get a warning about counter redefinition, but 
it works.


rh

#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   "Bibliography"
LabelFont
  Series  Bold
  SizeHuge
EndFont
End

Input amsdefs.inc
Input amsmaths-seq.inc


Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Hi,

  I am trying to use the following layout file, which rgheck kindly 
provided me,  to typeset my document.




#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End



The problem with this layout is that it prepends the number of the 
relevant subsection to the number of each theorem, definition, etc. I 
want to get sequential numbering for theorem etc., without the 
subsection numbers.


For this I changed Input amsdefs.inc to Input amsmaths-seq.inc (as 
suggested by rgheck), after which I got an error saying \theoremstyle is 
not defined. When I checked the tex file exported by LyX, I saw that 
indeed \theoremstyle is being used without any package that defines it 
being imported.


So I added the following lines after the Format line and before the 
Input lines:


---

Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{buha}{Buha}
EndPreamble

---

(I added the invocations to \theoremstyle and \newtheorem just for 
testing).


When I reconfigure, restart LyX and generate a tex file from my 
document, the tex file does not contain the contents of this preamble 
anywhere -- the Preamble...EndPreamble block is completely being ignored 
by LyX.


Please help me fix this : I want to have \usepackage{amsthm} included 
somewhere near the very beginning of the output tex file, so that it is 
present before the first invocation of \theoremstyle --- puting 
\usepackage{amsthm} in the document preamble doesn't help, so I guess 
it must be somewhere withing the layout file.


Thanks,
Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread rgheck

Geevarghese Philip wrote:

Hi,

  I am trying to use the following layout file, which rgheck kindly 
provided me,  to typeset my document.




#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End



The problem with this layout is that it prepends the number of the 
relevant subsection to the number of each theorem, definition, etc. I 
want to get sequential numbering for theorem etc., without the 
subsection numbers.


For this I changed Input amsdefs.inc to Input amsmaths-seq.inc (as 
suggested by rgheck), after which I got an error saying \theoremstyle 
is not defined. When I checked the tex file exported by LyX, I saw 
that indeed \theoremstyle is being used without any package that 
defines it being imported.


So I added the following lines after the Format line and before the 
Input lines:


---

Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{buha}{Buha}
EndPreamble

---

(I added the invocations to \theoremstyle and \newtheorem just for 
testing).


When I reconfigure, restart LyX and generate a tex file from my 
document, the tex file does not contain the contents of this preamble 
anywhere -- the Preamble...EndPreamble block is completely being 
ignored by LyX.


Please help me fix this : I want to have \usepackage{amsthm} 
included somewhere near the very beginning of the output tex file, so 
that it is present before the first invocation of \theoremstyle --- 
puting \usepackage{amsthm} in the document preamble doesn't help, so 
I guess it must be somewhere withing the layout file.


This is a bug of sorts in the 1.5 layout system, I expect. The problem 
is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.

rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

rgheck wrote:

This is a bug of sorts in the 1.5 layout system, I expect. The problem 
is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.



Thanks, but unfortunately it doesn't work. I added this snippet to the 
end of the amsreport layout file, but the error persists.


One thing I noticed in the output tex file was that the very first lines 
are like the following:


\documentclass[english]{report}
...
...
...
\usepackage{amssymb}

The corresponding lines in the .lyx file are:

\lyxformat 276
\begin_document
\begin_header
\textclass amsreport


How does this \usepackage{amssymb} invocation get included in the tex 
preamble right at the top? I didn't include this in the preamble of the 
document. It is not mentioned in the amsreport.layout file, nor in the 
three files that this file Inputs : stdclass.inc, amsmaths-seq.inc, 
and numreport.inc. How does LyX know to include this invocation then? 
Perhaps I can modify the file which causes this line to be included to 
serve my purpose?


Thanks,
Philip




Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread rgheck

Geevarghese Philip wrote:

rgheck wrote:

This is a bug of sorts in the 1.5 layout system, I expect. The 
problem is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.



Thanks, but unfortunately it doesn't work. [snip]


Well, I'm not sure what the problem is. The attached files work for me.

rh

#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End



amsreport.lyx
Description: application/lyx


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

rgheck wrote:


Well, I'm not sure what the problem is. The attached files work for me.


There is no problem when including amsdefs.inc, as you have done in the 
layout file that you attached. The problem is when I replace this with 
Input amsmaths-seq.inc in the layout file, so that I may get 
sequentially numbered theorems and such.


Could you try replacing Input amsdefs.inc with Input 
amsmaths-seq.inc in the very same layout file that you had attached, 
and see if you get the error saying \theoremstyle is not defined?


Thanks a lot for your patience and help.

-- Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Geevarghese Philip wrote:

rgheck wrote:


Well, I'm not sure what the problem is. The attached files work for me.


There is no problem when including amsdefs.inc, as you have done in the 
layout file that you attached. The problem is when I replace this with 
Input amsmaths-seq.inc in the layout file, so that I may get 
sequentially numbered theorems and such.


Sorry for my hasty mail, I see your point now: the layout file you 
attached solves my problem of getting sequential theorems, without any 
modification. Thanks a /lot/ for your help.


--Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Geevarghese Philip wrote:

Geevarghese Philip wrote:
the layout file you 
attached solves my problem of getting sequential theorems,


This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to the 
theorem


--Philip



Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Hi,

  I am trying to use the following layout file, which rgheck kindly 
provided me,  to typeset my document.




#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End



The problem with this layout is that it prepends the number of the 
relevant subsection to the number of each theorem, definition, etc. I 
want to get sequential numbering for theorem etc., without the 
subsection numbers.


For this I changed Input amsdefs.inc to Input amsmaths-seq.inc (as 
suggested by rgheck), after which I got an error saying \theoremstyle is 
not defined. When I checked the tex file exported by LyX, I saw that 
indeed \theoremstyle is being used without any package that defines it 
being imported.


So I added the following lines after the Format line and before the 
Input lines:


---

Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{buha}{Buha}
EndPreamble

---

(I added the invocations to \theoremstyle and \newtheorem just for 
testing).


When I reconfigure, restart LyX and generate a tex file from my 
document, the tex file does not contain the contents of this preamble 
anywhere -- the Preamble...EndPreamble block is completely being ignored 
by LyX.


Please help me fix this : I want to have \usepackage{amsthm} included 
somewhere near the very beginning of the output tex file, so that it is 
present before the first invocation of \theoremstyle --- puting 
\usepackage{amsthm} in the document preamble doesn't help, so I guess 
it must be somewhere withing the layout file.


Thanks,
Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread rgheck

Geevarghese Philip wrote:

Hi,

  I am trying to use the following layout file, which rgheck kindly 
provided me,  to typeset my document.




#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End



The problem with this layout is that it prepends the number of the 
relevant subsection to the number of each theorem, definition, etc. I 
want to get sequential numbering for theorem etc., without the 
subsection numbers.


For this I changed Input amsdefs.inc to Input amsmaths-seq.inc (as 
suggested by rgheck), after which I got an error saying \theoremstyle 
is not defined. When I checked the tex file exported by LyX, I saw 
that indeed \theoremstyle is being used without any package that 
defines it being imported.


So I added the following lines after the Format line and before the 
Input lines:


---

Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{buha}{Buha}
EndPreamble

---

(I added the invocations to \theoremstyle and \newtheorem just for 
testing).


When I reconfigure, restart LyX and generate a tex file from my 
document, the tex file does not contain the contents of this preamble 
anywhere -- the Preamble...EndPreamble block is completely being 
ignored by LyX.


Please help me fix this : I want to have \usepackage{amsthm} 
included somewhere near the very beginning of the output tex file, so 
that it is present before the first invocation of \theoremstyle --- 
puting \usepackage{amsthm} in the document preamble doesn't help, so 
I guess it must be somewhere withing the layout file.


This is a bug of sorts in the 1.5 layout system, I expect. The problem 
is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.

rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

rgheck wrote:

This is a bug of sorts in the 1.5 layout system, I expect. The problem 
is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.



Thanks, but unfortunately it doesn't work. I added this snippet to the 
end of the amsreport layout file, but the error persists.


One thing I noticed in the output tex file was that the very first lines 
are like the following:


\documentclass[english]{report}
...
...
...
\usepackage{amssymb}

The corresponding lines in the .lyx file are:

\lyxformat 276
\begin_document
\begin_header
\textclass amsreport


How does this \usepackage{amssymb} invocation get included in the tex 
preamble right at the top? I didn't include this in the preamble of the 
document. It is not mentioned in the amsreport.layout file, nor in the 
three files that this file Inputs : stdclass.inc, amsmaths-seq.inc, 
and numreport.inc. How does LyX know to include this invocation then? 
Perhaps I can modify the file which causes this line to be included to 
serve my purpose?


Thanks,
Philip




Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread rgheck

Geevarghese Philip wrote:

rgheck wrote:

This is a bug of sorts in the 1.5 layout system, I expect. The 
problem is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.



Thanks, but unfortunately it doesn't work. [snip]


Well, I'm not sure what the problem is. The attached files work for me.

rh

#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   Bibliography
LabelFont
  Series  Bold
  SizeHuge
EndFont
End

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End



amsreport.lyx
Description: application/lyx


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

rgheck wrote:


Well, I'm not sure what the problem is. The attached files work for me.


There is no problem when including amsdefs.inc, as you have done in the 
layout file that you attached. The problem is when I replace this with 
Input amsmaths-seq.inc in the layout file, so that I may get 
sequentially numbered theorems and such.


Could you try replacing Input amsdefs.inc with Input 
amsmaths-seq.inc in the very same layout file that you had attached, 
and see if you get the error saying \theoremstyle is not defined?


Thanks a lot for your patience and help.

-- Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Geevarghese Philip wrote:

rgheck wrote:


Well, I'm not sure what the problem is. The attached files work for me.


There is no problem when including amsdefs.inc, as you have done in the 
layout file that you attached. The problem is when I replace this with 
Input amsmaths-seq.inc in the layout file, so that I may get 
sequentially numbered theorems and such.


Sorry for my hasty mail, I see your point now: the layout file you 
attached solves my problem of getting sequential theorems, without any 
modification. Thanks a /lot/ for your help.


--Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Geevarghese Philip wrote:

Geevarghese Philip wrote:
the layout file you 
attached solves my problem of getting sequential theorems,


This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to the 
theorem


--Philip



Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Hi,

  I am trying to use the following layout file, which rgheck kindly 
provided me,  to typeset my document.




#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   "Bibliography"
LabelFont
  Series  Bold
  SizeHuge
EndFont
End



The problem with this layout is that it prepends the number of the 
relevant subsection to the number of each theorem, definition, etc. I 
want to get sequential numbering for theorem etc., without the 
subsection numbers.


For this I changed "Input amsdefs.inc" to "Input amsmaths-seq.inc" (as 
suggested by rgheck), after which I got an error saying \theoremstyle is 
not defined. When I checked the tex file exported by LyX, I saw that 
indeed \theoremstyle is being used without any package that defines it 
being imported.


So I added the following lines after the Format line and before the 
Input lines:


---

Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{buha}{Buha}
EndPreamble

---

(I added the invocations to \theoremstyle and \newtheorem just for 
testing).


When I reconfigure, restart LyX and generate a tex file from my 
document, the tex file does not contain the contents of this preamble 
anywhere -- the Preamble...EndPreamble block is completely being ignored 
by LyX.


Please help me fix this : I want to have "\usepackage{amsthm}" included 
somewhere near the very beginning of the output tex file, so that it is 
present before the first invocation of \theoremstyle --- puting 
"\usepackage{amsthm}" in the document preamble doesn't help, so I guess 
it must be somewhere withing the layout file.


Thanks,
Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread rgheck

Geevarghese Philip wrote:

Hi,

  I am trying to use the following layout file, which rgheck kindly 
provided me,  to typeset my document.




#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   "Bibliography"
LabelFont
  Series  Bold
  SizeHuge
EndFont
End



The problem with this layout is that it prepends the number of the 
relevant subsection to the number of each theorem, definition, etc. I 
want to get sequential numbering for theorem etc., without the 
subsection numbers.


For this I changed "Input amsdefs.inc" to "Input amsmaths-seq.inc" (as 
suggested by rgheck), after which I got an error saying \theoremstyle 
is not defined. When I checked the tex file exported by LyX, I saw 
that indeed \theoremstyle is being used without any package that 
defines it being imported.


So I added the following lines after the Format line and before the 
Input lines:


---

Preamble
\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{buha}{Buha}
EndPreamble

---

(I added the invocations to \theoremstyle and \newtheorem just for 
testing).


When I reconfigure, restart LyX and generate a tex file from my 
document, the tex file does not contain the contents of this preamble 
anywhere -- the Preamble...EndPreamble block is completely being 
ignored by LyX.


Please help me fix this : I want to have "\usepackage{amsthm}" 
included somewhere near the very beginning of the output tex file, so 
that it is present before the first invocation of \theoremstyle --- 
puting "\usepackage{amsthm}" in the document preamble doesn't help, so 
I guess it must be somewhere withing the layout file.


This is a bug of sorts in the 1.5 layout system, I expect. The problem 
is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.

rh



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

rgheck wrote:

This is a bug of sorts in the 1.5 layout system, I expect. The problem 
is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.



Thanks, but unfortunately it doesn't work. I added this snippet to the 
end of the amsreport layout file, but the error persists.


One thing I noticed in the output tex file was that the very first lines 
are like the following:


\documentclass[english]{report}
...
...
...
\usepackage{amssymb}

The corresponding lines in the .lyx file are:

\lyxformat 276
\begin_document
\begin_header
\textclass amsreport


How does this \usepackage{amssymb} invocation get included in the tex 
preamble right at the top? I didn't include this in the preamble of the 
document. It is not mentioned in the amsreport.layout file, nor in the 
three files that this file "Inputs" : stdclass.inc, amsmaths-seq.inc, 
and numreport.inc. How does LyX know to include this invocation then? 
Perhaps I can modify the file which causes this line to be included to 
serve my purpose?


Thanks,
Philip




Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread rgheck

Geevarghese Philip wrote:

rgheck wrote:

This is a bug of sorts in the 1.5 layout system, I expect. The 
problem is that the preamble later gets redefined and your bit gets 
over-written. Try adding this at the end:

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End
I think that'll work.



Thanks, but unfortunately it doesn't work. [snip]


Well, I'm not sure what the problem is. The attached files work for me.

rh

#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[report]{amsreport}

Format 4

Input stdclass.inc
Input amsdefs.inc
Input numreport.inc

Style Bibliography
TopSep4
LabelString   "Bibliography"
LabelFont
  Series  Bold
  SizeHuge
EndFont
End

Style Theorem
   Preamble
 \usepackage{amsthm}
 \theoremstyle{plain}
 \newtheorem{thm}{Theorem}
   EndPreamble
End



amsreport.lyx
Description: application/lyx


Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

rgheck wrote:


Well, I'm not sure what the problem is. The attached files work for me.


There is no problem when including amsdefs.inc, as you have done in the 
layout file that you attached. The problem is when I replace this with 
"Input amsmaths-seq.inc" in the layout file, so that I may get 
sequentially numbered theorems and such.


Could you try replacing "Input amsdefs.inc" with "Input 
amsmaths-seq.inc" in the very same layout file that you had attached, 
and see if you get the error saying \theoremstyle is not defined?


Thanks a lot for your patience and help.

-- Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Geevarghese Philip wrote:

rgheck wrote:


Well, I'm not sure what the problem is. The attached files work for me.


There is no problem when including amsdefs.inc, as you have done in the 
layout file that you attached. The problem is when I replace this with 
"Input amsmaths-seq.inc" in the layout file, so that I may get 
sequentially numbered theorems and such.


Sorry for my hasty mail, I see your point now: the layout file you 
attached solves my problem of getting sequential theorems, without any 
modification. Thanks a /lot/ for your help.


--Philip



Re: Contents of Preamble...EndPreamble in Layout not being output to tex file

2008-03-27 Thread Geevarghese Philip

Geevarghese Philip wrote:

Geevarghese Philip wrote:
the layout file you 
attached solves my problem of getting sequential theorems,


This works as intended for the dvi/ps/pdf versions. I guess I am being 
greedy, but if only I could make LyX display the theorems with a 
sequential numbering, instead of prepending the subsection number to the 
theorem


--Philip