mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-11 03:03:06 +00:00
Support non-default styles in multirow
This commit is contained in:
parent
5979a01b1d
commit
8d09fb5bf0
@ -4198,12 +4198,6 @@ InsetTableCell::InsetTableCell(Buffer * buf)
|
|||||||
isMultiColumn(false), isMultiRow(false), contentAlign(LYX_ALIGN_CENTER)
|
isMultiColumn(false), isMultiRow(false), contentAlign(LYX_ALIGN_CENTER)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
bool InsetTableCell::forcePlainLayout(idx_type) const
|
|
||||||
{
|
|
||||||
return isMultiRow;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool InsetTableCell::allowParagraphCustomization(idx_type) const
|
bool InsetTableCell::allowParagraphCustomization(idx_type) const
|
||||||
{
|
{
|
||||||
return isFixedWidth;
|
return isFixedWidth;
|
||||||
@ -7398,12 +7392,6 @@ bool InsetTabular::allowParagraphCustomization(idx_type cell) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool InsetTabular::forcePlainLayout(idx_type cell) const
|
|
||||||
{
|
|
||||||
return tabular.isMultiRow(cell);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool InsetTabular::insertPlaintextString(BufferView & bv, docstring const & buf,
|
bool InsetTabular::insertPlaintextString(BufferView & bv, docstring const & buf,
|
||||||
bool usePaste)
|
bool usePaste)
|
||||||
{
|
{
|
||||||
|
@ -136,8 +136,6 @@ private:
|
|||||||
///
|
///
|
||||||
bool usePlainLayout() const override { return true; }
|
bool usePlainLayout() const override { return true; }
|
||||||
///
|
///
|
||||||
bool forcePlainLayout(idx_type = 0) const override;
|
|
||||||
///
|
|
||||||
bool allowParagraphCustomization(idx_type = 0) const override;
|
bool allowParagraphCustomization(idx_type = 0) const override;
|
||||||
///
|
///
|
||||||
bool forceLocalFontSwitch() const override;
|
bool forceLocalFontSwitch() const override;
|
||||||
@ -1034,8 +1032,6 @@ public:
|
|||||||
/// should all paragraphs be output with "Standard" layout?
|
/// should all paragraphs be output with "Standard" layout?
|
||||||
bool allowParagraphCustomization(idx_type cell = 0) const override;
|
bool allowParagraphCustomization(idx_type cell = 0) const override;
|
||||||
///
|
///
|
||||||
bool forcePlainLayout(idx_type cell = 0) const override;
|
|
||||||
///
|
|
||||||
void addPreview(DocIterator const & inset_pos,
|
void addPreview(DocIterator const & inset_pos,
|
||||||
graphics::PreviewLoader &) const override;
|
graphics::PreviewLoader &) const override;
|
||||||
|
|
||||||
|
@ -1455,12 +1455,7 @@ void TeXOnePar(Buffer const & buf,
|
|||||||
// Note from JMarc: we will re-add a \n explicitly in
|
// Note from JMarc: we will re-add a \n explicitly in
|
||||||
// TeXEnvironment, because it is needed in this case
|
// TeXEnvironment, because it is needed in this case
|
||||||
if (nextpar && !os.afterParbreak() && !last_was_separator) {
|
if (nextpar && !os.afterParbreak() && !last_was_separator) {
|
||||||
if (runparams.isNonLong)
|
if (!text.inset().getLayout().parbreakIgnored() && !merged_par)
|
||||||
// This is to allow parbreak in multirow
|
|
||||||
// It could also be used for other non-long
|
|
||||||
// contexts
|
|
||||||
os << "\\endgraf";
|
|
||||||
else if (!text.inset().getLayout().parbreakIgnored() && !merged_par)
|
|
||||||
// Make sure to start a new line
|
// Make sure to start a new line
|
||||||
os << breakln;
|
os << breakln;
|
||||||
// A newline '\n' is always output before a command,
|
// A newline '\n' is always output before a command,
|
||||||
@ -1507,8 +1502,15 @@ void TeXOnePar(Buffer const & buf,
|
|||||||
&& tclass.isDefaultLayout(next_layout))) {
|
&& tclass.isDefaultLayout(next_layout))) {
|
||||||
// and omit paragraph break if it has been deleted with ct
|
// and omit paragraph break if it has been deleted with ct
|
||||||
// and changes are not shown in output
|
// and changes are not shown in output
|
||||||
if (!merged_par)
|
if (!merged_par) {
|
||||||
os << '\n';
|
if (runparams.isNonLong)
|
||||||
|
// This is to allow parbreak in multirow
|
||||||
|
// It could also be used for other non-long
|
||||||
|
// contexts
|
||||||
|
os << "\\endgraf\n";
|
||||||
|
else
|
||||||
|
os << '\n';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user