Commit Graph

244 Commits

Author SHA1 Message Date
Jean-Marc Lasgouttes
85e693806e Allow toggling (no)limits only after mathop symbol
In particular, introduce the new InsetMathScript::allowLimits method
that checks for that and honor it in getStatus/ddoDispatch.

Do the same for (over|under)brace

(cherry picked from commit 7b7ed64a0e)
(cherry picked from commit 6cfd733dea)
2019-01-05 15:18:09 +01:00
Jean-Marc Lasgouttes
ca8f6c09b6 forgot this 2019-01-05 15:04:51 +01:00
Jean-Marc Lasgouttes
7f3407b89a Avoid crash when using inset-select-all in tabular
When changing cell idx, it is important to set the pit to a reasonable
value.

(cherry picked from commit a69e01d0b4)
2019-01-05 14:56:41 +01:00
Jean-Marc Lasgouttes
e73c0d6387 Fix vertical offset of fonts like MinionPro
For some reason, adding a LTR/RTL Override unicode character before a
MinionPro string increases the ascent of the line.

This creates vertical offset issues when painting if the ascent used
as reference is the one of the font. Use the QTextLine ascent instead
for better results.

This is a followup to 1bed76e2a.

Fixes (reopened) ticket #11284.
Fixes ticket #10532.
Fixes ticket #10767.

(cherry picked from commit d8498d4785)
2019-01-05 14:40:56 +01:00
Juergen Spitzmueller
08100f8b02 Always update bibfiles cache with bibliography environment before opening citation dialog
We need to do this unconditionally, since there is no (trivial and non-
awkward) way to update it when the bibliography paragraphs are modified.

Fixes: #4899
(cherry picked from commit 35534231d4)
2019-01-05 10:31:08 +01:00
Richard Kimberly Heck
3c4c5aa994 Fix bug #11432.
Take account of Layout::free_spacing.

(cherry picked from commit 6135824f40)
2019-01-03 19:18:22 -05:00
Jean-Marc Lasgouttes
1e2b503ac9 Remove premature (and bad) optimization
When blinking the caret, it looks like a cool idea to only update the
small rectangle containing the caret. Actually it is an awful idea, since
the paint event will paint some rows, and these rows will not be
properly painted outside of the small rectangle. Unfortunately, the
painter will skip those "painted" rows on next paint events.

This leads to painting errors that depend on the ordering of "real"
and "caret" paint events. This is the reason why they only appeared
with split screens.

Quote of the day: ``The real problem is that programmers have spent far
too much time worrying about efficiency in the wrong places and at the
wrong times; premature optimization is the root of all evil (or at
least most of it) in programming.''
-- Donald Knuth, The Art of Computer Programming.

Fixes bug #11354.

(cherry picked from commit fba9f5b9e8)
2019-01-03 13:52:40 +01:00
Jean-Marc Lasgouttes
b9116e8b81 Add override statements to please clang
Eventually, all overridden virtual methods should be marked properly.
Currently, clang only warns about those in classes that already use
override in at least one place (which was the case dor GuiApplication).

(cherry picked from commit c8f4b68423)
2019-01-03 10:22:11 +01:00
Kornel Benko
00cd6f101c Amend 031d1c86: Add support for aastex62 2018-12-30 09:22:55 +01:00
Juergen Spitzmueller
51db94b350 Fix some parsing glitches in Autonest and IsAutonestedBy
Layouts can have spaces, underlines (that must be read as spaces, and
be enquoted)

Candidate for stable

(cherry picked from commit da273a944f)
2018-12-29 18:36:20 +01:00
Juergen Spitzmueller
d62775553a Beamer: autonest column in columns
Candidate for stable

(cherry picked from commit 012d9b088e)
2018-12-29 18:34:10 +01:00
Juergen Spitzmueller
a9890828bd Do not auto-insert separator for keepempty layouts
Candidate for stable

(cherry picked from commit 59d73f52b8)
2018-12-29 18:32:47 +01:00
Juergen Spitzmueller
7e1ecb653b Handle bibliography irritations in thesis template
Outsource the bibliography to an own child, which is then also included
in the children's "Standalone" branch

Add some clarifying notes.

Fixes: #10748
(cherry picked from commit 12aaeb259f)
2018-12-29 18:07:17 +01:00
Pavel Sanda
78e256163a Backport 33284ee5c. 2018-12-29 17:55:55 +01:00
Richard Kimberly Heck
d06c3d7d9f Fix bug #6096.
We used to need a hack to set the size of the layout combo, but
the code was changed in Qt 4.5 or so. Hence the appearance of this
bug in 2009. We can now just remove this hack, and all seems to
work correctly.

