This commit fixes a few warnings from Qt 5.14 like the following
one:
error: ‘void QComboBox::setAutoCompletion(bool)’ is deprecated: Use setCompleter() instead. [-Werror=deprecated-declarations]
We only generated setAutoCompletion() from setting the property in
the .ui files. There does not seem to be a .ui file property that
generates setCompleter(). However, the default in both Qt5 [1] and
Qt4 [2] is to enable case-insensitive autocompletion, which seems to
be the same type of autocompletion as when we were relying on
setAutoCompletion(true). Thus, we can remove the properties that set
autocomplete to true. There is only one file, SearchUi.ui, where we
were turning off the autocompletion; we now do so using
setCompleter(0) in GuiSearch::GuiSearch().
[1] https://doc.qt.io/qt-5/qcombobox.html#setCompleter
[2] https://doc.qt.io/archives/qt-4.8/qcombobox.html#setCompleter
(manually cherry picked from commit 27ba830b8e)
When switching class, it does not make sense to flag flex insets that
are undefined if they were already undefined before.
Part of bug #12163.
(cherry picked from commit 009efa195b)
Add code stolen from QBitTorrent and Qt Creator that properly enables
HighDpi handling.
The rules are:
1/ nothing needs to be done for macOS and Qt >= 6
2/ HighDpi support is set by default starting with Qt 5.6.
3/ Support for fractional scaling is added for Qt >= 5.14.
Hopefully fixes bug #12060.
(cherry picked from commit d7a4f47e7d)
(cherry picked from commit f92f2f95ff)
The math color inset inherits the mode of the containing inset.
This mode is inferred by the kind of font in effect. Setting the
right mode allows to insert spaces where these should be allowed.
Another small glitch was that the selection was always parsed in
math mode, so that any space was swallowed, even if the inset would
allow them.
We lack the necessary font (cmb10) for drawing bold uppercase greek
letters. It would be overkill adding it for this sole purpose, so
adopt the same poor man's bold strategy used with \boldsymbol.
A reference can be directly inserted into mathed but cannot be pasted
because the pasted material is returned in plain text format. This patch
allows getting a string from the cut stack in a suitable format allowing
the math parser to actually create an InsetRef.
Fixes#11539
(cherry picked from commit 22ee249c3e)
When hitting backspace in the first position of a cell in mathed,
if the cell is part of an array, the whole array is dissolved
and the sole cell content pasted in the containing environment.
But if the cell is part of an eqnarray or align math hull type, the
cursor is simply (and unexpectedly) taken out of the whole equation,
which is left unchanged.
This patch makes backspace equivalent to the cursor left key in those
cases, while leaving the behavior unchanged in all other ones.
Fixes#11678
(cherry picked from commit c79ec4114e)