Commit Graph

244 Commits

Author SHA1 Message Date
Juergen Spitzmueller
e00b11355d Merge paragraphs when pasted into an inset that forbids multipars
Fixes: #8281
(cherry picked from commit 5dde4b1b3e)
2018-10-14 09:06:38 +02:00
Juergen Spitzmueller
53a108e814 Load covington later
This solves a loading order conflict with beamer-article.

(cherry picked from commit 00ee54e694)
2018-10-13 09:49:10 +02:00
Enrico Forestieri
e323f74b78 Fix bug #11332
Add the "hyperref-driver=dvips" option to the extra flags of the
latex->dvi converter so that the breakurl package is automatically
loaded when needed.

(cherry picked from commit f5e6db7171)
2018-10-12 08:27:23 +02:00
Richard Kimberly Heck
7697bf7888 Revert "Fix bug #9348"
The fix changes behavior too much for stable. My bad.

This reverts commit e94ea46be7.
2018-10-08 16:27:47 -04:00
Juergen Spitzmueller
7a0416b374 Rework OK/Apply/Cancel UI of prefs dialog
Instead of "Save" (permanently) and "Apply" (temporarily), OK and Apply
now always save permanently, unless the new checkbox "Apply to current
session only" is checked.

Addresses: #10016
(cherry picked from commit c7bdb3b342)
2018-10-08 11:46:42 +02:00
Juergen Spitzmueller
4a8b508d40 If a master is being created at loading the child, un-hide it.
Fixes: #11162
(cherry picked from commit a368439bcc)
2018-10-08 11:43:20 +02:00
Juergen Spitzmueller
5133026b01 Fix suprious comma in book and thesis bib preview.
Fixes: #11272
(cherry picked from commit 399a4d7e71)
2018-10-08 11:40:24 +02:00
Juergen Spitzmueller
ea43f293c2 GuiCitation: don't reset filter on show
Addresses #11291

(cherry picked from commit 33d6499bbc)
2018-10-08 11:36:47 +02:00
Enrico Forestieri
e94ea46be7 Fix bug #9348
(cherry picked from commit 503f7db224)
2018-10-06 12:43:09 +02:00
Richard Kimberly Heck
00db9c44c8 Minor status updates 2018-10-05 11:46:51 -04:00
Richard Kimberly Heck
1d22d23808 Fix bug #10177.
The left margin given at class level should apply only to the main text.

(cherry picked from commit a007b65202)
2018-10-04 19:44:42 -04:00
Richard Kimberly Heck
768c7e2fa2 Fix bug #11275.
Show module name with description.

(cherry picked from commit 2553b0073f)
2018-10-04 14:12:03 -04:00
Jean-Marc Lasgouttes
ba3ff646db When ignoring an update, request one for later
If we were not ready to paint the screen, this does not mean that we
should give up on repainting, just potpone it.

I thought that it was bad to call update() in the paint event, but I
cannot find reference to this anymore and everything seems to work as
intended.

Fixes part of bug #11323.

(cherry picked from commit 38f09c177b)
(cherry picked from commit 2617a4dd50)
2018-10-04 15:07:12 +02:00
Enrico Forestieri
ea81faa911 Fix bug #11180
When a raster image with an advertised pixel density different
from 72 dpi is included in a latex file, the output image dimensions
are scaled by the ratio 72/pixel_density. Hence, if a clipping
bounding box is specified, it has to be scaled by the same ratio,
otherwise the images will be clipped differently on screen and output.
Here we use the extractbb command (present in any TeX distribution)
to ask about the output dimensions of the image as dictated by the
pixel density and compute the scaling ratio by the knowledge of the
actual dimensions. If, for whatever reason, extractbb is not found,
everything goes as before, because the clipping bounding box will
simply not be corrected.

(cherry picked from commit 380f34a114)
2018-10-04 00:40:19 -04:00
Richard Kimberly Heck
e67c119d80 Do not step equation numbers in deleted equations.
(cherry picked from commit df5805917b)
2018-10-04 00:20:19 -04:00
Richard Heck
a05da2121c Fix bug 11070.
Allows plural, caps, no prefix to be set via context menu.

