This is a regression at b0673bd1. The code referred to row.pit(),
which was not correctly initialized in this case. The bug does not
exist in master, since the code in redoParagraph has been cleaned-up
and row.pit() is always correct.
Two corrective measures are taken, each of which would fix the bug:
- do not use row.pit() in breakRow, but directly the pit parameter.
- initialize row.pit() correctly in the faulty case.
When including files, LyX always searches the user and the system
directory, in that order. This means that when using local layout
files broken down into multiple includes, the various includes should
be specified with a path relative to the user layouts directory
(typically ~/.lyx/layouts), making this very impractical.
This commit allows including local files by specifying their path
as explicitly relative to the main layout file position, i.e., by
specifying their path with either "./" or "../". If the main layout
is not loaded from a local file, the usual search order is used,
even if the path are explicitly relative. So, for system layouts,
both "Input ./name.inc" and "Input name.inc" are equivalent.
(cherry picked from commit 17ab47b3e6)
Because latex allows to do so, and there is no easy way to achieve this.
This was apparently implemented to allow cycling between the various dash
types, but it was a bad idea bringing no benefit and causing griefs.
Useful to cache copies of objects, including shared_ptrs. No risks of dangling
pointer, and avoid naked pointers in the source.
Fix memory leak when compiling with Qt5.
As part as the backport to stable, this code has been change to work
with C++98.
(cherry picked from commit 33b696c8ac)
(cherry picked from commit e04079aa52)
(cherry picked from commit 5211ca52ca)
(cherry picked from commit 8353a53cc3)
After a Theorem environment, LaTeX does by default indent the
following paragraph.
I checked various classes and no ModifyStyle was needed. The
hollywood and broadway classes are strange cases where there is an
indent after the Theorem environment, but it is much smaller than
the normal indent. The indent is the same as the opening indent of
normal text, which we currently ignore. Further, I don't expect it
is common to use theorems in these classes.
(cherry picked from commit f9ee47dfa2)
This empty inset caused problems with LuaTeX + system fonts (see
b863fb07). Although these problems seem to be resolved, this empty
inset is not supposed to be there.
The current version was wrong for non-English dialogs, and even for
the English one, due to the translator commands that were not removed
for calculation (as in "Formats[[output]]").
When using Qt stuff in breakAt, it may happen that the row is broken
after an hyphen (whereas the old code would only consider spaces).
The fact that we abuse the Row::right_boundary() property to detect when
a row should be flushed broke justification when a row is cut at an
hyphen.
Fix this by introducing a new Row::flushed() property and set it as needed.
(cherry picked from commit 8e7d0c2002)
The code that tries to decide whether it is worth splitting a given
text row element had a shortcoming: it did not take into account the
left margin of the new row that would be created.
The problem is that this left margin is not the same as the left
margin of the current row, because there can be for example
indentation effects.
To fix this problem, we pass the amount of available space on the
next row as a parameter of Row::shortenIfNeeded.
Note that there is no need to care about RtL row elements at this
point, since the bidi algorithm will be applied to the row
subsequently.
(cherry picked from commit 8491962c6b)
They are shown on screen by arrow or pilcrow symbol and cause a line break.
They are still not handled in LaTeX output, though.
(cherry picked from commit 6dfbab3124)
Whenever an argument delimiter is used inside the argument, the argument
needs to be grouped, that is
\cites({text (text) text})
or
\cite[{text [text] text}]
This fixes the original case reported in #2751 which is independent
from the general issue that the pre- and postnote field take literal
code.
It seems that QTextLayout does not handle properly a single character
with 0 width. This breaks drawing of things like \not.
No status line needed as this amends 24648404.