mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
Next attempt at correctly setting fonts in insets depending on inheritFont()
This commit is contained in:
parent
10bbf9e62b
commit
aba8c81290
@ -2393,8 +2393,9 @@ void Paragraph::latex(BufferParams const & bparams,
|
|||||||
pos_type body_pos = beginOfBody();
|
pos_type body_pos = beginOfBody();
|
||||||
unsigned int column = 0;
|
unsigned int column = 0;
|
||||||
|
|
||||||
// If we are inside an inset, the real outerfont is local_font
|
// If we are inside an non inheritFont() inset, the real outerfont is local_font
|
||||||
Font const real_outerfont = (runparams.local_font != nullptr)
|
Font const real_outerfont = (!inInset().inheritFont()
|
||||||
|
&& runparams.local_font != nullptr)
|
||||||
? Font(runparams.local_font->fontInfo()) : outerfont;
|
? Font(runparams.local_font->fontInfo()) : outerfont;
|
||||||
|
|
||||||
if (body_pos > 0) {
|
if (body_pos > 0) {
|
||||||
@ -2558,7 +2559,7 @@ void Paragraph::latex(BufferParams const & bparams,
|
|||||||
++column;
|
++column;
|
||||||
|
|
||||||
// Fully instantiated font
|
// Fully instantiated font
|
||||||
Font const current_font = getFont(bparams, i, real_outerfont);
|
Font const current_font = getFont(bparams, i, outerfont);
|
||||||
|
|
||||||
Font const last_font = running_font;
|
Font const last_font = running_font;
|
||||||
bool const in_ct_deletion = (bparams.output_changes
|
bool const in_ct_deletion = (bparams.output_changes
|
||||||
|
@ -80,6 +80,8 @@ public:
|
|||||||
UpdateType utype, TocBackend & backend) const;
|
UpdateType utype, TocBackend & backend) const;
|
||||||
///
|
///
|
||||||
void metrics(MetricsInfo &, Dimension &) const;
|
void metrics(MetricsInfo &, Dimension &) const;
|
||||||
|
/// Needs to be same as InsetTabular
|
||||||
|
bool inheritFont() const { return false; }
|
||||||
private:
|
private:
|
||||||
/// unimplemented
|
/// unimplemented
|
||||||
InsetTableCell();
|
InsetTableCell();
|
||||||
|
Loading…
Reference in New Issue
Block a user