(cherry picked from commit 35afcfb6dd)
2018-10-04 00:17:47 -04:00
Juergen Spitzmueller
76c15f51ea Do not store empty posttext for qualified citations
Fixes: #11308
(cherry picked from commit 90b1345203)
2018-10-02 08:11:50 +02:00
Juergen Spitzmueller
416b71883b Add bibtex inset to outliner if "add to toc" is checked.
Fixes #11309

(cherry picked from commit a89e3c344b)
2018-10-02 08:09:04 +02:00
Juergen Spitzmueller
068e3d4fe5 Amend cab46ff9d1
(cherry picked from commit f973855bde)
2018-10-02 07:47:06 +02:00
Stephan Witt
9fd0c45fa3 Add missing status entries for Mac build fixes 2018-09-29 13:48:31 +02:00
Juergen Spitzmueller
a754912e88 Use LTR environment for forceLTR content with polyglossia
Fixes: #10548
(cherry picked from commit 10c06f67c9)
2018-09-28 18:32:32 +02:00
Richard Kimberly Heck
1e26864c0a Status for last commit. 2018-09-27 22:14:44 -04:00
Enrico Forestieri
804ed1bffb Fix bug #11210
On Windows, start viewers in detached processes in order to avoid
a crash of the QProcess destructor when their thread terminates.
The opening of a console window is avoided by redirecting to the
null device all standard I/O channels.
2018-09-27 21:32:24 +02:00
Juergen Spitzmueller
ac5c2be8db Amend 2d4ac90fd2 once more
Only use local switch in RTL environment.

(cherry picked from commit e158d661b9)
2018-09-26 17:02:18 +02:00
Jean-Marc Lasgouttes
ebd4e25588 Avoid crash with cursor down in math
This can happen when the inset that contains the cursor is outside of
the screen.

THis is only a workaround. The real solution would be a
processUpdateFlags(FitCursor) call, but the code is not ready for that
yet.

Fixes bug #11296.

(cherry picked from commit 17576fb83b)
2018-09-21 18:43:53 +02:00
Jean-Marc Lasgouttes
bf3b81e46a Ignore horizontal wheel scrolling in workarea
We do not know what to do with horizontal scrolling events, so we ignore them.

Note that the code has to be different between Qt4 and Qt5.

Fixes bug #11257.

(cherry picked from commit 2cfbc5ecf6)
2018-09-21 18:42:32 +02:00
Jean-Marc Lasgouttes
97f3f18007 Avoid space before completion in mathed
This can happen if the current element has space after it (e.g. before
a relation).

Fixes bug #11283.

(cherry picked from commit 1b5ccecd65)
2018-09-21 18:41:08 +02:00
Jean-Marc Lasgouttes
f00a3e9304 Paint underline for insets too.
Fixes bug 11297.

(cherry picked from commit 328ff9df3a)
2018-09-20 17:07:10 +02:00
Juergen Spitzmueller
bebb077955 Avoid infinite loop
Fixes: #11295
(cherry picked from commit 92bfa07a62)
2018-09-20 17:01:38 +02:00
Jean-Marc Lasgouttes
b956265be3 Handle branches with space in their name
1/ Handle space in color name in set-color (with quoting)

2/ read properly branch inset which name has a space

Fixes bug #11108.

(cherry picked from commit 819cf53c22)
2018-09-19 22:39:01 +02:00
Juergen Spitzmueller
b5892e58f0 Fix copy-paste error.
(cherry picked from commit 305d449a47)
2018-09-19 08:54:09 +02:00
Jean-Marc Lasgouttes
c2ea2057fb Forgot this 2018-09-18 23:14:19 +02:00
Jean-Marc Lasgouttes
5c4c8065aa needauth is not needed for Sweave>LyX
Indeed this relies on tex2lyx and does not run R scripts.

The same holds for Knitr>LyX

(cherry picked from commit 23dbacb636)
2018-09-18 08:52:57 +02:00
Juergen Spitzmueller
734176c452 zh_CN.po: update by Winfred 2018-09-15 16:24:25 +02:00
Jean-Marc Lasgouttes
66e23c6334 Use a unicode character for menu separator on screen
Additionally, use a left pointing character in a RtL setting.

