mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 01:59:02 +00:00
parent
1840e2dbaf
commit
ab3a49973f
@ -313,6 +313,19 @@ InsetLayout Listings
|
||||
ForceLTR true
|
||||
RefPrefix lst
|
||||
HTMLTag pre
|
||||
HTMLStyle
|
||||
div.float-listings {
|
||||
border: 2px solid black;
|
||||
padding: 1ex;
|
||||
margin: 1ex;
|
||||
}
|
||||
div.listings-caption {
|
||||
text-align: center;
|
||||
border: 2px solid black;
|
||||
padding: 1ex;
|
||||
margin: 1ex;
|
||||
}
|
||||
EndHTMLStyle
|
||||
End
|
||||
|
||||
InsetLayout Branch
|
||||
|
@ -273,10 +273,10 @@ docstring InsetListings::xhtml(XHTMLStream & os, OutputParams const & rp) const
|
||||
if (isInline)
|
||||
out << html::CompTag("br");
|
||||
else {
|
||||
out << html::StartTag("div", "class='float float-listings'");
|
||||
out << html::StartTag("div", "class='float-listings'");
|
||||
docstring caption = getCaptionHTML(rp);
|
||||
if (!caption.empty())
|
||||
out << html::StartTag("div", "class='float-caption'")
|
||||
out << html::StartTag("div", "class='listings-caption'")
|
||||
<< XHTMLStream::ESCAPE_NONE
|
||||
<< caption << html::EndTag("div");
|
||||
}
|
||||
@ -372,6 +372,7 @@ docstring const InsetListings::buttonLabel(BufferView const & bv) const
|
||||
void InsetListings::validate(LaTeXFeatures & features) const
|
||||
{
|
||||
features.require("listings");
|
||||
features.useInsetLayout(getLayout());
|
||||
string param_string = params().params();
|
||||
if (param_string.find("\\color") != string::npos)
|
||||
features.require("color");
|
||||
|
Loading…
Reference in New Issue
Block a user