(cherry picked from commit d7f4346a19)
2018-12-29 11:30:47 -05:00
Richard Kimberly Heck
6806ad98df Fix bug #9004.
I'm not entirely happy with this way of doing it. It seems messy.
But there is not another clear option right now.

(cherry picked from commit 4f0ccae399)
2018-12-29 11:28:51 -05:00
Juergen Spitzmueller
35f0117b5f LFUN_TEXTSTYLE_UPDATE: Do not force any unspecified settings.
Fixes: #11111 (yay!)
(cherry picked from commit 2f9876a410)
2018-12-29 09:38:39 +01:00
Richard Kimberly Heck
88034d3d89 Fix bug #11422.
We need to load the master document before applying the params, since
otherwise the TOC reset (and other things) happen before the master
has been loaded (and set as parent).

(cherry picked from commit ac3693c04f)
2018-12-29 00:25:58 -05:00
Richard Kimberly Heck
9cd9712cf0 Fix bug #11378.
(cherry picked from commit f11a51be35)
2018-12-28 23:04:46 -05:00
Juergen Spitzmueller
6145cb798d Allow to restore default UI colors in prefs
Patch by Daniel Ramöller (racoon), with slight modifications of mine.

Fixes: #10062

(cherry picked from commit 81e4f8dfb6
with minor adaptations)
2018-12-24 11:51:38 +01:00
Scott Kostyshak
c249d942d6 status.23x: add entry for fix to changes in sel
This status entry is for #10338, which was backported in the
previous two commits.
2018-12-23 15:19:40 -05:00
Juergen Spitzmueller
4480b72a9d GuiCharacter: Add menu to Restore button
and allow for resetting all widgets to "No Change" besides "Default"

(cherry picked from commit ac8aac5b36)
2018-12-22 08:52:55 +01:00
Jean-Marc Lasgouttes
714b731e39 Make DEPM respect current cursor position.
Spaces are now conserved when they surround current cursor. Examples:
  abc   |   def
becomes
  abc | def
after DEPM and
  abc |
is kept as it is.

Fixes ticket #11412.

(cherry picked from commit dff0c5729e)
2018-12-21 22:18:40 +01:00
Enrico Forestieri
324b828717 Fix bug 11346
Enclose in braces an optional argument of a math macro when it
starts with an incomplete script inset or ends with a delimiter
size-modifier macro.

(cherry picked from commit 2dcb730026)
2018-12-20 11:57:54 +01:00
Pavel Sanda
7b431ff0ba Backport 99bfe20120. 2018-12-19 21:47:06 +01:00
Pavel Sanda
cb848bbcd0 * status.23x 2018-12-18 23:17:54 +01:00
Juergen Spitzmueller
1dc6154708 GuiCharacter: Add "Reset" and "Restore Defaults" buttons
Addresses #11415
2018-12-18 08:32:48 +01:00
Juergen Spitzmueller
aea162cc8d Check for hidden dirty child on close
Fixes: #11405
(cherry picked from commit f87218bbb5)
2018-12-17 18:46:13 +01:00
Juergen Spitzmueller
262b0dcca4 GuiCharacter: INHERIT is OFF for the tristate buttons.
(cherry picked from commit 1b6ce0e827)
2018-12-17 10:44:10 +01:00
Jean-Marc Lasgouttes
47adf27ac3 Fix undo after breaking a nested paragraph
We have to take into account that Buffer::updateBuffer can modify the document.

Fix bug #11292.

(cherry picked from commit 57feb0fed0)
2018-12-16 22:00:36 +01:00
Jean-Marc Lasgouttes
09d742cc7f Update boost to 1.68.
This avoid lots of warnings from gcc 8.
2018-12-16 21:45:02 +01:00
Jean-Marc Lasgouttes
0e6cb4e599 Set buffer correctly when changing math space type.
Fixes bug #7747.

(cherry picked from commit 2ec25c8eef)
2018-12-14 19:39:54 +01:00
Enrico Forestieri
3e9a1c2da7 Fix bug #9622
The backslash is the escape character used in our parser. Hence,
when used as a path separator on Windows, it has to be itself
escaped or the path enclosed in either double or single quotes.
Windows users are maybe trained to quote paths containing spaces
but not paths with backslashes. So, we automatically escape the
backslashes when they are not already enclosed in quotes.