(cherry picked from commit 76512a7569)
2018-09-11 10:59:26 +02:00
Juergen Spitzmueller
a6fa2d721e tex2lyx: support for plural and capitalized refstyle
Also fix a glitch in non-refstyle import (getOpt() returns the option
with delimiter, so do not add them in ERT once more)

Candidate for stable

(cherry picked from commit faf40fb408)
2018-09-11 08:07:03 +02:00
Juergen Spitzmueller
4431ae2505 tex2lyx: support decimal alignment in tables
(cherry picked from commit 8ef2558dc2)
2018-09-11 08:03:23 +02:00
Juergen Spitzmueller
87db8ba5b8 Fix RTL tabular output with bidi package (i.e., polyglossia)
Fixes: #9686
(cherry picked from commit 21b347a2f8)
2018-09-10 19:20:24 +02:00
Juergen Spitzmueller
c5fe0751d9 tex2lyx: Fixes to the btUnit import
1. Do not attempt to mix diverging btUnits (e.g., chapters and sections).
2. use parse_text to properly parse the contents.

(cherry picked from commit 68d48b0015)
2018-09-10 17:50:30 +02:00
Juergen Spitzmueller
b1e5663333 tex2lyx: Add support for horizontal longtabular alignment 2018-09-10 16:31:46 +02:00
Enrico Forestieri
bc55ae0220 Update it.po 2018-09-10 14:48:34 +02:00
Jean-Marc Lasgouttes
93f861903d Fix disappearing blue language underline.
Make sure that the blue language underline is not below the bottom of
the row. Otherwise, it can disappear when the next row is painted.

(cherry picked from commit 8e9e050670)
2018-09-10 11:53:36 +02:00
Jean-Marc Lasgouttes
d371a43865 Draw top/bottom rules heavier for booktab
This gives a better idea of the TeX output, even though the thicknesses are
not correct. Like in LaTeX, this happens only for full top/bottom rules.

(cherry picked from commit 8651cd89f6)
(cherry picked from commit 84328c8538)
2018-09-10 11:48:37 +02:00
Juergen Spitzmueller
22e6659780 Don't add localswitch if no language changes
(cherry picked from commit 7018d3641f)
2018-09-10 10:13:29 +02:00
Juergen Spitzmueller
9b03b40731 Fix shortcuts info output on the Mac
QKeySequence returns special characters for keys on the mac rather than
textual key names (as on other OSes).

Since these symbols are not included in many fonts, we re-translate them
to textual names

Fixes: #10641
(cherry picked from commit 5f45b3ed9c)
2018-09-10 10:08:04 +02:00
Juergen Spitzmueller
4d81f210c1 Support key symbols via menukeys package
(cherry picked from commit fd7490762d)
2018-09-10 09:46:25 +02:00
Jean-Marc Lasgouttes
014227cc40 Fixes to input method handling
The goal of this patch is to make "self-insert <string>" act as a
sequence of individual self-insert calls. Once it is done, the
insertion of the commit string in GuiWorkArea can use that, which
fixes the issues described in bug 11183.

1/ in InsetMathNest, SELF_INSERT is rewritten to be a proper loop of
   interpretChar, instead of inserting the string as characters. This
   solves the issue of interpreting ^ properly.

2/ the text version does not need to be changed (the loop is rewritten
   using a range, though).

3/ Then {{{GuiWorkArea::inputMethodEvent}}} is changed to invoke
   directly self-insert. This removes the update issues.

Fixes bug 11183.

(cherry picked from commit ad5548cfe3)
2018-09-09 19:43:18 +02:00
Juergen Spitzmueller
ae8c0b2976 Amend 79cf3f5ec1
Some InfoInsets have to be LTR always.
2018-09-09 19:35:24 +02:00
Juergen Spitzmueller
b8c62838ec Covington now provides subexamples itself
Candidate for stable.

