]> git.lyx.org Git - features.git/commitdiff
Fix bug 1147.
authorJosé Matox <jamatos@lyx.org>
Fri, 13 Aug 2004 13:07:02 +0000 (13:07 +0000)
committerJosé Matox <jamatos@lyx.org>
Fri, 13 Aug 2004 13:07:02 +0000 (13:07 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@8899 a592a061-630c-0410-9148-cb99ea01b6c8

src/ChangeLog
src/insets/ChangeLog
src/insets/insetgraphics.C
src/tabular.C

index 9da3aa7317ae9597b38296bd13ea4bdeb7bf657d..ea87c4538c282c0b8d7b97be4a6abc7ef6ba45db 100644 (file)
@@ -1,3 +1,6 @@
+2004-08-13  José Matos  <jamatos@lyx.org>
+
+       * tabular.C (docbook): close empty tags in XML. Fix bug 1147.
 
 2004-08-13  André Pönitz  <poenitz@gmx.net>
 
index dc0334bfdc363fe624907c8855ac60e44f08671b..77bcf614de2bfd96e939f71dbc3e014c6d7717d5 100644 (file)
@@ -1,3 +1,7 @@
+2004-08-13  José Matos  <jamatos@lyx.org>
+
+       * insetgraphics.C (docbook): close empty tags in XML. Fix bug 1147.
+
 2004-08-04  Jean-Marc Lasgouttes  <lasgouttes@lyx.org>
 
        * insetfoot.C (latex): use OutputParams::intitle instead of
index fe29faf3ba076b397f9aabd04e8d0a38aaa2262e..2314504c7cd265cd2d08471737695682fbdfcc97 100644 (file)
@@ -703,11 +703,15 @@ int InsetGraphics::docbook(Buffer const &, ostream & os,
        // In DocBook v5.0, the graphic tag will be eliminated from DocBook, will
        // need to switch to MediaObject. However, for now this is sufficient and
        // easier to use.
-       runparams.exportdata->addExternalFile("docbook",
-                                             params().filename.absFilename());
-       runparams.exportdata->addExternalFile("docbook-xml",
-                                             params().filename.absFilename());
-       os << "<graphic fileref=\"&" << graphic_label << ";\">";
+       if (runparams.flavor == OutputParams::XML) {
+               runparams.exportdata->addExternalFile("docbook-xml",
+                                                     params().filename.absFilename());
+               os << "<graphic fileref=\"&" << graphic_label << ";\"/>";
+       } else {
+               runparams.exportdata->addExternalFile("docbook",
+                                                     params().filename.absFilename());
+               os << "<graphic fileref=\"&" << graphic_label << ";\">";
+       }
        return 0;
 }
 
index 98411af6604372cf37fbbbbb16bef52202870c09..c3da317f2c5ef1e884d2dedea1389ae3479c14e6 100644 (file)
@@ -2250,7 +2250,10 @@ int LyXTabular::docbook(Buffer const & buf, ostream & os,
                        os << "center";
                        break;
                }
-               os << "\">\n";
+               os << '"';
+               if (runparams.flavor == OutputParams::XML)
+                       os << '/';
+               os << ">\n";
                ++ret;
        }