(cherry picked from commit 4c9df62c6c)
2018-12-14 18:57:48 +01:00
Enrico Forestieri
eba2f14fa7 Fix display of single-char macro names
Essentially, all characters are allowed in single-char macro names.

Part of #11158.

(cherry picked from commit 95bc273a59)
2018-12-14 12:05:40 +01:00
Jean-Marc Lasgouttes
7950ace3d9 Fix selection of unmarked RtL text
With Qt 5.11 at least, RtL text will be drawn RtL even when the
(undocumented) flag Qt::TextForceLeftToRight is applied to the
QTextLayout object. This creates selection issues for Hebrew text
marked as English.

The solution is to do the same as in breakAt_helper, that is prepend
the string with a direction override unicode character.

Doing this requires to introduce a TEXTLAYOUT_OFFSET constant that has
to be used wisely to account for this extra character.

Fixes bug #11284.

(cherry picked from commit 1bed76e2a1)
2018-12-13 10:51:59 +01:00
Jean-Marc Lasgouttes
3a123b90af Remove old workaround that is not needed anymore
This causes a compilation error with boost 1.69.

Fixes bug #11349.

(cherry picked from commit 76e99e9a20)
2018-12-13 10:39:58 +01:00
Juergen Spitzmueller
ac351f40f1 Fix encoding problems in \input@path
As of LaTeX2e 2018, characters are made active earlier, which results
in new expansion problems.

Following a suggestion of Markus Kohm (pc) and the TL mailing list [1],
we embrace non-ASCII input paths in \detokenize. This relies on e-tex,
but I think we can assume this is nowadays available everywhere.

[1] http://tug.org/pipermail/tex-live/2018-May/041691.html

Fixes: #11146
(cherry picked from commit 8bd65041f2)
2018-12-12 08:39:20 +01:00
Richard Kimberly Heck
c26c7602e4 Copy modules into the Advanced F&R pane as well.
(cherry picked from commit 5064c09e9f)

Update the Advanced F&R document class when switching buffers.

(cherry picked from commit 944b0ae55d)
2018-12-11 18:05:53 -05:00
Richard Kimberly Heck
7bc7b8f422 Speed up convert_literalparam. Part of #11200.
(cherry picked from commit 4549f46a43)
2018-12-11 18:03:44 -05:00
Guillaume Munch
c1945d27df Make tab movement visible (#10733)
The nice hand-made solution for moving tabs has made its time. Use Qt's feature
instead from now on.

(cherry picked from commit 1979496399)
2018-12-11 17:59:27 -05:00
Richard Heck
e694199837 Fix bug 9798.
Nameref support for math references.

(cherry picked from commit 5f6332bf46)
2018-12-11 17:58:07 -05:00
Enrico Forestieri
535309929b Fix reloading of local layout file (bug #11120)
(cherry picked from commit 7822d11361)
2018-12-11 19:26:17 +01:00
Richard Kimberly Heck
ec464a8b9f Prepare for 2.3.2. 2018-12-08 11:24:40 -05:00
Juergen Spitzmueller
a7ecbba7bc sv.po: update by Jim. 2018-11-25 11:51:11 +01:00
Jean-Marc Lasgouttes
f7ebe1f70f Show cursor correctly when loading file
This is a fixup to 4ecbff00. When a file is loaded and the cursor is
set, it is required to first compute metrics to be able to scroll the
screen correctly.

Fixes bug #11377.

(cherry picked from commit 2dc84b69d5)
2018-11-23 17:05:46 +01:00
Jean-Marc Lasgouttes
c1df5fb6ef Avoid extra space in tooltips
When using QTextDocument to check the natutal size of a text, one has
to remove the text margin, which is not useful here.

Fixes bug #11353.

(cherry picked from commit 7db99672e6)
2018-11-21 14:47:04 +01:00
Juergen Spitzmueller
caa4ee6412 pt_BR.po: update by Georger 2018-11-18 18:22:08 +01:00
Juergen Spitzmueller
37599f29a4 uk.po: update by Yuri 2018-11-14 16:21:35 +01:00
Enrico Forestieri
704eede69b Fix bug #11367
The overset, underset, and stackrel insets behave like the script
rather than the fraction inset.
2018-11-12 21:17:03 +01:00
Juergen Spitzmueller
639aa35444 Dispay pre- and posttext widgets if non-empty also if unapplied
Fixes: #11352
(cherry picked from commit b8932afed5)
2018-10-30 22:18:52 +01:00