(cherry picked from commit ab16bb7eb9)
2018-09-09 19:17:46 +02:00
Juergen Spitzmueller
0bd7a6384b Allow to change multiple columns' width at once
Fixes: #11205
(cherry picked from commit 91254472e6)
2018-09-09 19:13:46 +02:00
Juergen Spitzmueller
0a89b08f68 tex2lyx: fix import of unknown commands'/environments' options
If we detect options via hasOpt(), output the brackets as ERT.

Fixes: #8685
(cherry picked from commit da62299f37)
2018-09-09 19:09:59 +02:00
Juergen Spitzmueller
93f3727b53 tex2lyx: Fix import of Arabic polyglossia environment
Part of #10111

(cherry picked from commit 920e26916e)
2018-09-09 19:05:53 +02:00
Juergen Spitzmueller
9e387aea07 tex2lyx: Add support for multirow
Fixes: #11164
(cherry picked from commit c33506555f)
2018-09-09 12:35:28 +02:00
Juergen Spitzmueller
3efd64696f Consider required modules when checking for layout definitions in modules
Fixes: #11156.
(cherry picked from commit 8b4c76fb24)
2018-09-09 12:25:57 +02:00
Juergen Spitzmueller
995aed2e6e Par alignment in floats must be swapped for all RTL langs, not only Hebrew
Fixes: #11029
(cherry picked from commit 3bacc3c6e7)
2018-09-09 12:23:16 +02:00
Juergen Spitzmueller
a41d589e85 Proper logos with RTL
Fixes #10423

(cherry picked from commit e5a9244bef)
2018-09-09 12:17:03 +02:00
Juergen Spitzmueller
2e65b8e75e Implement tri-state in GuiSetBorder
A new UNDECIDED state is used if multiple cells with differing border
settings are selected.

This prevents additional borders to be set without being asked.

Fixes: #10010
(cherry picked from commit 99aefa5fd2)
2018-09-09 11:46:37 +02:00
Juergen Spitzmueller
a359a53eb6 Disallow paragraph customization in some single-par charstyle insets
Fixes: #9192
(cherry picked from commit 7a5184fd87)
2018-09-09 11:41:52 +02:00
Juergen Spitzmueller
f6a8810d9d Wrap rotated cells with linebreaks in varwidth
Fixes: #8085
(cherry picked from commit 88e5e5fd34)
2018-09-09 11:38:38 +02:00
Juergen Spitzmueller
c41f9f7ed7 tex2lyx: extend titling support
Rather than checking for hardcoded title commands such as \maketitle,
use the titlename and titletype as defined in the layout.

This now also includes title environments.

Fixes part of #6461

(cherry picked from commit 429edc0a59)
2018-09-09 11:33:25 +02:00
Juergen Spitzmueller
00f344effa Consider EuropeanNumberTerminator property when determining text direction
Also, use EuropeanNumberSeparator information rather than relying on an
own (incomplete) list of number separators.

Fixes: #4057
(cherry picked from commit 611df441b6)
2018-09-09 11:30:43 +02:00
Enrico Forestieri
4862e00c1f Fix bug #11203
Minted does not have a language option but it is possible to enter
this option in the LyX interface for compatibility with the listings
package, and also for letting to enter a language not present in the
gui. So, this option is only used for properly specifying a language
in a listing, unless it is entered in the document settings dialog.
This case was not foreseen and thus the option was being passed to
the package as is, causing havoc. With this commit the option is
still available but is used to set a default language for a new
listing in place of the default "tex" language used so far.

(cherry picked from commit 16ca5290c0)
2018-09-09 11:25:01 +02:00
Juergen Spitzmueller
ae196dd70c Support input of non-ASCII characters in hyperlinks
We transform them to hex representation via
QByteArray::toPercentEncoding()

Fixes: #11165
(cherry picked from commit 01d8f41894)
2018-09-09 11:00:20 +02:00
Juergen Spitzmueller
29355d34d5 Use footnotehyper rather than footnote if hyperref is used
Fixes: #11212
(cherry picked from commit f8e286b823)
2018-09-09 10:55:34 +02:00
Juergen Spitzmueller
5f0c20b67e Capitalization fixes
Fixes: #11237
(cherry picked from commit b75f716b73)
2018-09-09 10:52:32 +02:00
Juergen Spitzmueller
08aef452e7 Disambiguate dialog buttons
Fixes: #11242
(cherry picked from commit 74657a14a7)
2018-09-09 10:50:01 +02:00
Juergen Spitzmueller
a0fb2f05c9 Do not start from a non-relevant parent in Buffer cloning.
(cherry picked from commit e077255aea)
2018-09-09 10:46:20 +02:00
Juergen Spitzmueller
0c05722a60 Redesign character dialog
Fixes: #2752, #3804, #3884, #4836

