Re: LyX 1.6svn bug - irritating and wrong message about included file using module not used in parent file

2008-03-31 Thread Helge Hafting

rgheck wrote:

Helge Hafting wrote:

Today I split a document in two, so I can publish the content
with two different front pages. [...] All this works very well, except
that I get a bogus error message each time
I do File-Export-Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not 
used in the parent file.


The message is wrong.


Can you try the attached exceedingly silly patch?

rh



Index: InsetInclude.cpp
===
--- InsetInclude.cpp(revision 23755)
+++ InsetInclude.cpp(working copy)
@@ -473,7 +473,7 @@
string const module = *it;
vectorstring::const_iterator found =
find(masterModules.begin(), 
masterModules.end(), module);
-   if (found != masterModules.end()) {
+   if (found == masterModules.end()) {
docstring text = bformat(_(Included file 
`%1$s'\n
uses module `%2$s'\n
which is not used in parent file.),
  

Taht patch did the trick - no more bogus error message. Thanks!

Helge Hafting


Re: LyX 1.6svn bug - irritating and wrong message about "included file using module not used in parent file"

2008-03-31 Thread Helge Hafting

rgheck wrote:

Helge Hafting wrote:

Today I split a document in two, so I can publish the content
with two different front pages. [...] All this works very well, except
that I get a bogus error message each time
I do File->Export->Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not 
used in the parent file.


The message is wrong.


Can you try the attached exceedingly silly patch?

rh



Index: InsetInclude.cpp
===
--- InsetInclude.cpp(revision 23755)
+++ InsetInclude.cpp(working copy)
@@ -473,7 +473,7 @@
string const module = *it;
vector::const_iterator found =
find(masterModules.begin(), 
masterModules.end(), module);
-   if (found != masterModules.end()) {
+   if (found == masterModules.end()) {
docstring text = bformat(_("Included file 
`%1$s'\n"
"uses module `%2$s'\n"
"which is not used in parent file."),
  

Taht patch did the trick - no more bogus error message. Thanks!

Helge Hafting


LyX 1.6svn bug - irritating and wrong message about included file using module not used in parent file

2008-03-14 Thread Helge Hafting

Today I split a document in two, so I can publish the content
with two different front pages. The idea is simple:

The first document has a latex preamble that sets up the front page,
and in the main window it simply \input the second document which has
all the content. (TOC, headings, text paragraphs, figures)
The \input is done using LyX, no ERT for that.


I split the document by making two copies. From the first I deleted
all content and added the \input. From the second I removed
my custom preamble because that is now in the first document.

The preamble merely defines some commands that the
second document will use to build a front page. Several
different first documents can now use the same content, but get a 
different front.



All this works very well, except that I get a bogus error message each time
I do File-Export-Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not used 
in the parent file.


The message is wrong.
Both documents have logical markup in their settings.
The first document has no content (other than \input) so
obviously it doesn't actually _use_ any logical markup. But adding a word
with logical markup doesn't make the message go away. There is no mismatch
in modules.

Ideally, not using logicalmkup in the first file should not be a 
problem at all,
but I can certainly live with having to put all modules in the master 
document.

The bogus message need to go away though.

Helge Hafting





Re: LyX 1.6svn bug - irritating and wrong message about included file using module not used in parent file

2008-03-14 Thread Richard Heck

Helge Hafting wrote:

Today I split a document in two, so I can publish the content
with two different front pages. The idea is simple:

The first document has a latex preamble that sets up the front page,
and in the main window it simply \input the second document which has
all the content. (TOC, headings, text paragraphs, figures)
The \input is done using LyX, no ERT for that.


I split the document by making two copies. From the first I deleted
all content and added the \input. From the second I removed
my custom preamble because that is now in the first document.

The preamble merely defines some commands that the
second document will use to build a front page. Several
different first documents can now use the same content, but get a 
different front.



All this works very well, except that I get a bogus error message each 
time

I do File-Export-Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not 
used in the parent file.


The message is wrong.
Both documents have logical markup in their settings.
The first document has no content (other than \input) so
obviously it doesn't actually _use_ any logical markup. But adding a word
with logical markup doesn't make the message go away. There is no 
mismatch

in modules.

Ideally, not using logicalmkup in the first file should not be a 
problem at all,



I agree.

but I can certainly live with having to put all modules in the master 
document.

The bogus message need to go away though.


I'll check this.

rh



Re: LyX 1.6svn bug - irritating and wrong message about included file using module not used in parent file

2008-03-14 Thread rgheck

Helge Hafting wrote:

Today I split a document in two, so I can publish the content
with two different front pages. [...] All this works very well, except
that I get a bogus error message each time
I do File-Export-Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not 
used in the parent file.


The message is wrong.


Can you try the attached exceedingly silly patch?

rh

Index: InsetInclude.cpp
===
--- InsetInclude.cpp	(revision 23755)
+++ InsetInclude.cpp	(working copy)
@@ -473,7 +473,7 @@
 			string const module = *it;
 			vectorstring::const_iterator found =
 find(masterModules.begin(), masterModules.end(), module);
-			if (found != masterModules.end()) {
+			if (found == masterModules.end()) {
 docstring text = bformat(_(Included file `%1$s'\n
 	uses module `%2$s'\n
 	which is not used in parent file.),


LyX 1.6svn bug - irritating and wrong message about "included file using module not used in parent file"

2008-03-14 Thread Helge Hafting

Today I split a document in two, so I can publish the content
with two different front pages. The idea is simple:

The first document has a latex preamble that sets up the front page,
and in the main window it simply \input the second document which has
all the content. (TOC, headings, text paragraphs, figures)
The \input is done using LyX, no ERT for that.


I split the document by making two copies. From the first I deleted
all content and added the \input. From the second I removed
my custom preamble because that is now in the first document.

The preamble merely defines some commands that the
second document will use to build a front page. Several
different first documents can now use the same content, but get a 
different front.



All this works very well, except that I get a bogus error message each time
I do File->Export->Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not used 
in the parent file.


The message is wrong.
Both documents have "logical markup" in their settings.
The first document has no content (other than \input) so
obviously it doesn't actually _use_ any logical markup. But adding a word
with logical markup doesn't make the message go away. There is no mismatch
in modules.

Ideally, not using "logicalmkup" in the first file should not be a 
problem at all,
but I can certainly live with having to put all modules in the master 
document.

The bogus message need to go away though.

Helge Hafting





Re: LyX 1.6svn bug - irritating and wrong message about "included file using module not used in parent file"

2008-03-14 Thread Richard Heck

Helge Hafting wrote:

Today I split a document in two, so I can publish the content
with two different front pages. The idea is simple:

The first document has a latex preamble that sets up the front page,
and in the main window it simply \input the second document which has
all the content. (TOC, headings, text paragraphs, figures)
The \input is done using LyX, no ERT for that.


I split the document by making two copies. From the first I deleted
all content and added the \input. From the second I removed
my custom preamble because that is now in the first document.

The preamble merely defines some commands that the
second document will use to build a front page. Several
different first documents can now use the same content, but get a 
different front.



All this works very well, except that I get a bogus error message each 
time

I do File->Export->Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not 
used in the parent file.


The message is wrong.
Both documents have "logical markup" in their settings.
The first document has no content (other than \input) so
obviously it doesn't actually _use_ any logical markup. But adding a word
with logical markup doesn't make the message go away. There is no 
mismatch

in modules.

Ideally, not using "logicalmkup" in the first file should not be a 
problem at all,



I agree.

but I can certainly live with having to put all modules in the master 
document.

The bogus message need to go away though.


I'll check this.

rh



Re: LyX 1.6svn bug - irritating and wrong message about "included file using module not used in parent file"

2008-03-14 Thread rgheck

Helge Hafting wrote:

Today I split a document in two, so I can publish the content
with two different front pages. [...] All this works very well, except
that I get a bogus error message each time
I do File->Export->Pdf(pdflatex). I get:
Included file 'content.lyx' uses module 'logicalmkup' which is not 
used in the parent file.


The message is wrong.


Can you try the attached exceedingly silly patch?

rh

Index: InsetInclude.cpp
===
--- InsetInclude.cpp	(revision 23755)
+++ InsetInclude.cpp	(working copy)
@@ -473,7 +473,7 @@
 			string const module = *it;
 			vector::const_iterator found =
 find(masterModules.begin(), masterModules.end(), module);
-			if (found != masterModules.end()) {
+			if (found == masterModules.end()) {
 docstring text = bformat(_("Included file `%1$s'\n"
 	"uses module `%2$s'\n"
 	"which is not used in parent file."),