Get InsetCollapsable working, at least to some extent.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29963 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Richard Heck 2009-06-05 18:57:53 +00:00
parent a3915db54f
commit 6ef03cc4ac
2 changed files with 16 additions and 0 deletions

View File

@ -28,6 +28,7 @@
#include "LaTeXFeatures.h"
#include "Lexer.h"
#include "MetricsInfo.h"
#include "output_xhtml.h"
#include "paragraph_funcs.h"
#include "ParagraphParameters.h"
#include "sgml.h"
@ -871,6 +872,19 @@ int InsetCollapsable::docbook(odocstream & os, OutputParams const & runparams) c
}
int InsetCollapsable::xhtml(odocstream & os, OutputParams const & runparams) const
{
InsetLayout const & il = getLayout();
bool opened = false;
if (!undefined())
opened = html::openTag(os, il.htmltag(), il.htmlattr());
InsetText::xhtml(os, runparams);
if (opened && !undefined())
html::closeTag(os, il.htmltag());
return 0;
}
void InsetCollapsable::validate(LaTeXFeatures & features) const
{
features.useInsetLayout(getLayout());

View File

@ -144,6 +144,8 @@ public:
///
int docbook(odocstream &, OutputParams const &) const;
///
int xhtml(odocstream &, OutputParams const &) const;
///
void validate(LaTeXFeatures &) const;
///
InsetCode lyxCode() const { return COLLAPSABLE_CODE; }