Backport of [fb393b450d661/lyxgit] and [f888afeb9ef7/lyxgit]
2018-09-09 10:28:25 +02:00
Richard Kimberly Heck
53bf5beae0 Prepare for 2.3.1. 2018-08-27 14:07:29 -04:00
Juergen Spitzmueller
7356f37644 Fix line break in tooltip
Fixes: #11252
(cherry picked from commit 6d71b9b69a)
2018-08-20 08:37:25 +02:00
Enrico Forestieri
103d6c6362 Fix bug #11247
async is a reserved keyword in python 3.7

(cherry picked from commit 061cd7fd9c)
2018-08-19 16:35:20 +02:00
Juergen Spitzmueller
5ef6805961 hu.po: update by Alex 2018-08-18 15:10:48 +02:00
Enrico Forestieri
48cd67ebf8 Fix LyX server on Windows
On some recent Windows versions, GetLastError() may also return
NO_ERROR instead of ERROR_IO_PENDING during an overlapped write
operation to a pipe. This was confusing the state machine in
Server.cpp so that replies to commands were scheduled but were
never actually output.

(cherry picked from commit cf5f2661dc)
2018-08-08 13:15:56 +02:00
Enrico Forestieri
e1fa3cb248 Update the server_monitor example client to Qt5
(cherry picked from commit ab72f94595)
2018-08-08 13:12:33 +02:00
Juergen Spitzmueller
9c3dbfb7ed uk.po: Update by Yuri 2018-08-04 07:12:33 +02:00
Juergen Spitzmueller
7de98f7dbc Change size policy of buffer combo in refs dialog
Fixes: #9316
(cherry picked from commit b286c6d235)
2018-08-03 19:46:27 +02:00
Juergen Spitzmueller
d762d55558 Fix problem of unwanted spaces caused by macro definitions
Patch by Gilbert J. M. Forkel

Fixes: #11216
(cherry picked from commit 372712cfd9)
2018-07-31 08:49:50 +02:00
Enrico Forestieri
9a851be4fa Fix bug #11214
The checkProg() function was separating a command from its parameters
by splitting at the first space. This was a problem if the command
was specified with a full path containing spaces. Now the checkProg()
function separates a command from the parameters by splitting at the
first non-quoted space. So, it suffices quoting a path to solve the
issue.
2018-07-28 23:27:43 +02:00
Juergen Spitzmueller
e0e998b157 Fix austrian language code
(cherry picked from commit b12ea3b731)
2018-07-25 19:44:26 +02:00
Juergen Spitzmueller
898ed85dd7 zh_CN: update from Winfred Huang 2018-07-25 15:43:20 +02:00
Juergen Spitzmueller
1d8ee1c704 (a)mend edb2d14124
(cherry picked from commit 0bf7b3211d)
2018-07-22 10:19:37 +02:00
Juergen Spitzmueller
485f070887 Fix nesting problem with numbers in RTL text
\textcolor must precede any \beginL

Fixes: #6283
(cherry picked from commit 114ebf00c4)
2018-07-22 10:16:32 +02:00
Juergen Spitzmueller
cc845ed2cf Fix bracket output in RTL languages
This is a real mess!

Fixes: #11187
(cherry picked from commit 195f62ac93)
2018-07-21 10:40:59 +02:00
Juergen Spitzmueller
a17dfeee0e Fix quotation marks in RTL script
Fixes: #11188
(cherry picked from commit aa1d9638fe)
2018-07-21 10:27:38 +02:00
Juergen Spitzmueller
bdbdd28756 Fix command line output of convertDefault.py for ImageMagick
Part of #11186

