From: Richard Heck Date: Sat, 20 Jul 2013 13:56:34 +0000 (-0400) Subject: Fix logic error that led to bug #8777. I have no idea what I was X-Git-Tag: 2.1.0beta2~230 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=d938284fb33da2754a16e39e5e15dc867e217a25;p=features.git Fix logic error that led to bug #8777. I have no idea what I was previously thinking. --- diff --git a/src/insets/InsetCaption.cpp b/src/insets/InsetCaption.cpp index ac6624f005..aaf06286f9 100644 --- a/src/insets/InsetCaption.cpp +++ b/src/insets/InsetCaption.cpp @@ -316,7 +316,9 @@ docstring InsetCaption::xhtml(XHTMLStream & xs, OutputParams const & rp) const string const our_class = "float-caption-" + type_; size_t const loc = attr.find("class='"); if (loc != string::npos) - attr.insert(loc + 1, our_class); + attr.insert(loc + 7, our_class+ " "); + else + attr = attr + " class='" + our_class + "'"; } xs << html::StartTag(tag, attr); docstring def = getCaptionAsHTML(xs, rp);