mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 21:21:32 +00:00
BUG 3598: display framed and shaded notes in a separate paragraph, require package color also for framed note
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18412 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
862a35bf2b
commit
d848a5e393
@ -150,6 +150,18 @@ docstring const InsetNote::editMessage() const
|
||||
}
|
||||
|
||||
|
||||
Inset::DisplayType InsetNote::display() const
|
||||
{
|
||||
switch (params_.type) {
|
||||
case InsetNoteParams::Framed:
|
||||
case InsetNoteParams::Shaded:
|
||||
return AlignLeft;
|
||||
default:
|
||||
return Inline;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void InsetNote::write(Buffer const & buf, ostream & os) const
|
||||
{
|
||||
params_.write(os);
|
||||
@ -353,8 +365,10 @@ void InsetNote::validate(LaTeXFeatures & features) const
|
||||
features.require("color");
|
||||
features.require("framed");
|
||||
}
|
||||
if (params_.type == InsetNoteParams::Framed)
|
||||
if (params_.type == InsetNoteParams::Framed) {
|
||||
features.require("color");
|
||||
features.require("framed");
|
||||
}
|
||||
InsetText::validate(features);
|
||||
}
|
||||
|
||||
|
@ -53,6 +53,8 @@ public:
|
||||
Inset::Code lyxCode() const { return Inset::NOTE_CODE; }
|
||||
///
|
||||
docstring name() const { return from_ascii("Note"); }
|
||||
/// framed and shaded notes are displayed
|
||||
virtual DisplayType display() const;
|
||||
///
|
||||
void write(Buffer const &, std::ostream &) const;
|
||||
///
|
||||
|
Loading…
Reference in New Issue
Block a user