(cherry picked from commit 1e5acc5656)
2018-07-13 17:26:34 +02:00
Juergen Spitzmueller
82cade4877 Use QMessageBox for toggleWarning if possible
Qt 5.2 introduces the possibility to place a checkbox on a QMessageBox,
so we need no longer to use our own crude dialog.

(cherry picked from commit 0148ef7e6c)
2018-07-11 19:11:28 +02:00
Juergen Spitzmueller
12ca81f2ea Fix creationCode() of GuiPrintNomencl
This fixes "New Inset" in that dialog.

Candidate for stable

(cherry picked from commit d2afa67da9)
2018-07-10 17:52:50 +02:00
Jean-Marc Lasgouttes
25e0ca1860 Do not force lfun argument to be pure ascii
Fixes bug #11167.

(cherry picked from commit 8e015f3cb2)
2018-07-04 11:46:03 +02:00
Jean-Marc Lasgouttes
5eb4a15579 Do not allow completion when there is an active selection
We do it in texted only, mathed is more difficult and not so relevant IMO.

(cherry picked from commit 789acb4a95)
2018-07-04 11:22:00 +02:00
Juergen Spitzmueller
ab450346b5 Handle correctly zero table special arguments.
Fixes: #10247
2018-06-27 08:16:59 +02:00
Scott Kostyshak
03fef44b54 status: describe the CMake changes in 889d10cd 2018-06-24 18:04:54 -04:00
Enrico Forestieri
49c0021306 Fix bug #11174
Apparently, a new paragraph is started after a float even if
no blank line is actually present. So, account for this fact.

(cherry picked from commit f6922b8c88)
2018-06-17 23:37:39 +02:00
Enrico Forestieri
87b44bcc1f Fix bug #11151
(cherry picked from commit 17ea71b31c)
2018-05-21 22:01:56 +02:00
Stephan Witt
26d0fb3dd5 #11142 correct list of previous versions to check for user directory contents
LyX on Mac uses a user directory with version suffix. On change of the version suffix
the existence of the directories with previous versions is checked and the latest one
is used for a copy on first configure run.

For 2.3 the candidate list starts with 2.2 now as it should.

(cherry picked from commit 17c3617c49)
2018-05-16 07:18:38 +02:00
Juergen Spitzmueller
d35055de83 Fix InsetBox::contentAlignment()
Some cases where alignment is possible were missing.

Candidate for 2.3.x.

(cherry picked from commit de67b68b1d)
2018-05-11 18:44:17 +02:00
Jean-Marc Lasgouttes
4e981b034e Adapt caret height to context in mathed.
Compute a height from current font and current cell vertical
dimensions in MathData::metrics(), because this is where current font
is known.

Introduce BufferView::setCaretAscentDescent to remember this value.

This mechanism is not used for text because Cursor::current_font is
restored by undo, and the caret height would not be changed then. But
in principle it is doable.

(cherry picked from commit 90cfe4ec3b)
2018-05-10 12:53:30 +02:00
Scott Kostyshak
705302f6de Center longtable explicitly (#10690)
"Center" is the default of longtable, but some situations require it
to be centered explicitly, such as when using floatrow:

https://tex.stackexchange.com/questions/320592/floatrow-package-conflicting-with-centering-longtable

(cherry picked from commit bde1834f7e)
2018-05-08 17:42:43 -04:00
Scott Kostyshak
532d3600f2 Do not use needauth when only exporting code
We have a couple of converters (using Sweave and knitr to "tangle"
an intermediate file) that are used for exporting code chunks
contained in a .lyx file. Since the code is just exported to a text
file and is not executed, needauth is not necessary.

(cherry picked from commit 065e37e96f)
2018-05-06 19:50:55 -04:00
Juergen Spitzmueller
36096435e5 Fixes for nested ulem commands
1. \uuline must be on top of \sout
2. \uwave in \xout needs a hack to compile

(cherry picked from commit 9fd94a2dd0)
2018-05-05 10:09:04 +02:00
Juergen Spitzmueller
63c54434ae PassThru paragraphs have latex_language; consider this when checking
previous language

Fixes: #10793.
(cherry picked from commit 15df033bce)
2018-05-01 06:56:45 +02:00