]> git.lyx.org Git - lyx.git/log
lyx.git
6 years agoFix trailing whitespace in cpp files.
Richard Heck [Mon, 3 Jul 2017 17:53:14 +0000 (13:53 -0400)]
Fix trailing whitespace in cpp files.

6 years agoFix whitespace at EOL.
Richard Heck [Mon, 3 Jul 2017 17:45:58 +0000 (13:45 -0400)]
Fix whitespace at EOL.

6 years agonatbibapa.module: Do not overwrite preamble.
Juergen Spitzmueller [Sun, 2 Jul 2017 08:54:39 +0000 (10:54 +0200)]
natbibapa.module: Do not overwrite preamble.

Also add author information.

Candidate for stable.

7 years agoDon't give users dangerous instructions
Enrico Forestieri [Tue, 27 Jun 2017 22:30:56 +0000 (00:30 +0200)]
Don't give users dangerous instructions

7 years agoSort images file list also for cmake
Kornel Benko [Tue, 27 Jun 2017 17:18:24 +0000 (19:18 +0200)]
Sort images file list also for cmake

This is not needed for recent cmake versions, but since we expect
also older cmake version be used, sort the list nevertheless.
See https://reproducible-builds.org/ for why this matters.

Amends b8e3615

7 years agoFixup the fixup d0acc3e57044: use editable()/isActive()
Jean-Marc Lasgouttes [Fri, 23 Jun 2017 18:32:32 +0000 (20:32 +0200)]
Fixup the fixup d0acc3e57044: use editable()/isActive()

While 522516d9 was too strong and broke mathed, d0acc3e57044 is too
lenient and can accept insets (mathed/CommandInset, InsetInfo) that
have a positive nargs() but are not editable (because they encapsulate
something).

Therefore the best solution for now is to use editable() in text and
isActive() in mathed, until those two things are merged.

Part of #10667.

7 years agosort svgz file list
Bernhard M. Wiedemann [Thu, 22 Jun 2017 13:52:43 +0000 (15:52 +0200)]
sort svgz file list

(required because filesystems return listings in undeterministic order)
to generate Resources.qrc and thereby Resources.cpp and the lyx binary
in a reproducible way

Setting LC_ALL=C because sort order might vary with locales.

See https://reproducible-builds.org/ for why this matters.

Fixes #10711.

7 years agoCmake export tests: Ignore missing glyphs on some tests
Kornel Benko [Tue, 27 Jun 2017 08:26:27 +0000 (10:26 +0200)]
Cmake export tests: Ignore missing glyphs on some tests

Could not find a suitable tex font for the following tests:
export/doc/uk/Intro_pdf4_texF
export/examples/uk/splash_pdf4_texF
export/examples/minted-filelisting_pdf4_texF

7 years agoDon't enclose in braces minted languages
Enrico Forestieri [Mon, 26 Jun 2017 22:58:07 +0000 (00:58 +0200)]
Don't enclose in braces minted languages

This is because the braces would be part of the language name.

7 years agoAmend 28be7d55 to avoid an exception
Enrico Forestieri [Mon, 26 Jun 2017 22:09:51 +0000 (00:09 +0200)]
Amend 28be7d55 to avoid an exception

This was occurring during validation when trying to enter the
language name in the advanced tab.

7 years agoAccount for old versions of Pygments
Enrico Forestieri [Mon, 26 Jun 2017 21:23:23 +0000 (23:23 +0200)]
Account for old versions of Pygments

Pygments versions prior to 2.0 only accept lower case names for lexers.
This commit makes sure to always use lower case names for the language
that is written in the LaTeX file, while retaining the proper casing
for the presentation in the GUI, which is dictated by compatibility
with the listings package. Moreover, if one switches from listings
to minted in a document, the language combo is properly updated even
if the used language had attached a dialect (a concept not shared by
minted), or even when importing a LaTeX document with tex2lyx.

7 years agoFix bug #10705
Enrico Forestieri [Mon, 26 Jun 2017 14:14:27 +0000 (16:14 +0200)]
Fix bug #10705

Seemingly, std::regex does not account for newlines in the string.

7 years agoClarify the status of thread local storage on OSX
Enrico Forestieri [Mon, 26 Jun 2017 12:41:34 +0000 (14:41 +0200)]
Clarify the status of thread local storage on OSX

The __thread local storage is supported on OSX since 10.7 (Lion),
released in 2012. For example, see:
http://forum.dlang.org/post/mailman.3439.1452269142.22025.digitalmars-d-bugs@puremagic.com

7 years agoCatch xdvipdfmx driver error (that breaks XeTeX compilation).
Juergen Spitzmueller [Sun, 25 Jun 2017 08:29:19 +0000 (10:29 +0200)]
Catch xdvipdfmx driver error (that breaks XeTeX compilation).

This prevents an assertion due to an unrecognized error.

Fixes: #10076.
7 years agoFixup 9c92494e1a486: avoid crash in Inset::dissolve()
Jean-Marc Lasgouttes [Fri, 23 Jun 2017 17:44:54 +0000 (19:44 +0200)]
Fixup 9c92494e1a486: avoid crash in Inset::dissolve()

The code path when the inset is empty did not fixup the cursor
position correctly.

Part of bug #10667.

7 years agoCmake export tests: Missed second parameter for writeConverters()
Kornel Benko [Tue, 20 Jun 2017 22:09:50 +0000 (00:09 +0200)]
Cmake export tests: Missed second parameter for writeConverters()

Unfortunatelly the prototype checking in perl is not very
sophisticated.

7 years agoFixup 522516d9 : editable() is unusable in mathed
Jean-Marc Lasgouttes [Tue, 20 Jun 2017 07:41:48 +0000 (09:41 +0200)]
Fixup 522516d9 : editable() is unusable in mathed

This is a relic from IU (Inset Unification): editable() is for text
insets and isActive() for mathed. This needs to be cleaned up.

Part of bug #10667.

7 years agoFix bug #10546
Enrico Forestieri [Mon, 19 Jun 2017 23:14:55 +0000 (01:14 +0200)]
Fix bug #10546

A labeled equation is also numbered.

7 years agoAvoid crash when selecting long text
Jean-Marc Lasgouttes [Mon, 19 Jun 2017 10:23:17 +0000 (12:23 +0200)]
Avoid crash when selecting long text

In some (not yet understood) situations, the paragraph metrics cache
is empty in generateSyntheticMouseEvent(). We just avoid a crash in
this case, but there is probably an underlying problem that deserves
being fixed.

Fixes bug #10324.

7 years agoCmake export tests: Modularisation of prefTest.pl
Kornel Benko [Sun, 18 Jun 2017 10:13:57 +0000 (12:13 +0200)]
Cmake export tests: Modularisation of prefTest.pl

Also added a parameter to easier switch between standard settings in
preferences and settings to use in export tests.

7 years agoPrune white space after the separating comma of options
Enrico Forestieri [Sat, 17 Jun 2017 18:41:29 +0000 (20:41 +0200)]
Prune white space after the separating comma of options

Both listings and minted allow for many complex options. So, a latex
source can be easily written as

\documentclass{article}
\usepackage{minted}
\usepackage{graphicx}
\usepackage{dingbat}
\begin{document}
\begin{minted}[breaklines=true,
               breakautoindent=false,
               breaksymbolleft=\raisebox{0.8ex}{
                   \small\reflectbox{\carriagereturn}},
               breaksymbolindentleft=0pt,
               breaksymbolsepleft=0pt,
               breaksymbolright=\small\carriagereturn,
               breaksymbolindentright=0pt,
               breaksymbolsepright=0pt]{Python}
def f(x):
    return 'Some text' + str(x) + 'some more text' + str(x) + 'even more text that goes on for a while'
\end{minted}
\end{document}

The used text editor can therefore add a mixture of tabs and spaces.
The white space after the options is not a problem and the imported
file compiles just fine, but the validator gets confused and doesn't
validate them. This would entail a difficult editing of the options
only to have them validated. So, better remove the white space.

7 years agoAmend 9b2b51a4
Enrico Forestieri [Sat, 17 Jun 2017 17:35:10 +0000 (19:35 +0200)]
Amend 9b2b51a4

runtests.py was being forgotten and a string transliterated.

7 years agoTex2lyx tests: Added minted testcase from Enrico Forestieri
Kornel Benko [Sat, 17 Jun 2017 14:55:57 +0000 (16:55 +0200)]
Tex2lyx tests: Added minted testcase from Enrico Forestieri

7 years agoDon't allow raw newlines in options
Enrico Forestieri [Sat, 17 Jun 2017 17:05:02 +0000 (19:05 +0200)]
Don't allow raw newlines in options

This happens if the options are split over multiple lines in the
latex source. A newline here confuses the lexer when reading the
converted LyX file.

7 years agoCorrect a default english layout translation
Enrico Forestieri [Sat, 17 Jun 2017 13:09:06 +0000 (15:09 +0200)]
Correct a default english layout translation

Of course, the default english translation for "List of Listings"
is "List of Listings", not "Listing".

7 years agoCorrectly skip a bottom caption
Enrico Forestieri [Sat, 17 Jun 2017 12:01:42 +0000 (14:01 +0200)]
Correctly skip a bottom caption

The getArg() method stops at the first closing brace, whether it
matches the opening one or not, so properly parse the caption and
then throw it away.

7 years agoUpdate parent buffer as soon as a child has been released
Juergen Spitzmueller [Sat, 17 Jun 2017 07:43:01 +0000 (09:43 +0200)]
Update parent buffer as soon as a child has been released

This prevents dangling pointers that might crash LyX.

Fixes: #9979.
Candidate for stable.

7 years agotex2lyx: import minted listings
Enrico Forestieri [Sat, 17 Jun 2017 00:23:00 +0000 (02:23 +0200)]
tex2lyx: import minted listings

This commit updates tex2lyx in order to also import minted listings.
For the floating version of a listing, minted uses the listing
environment, a concept that is not shared with the listings package,
towards which our listings inset is geared.
For this reason, a kludge is necessary when importing minted listings
not previously exported by LyX itself.
If the floating listing contains only a caption and a label (other
than the listing itself), everything is fine and the import is (or
aims to be) perfect. But, as in all other floating ebvironments,
one can also stick there other elements, which don't have a place
in the listings inset. So, in order to avoid a data loss, tex2lyx
sticks everything into the caption. In this way, things may be
rearranged in the GUI, if necessary. There is no other way, apart
from a complete redesign of the listings inset, of course. However,
I think that this is an acceptable compromise.

7 years agoCmake export tests: Adapt to minted listings
Kornel Benko [Fri, 16 Jun 2017 09:39:26 +0000 (11:39 +0200)]
Cmake export tests: Adapt to minted listings

1.) Handle also 'LatexCommand inputminted' in lyxStatus.pm
2.) Add '-shell-escape' to the appropriate converters.
  This applies only to the ctest-environment iff calling
  the script 'prefTest.pl' in the build directory.

7 years agoUse the same code for editable and non-editable buttons
Jean-Marc Lasgouttes [Thu, 15 Jun 2017 13:30:23 +0000 (15:30 +0200)]
Use the same code for editable and non-editable buttons

This removes the use of rectText in RenderButton. The fact that this
gave different spacing than buttonText was a problem.

Now buttonText requires to specify
* the offset, so that INSET_TO_TEXT_OFFSET is not used anymore in
  src/frontends/, which will be useful later.
* the background and frame color, in replacement for the hover state.

Remove the methods button() and buttonFrame() from GuiPainter.

Remove some unused header files.

Fixes bug #10704.

7 years agoAlso catch "! Incomplete \\if"
Juergen Spitzmueller [Thu, 15 Jun 2017 13:29:40 +0000 (15:29 +0200)]
Also catch "! Incomplete \\if"

7 years agoCatch "! Incomplete \\ifx" error
Juergen Spitzmueller [Thu, 15 Jun 2017 13:07:03 +0000 (15:07 +0200)]
Catch "! Incomplete \\ifx" error

Fixes: #10666
7 years agoMake fixIfBroken() more robust
Jean-Marc Lasgouttes [Thu, 15 Jun 2017 09:49:49 +0000 (11:49 +0200)]
Make fixIfBroken() more robust

Chop slice when its inset is not editable.

Fixes bug #10667.

7 years agoAvoid memory reuse problems with inset-dissolve
Jean-Marc Lasgouttes [Thu, 15 Jun 2017 09:37:40 +0000 (11:37 +0200)]
Avoid memory reuse problems with inset-dissolve

If
 1. the inset is deleted before pasting its contents in the outer text, and
 2. the inset contents begins with an inset, and
 3. the clone of this inner inset is allocated at the memory location just
    made free,
then bad things can happen.

To avoid this, we delete the inset only after its contents has been pasted.

Fixes bug #10667.

7 years agoGive 4 edit markers to all Frac-like insets
Jean-Marc Lasgouttes [Wed, 14 Jun 2017 13:38:47 +0000 (15:38 +0200)]
Give 4 edit markers to all Frac-like insets

Part of bug #10688.

7 years agoWhen entering an inset by cursor, reset boundary
Jean-Marc Lasgouttes [Wed, 14 Jun 2017 13:08:27 +0000 (15:08 +0200)]
When entering an inset by cursor, reset boundary

This happesn when cursor-left/right enters an inset.

Fixes bug #10630.

7 years agoUpdate it.po
Enrico Forestieri [Tue, 13 Jun 2017 17:57:41 +0000 (19:57 +0200)]
Update it.po

7 years agoAdd lower corners for BOX_MARKER too
Jean-Marc Lasgouttes [Tue, 13 Jun 2017 10:17:21 +0000 (12:17 +0200)]
Add lower corners for BOX_MARKER too

Let's see whether this helps Guillaume.

Part of bug #8883.

7 years agoUpdate sk.po
Kornel Benko [Tue, 13 Jun 2017 09:18:17 +0000 (11:18 +0200)]
Update sk.po

7 years agode.po
Juergen Spitzmueller [Tue, 13 Jun 2017 08:09:48 +0000 (10:09 +0200)]
de.po

7 years agoUpdate it.po
Enrico Forestieri [Tue, 13 Jun 2017 00:34:03 +0000 (02:34 +0200)]
Update it.po

7 years agoremerge po files, except sk.{po,gmo} as requested
Enrico Forestieri [Tue, 13 Jun 2017 00:11:51 +0000 (02:11 +0200)]
remerge po files, except sk.{po,gmo} as requested

7 years agoAvoid a crash if an external template is not installed
Enrico Forestieri [Mon, 12 Jun 2017 19:24:52 +0000 (21:24 +0200)]
Avoid a crash if an external template is not installed

7 years agoSet cursor properly after double/triple click in mathed
Jean-Marc Lasgouttes [Mon, 12 Jun 2017 16:00:43 +0000 (18:00 +0200)]
Set cursor properly after double/triple click in mathed

Without this setCurrentFont() is not correctly called on the
BufferView cursor and the cursor could appear in L-form.

Fixes bug #10686.

7 years agoUse a combo box instead of a check box for selecting the listings package
Enrico Forestieri [Mon, 12 Jun 2017 15:24:26 +0000 (17:24 +0200)]
Use a combo box instead of a check box for selecting the listings package

7 years agoImprovements to inset edit markers
Jean-Marc Lasgouttes [Mon, 12 Jun 2017 15:09:58 +0000 (17:09 +0200)]
Improvements to inset edit markers

Draw also upper markers when editing macros in MACRO_EDIT_INLINE_BOX mode.

Use MARKER2 for inline editing of macros.

7 years agoUse proper markers for display version of the math macro template.
Jean-Marc Lasgouttes [Mon, 12 Jun 2017 13:14:23 +0000 (15:14 +0200)]
Use proper markers for display version of the math macro template.

This avoids ghost white corners when the macro does not have a display
version.

Part of bug #8883.

7 years agoAvoid rounding issue when painting selection
Jean-Marc Lasgouttes [Mon, 12 Jun 2017 12:39:03 +0000 (14:39 +0200)]
Avoid rounding issue when painting selection

This is the same issue that was addressed in the all_sel case at
695b0cc3. The rounding issue only happens at specific zoom and
jusification values.

Fixes part of #8883.

7 years agoFix bad cursor positioning when entering an inset
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 09:35:05 +0000 (11:35 +0200)]
Fix bad cursor positioning when entering an inset

The test added at 359aef92 was incorrect. Actually, Inset::editXY
returns the inset when it is edited and also when it is not, which
can be confusing. So if we are unlucky and the slices positions in the
text area and in the inner inset match, the code below triggers and
many bad things can happen.

Also improve the documentation of Inset::editXY and TextMetrics::editXY.

Fixes #10691.

7 years agoSwitch parameters validation even before applying the changes
Enrico Forestieri [Mon, 12 Jun 2017 09:54:59 +0000 (11:54 +0200)]
Switch parameters validation even before applying the changes

In the document settings allow to immediately switch from one
package to the other for parameters validation without the need
of first applying the changes.

7 years agoUnhide buffers that are marked dirty as a result of external modifications
Guillaume MM [Sat, 10 Jun 2017 19:51:44 +0000 (21:51 +0200)]
Unhide buffers that are marked dirty as a result of external modifications

Several comments in the code point to the fact that hidden buffers are assumed
to be clean.

The other solution was to adapt the closing & saving code to take into account
hidden dirty buffers. Experience shows that it is more useful to unhide the
buffers at the moment of the external modification, in the context of a git
workflow where one has to reload the modified children buffers one-by-one.

Fixes crash at #10603

7 years agoRemove FileMonitorBlocker which does not work reliably on all platforms
Guillaume MM [Sat, 10 Jun 2017 21:45:57 +0000 (23:45 +0200)]
Remove FileMonitorBlocker which does not work reliably on all platforms

7 years agoIf the external modification is a deletion, do not ask for reloading.
Guillaume MM [Mon, 5 Jun 2017 20:04:07 +0000 (22:04 +0200)]
If the external modification is a deletion, do not ask for reloading.

The behavour when hitting "reload" on a deleted file was also confusing.

7 years agoPrevent false positives in external modifications
Guillaume MM [Fri, 12 May 2017 23:00:30 +0000 (01:00 +0200)]
Prevent false positives in external modifications

When the Buffer is notified to be externally modified, check that the
file contents have changed using the checksum.

Document the shortcoming of FileMonitorBlocker.

Fixes #10642.

7 years agoProperly track the lifetime of signals2::slots (#8261)
Guillaume MM [Sun, 28 May 2017 11:25:53 +0000 (13:25 +0200)]
Properly track the lifetime of signals2::slots (#8261)

Starting at 61b2bd5e, boost::bind was progressively replaced with
std::bind. They are not interchangeable though. boost::bind implements
the tracking of boost::signals{,2}::trackable objects. Now that
std::bind has completely replaced boost::bind, tracking never occurred.

This commit replaces boost::signals2::trackable with the new preferred
boost::signals2 methods: scoped_connections or slot::track_foreign. The
support::Trackable class introduced is less safe but easier for transitioning
old code.

Fixes the crash at #8261.

7 years agoAdjust minted options
Enrico Forestieri [Sun, 11 Jun 2017 15:47:31 +0000 (17:47 +0200)]
Adjust minted options

- Remove "chapter" and "section" as this are to be passed as class
  options and are otherwise not recognized.

- Let onoff=false for all TRUEFALSE parameters, otherwise only the
  form option=true is accepted and option=false does not validate,
  generating a lot of confusion.

7 years agode.po
Juergen Spitzmueller [Sun, 11 Jun 2017 14:42:35 +0000 (16:42 +0200)]
de.po

7 years agoUpdate sk.po
Kornel Benko [Sun, 11 Jun 2017 12:51:03 +0000 (14:51 +0200)]
Update sk.po

7 years agoCmake build: Totally missed lokalization of lib/citeengines/*.citeengines.
Kornel Benko [Sun, 11 Jun 2017 12:39:51 +0000 (14:39 +0200)]
Cmake build: Totally missed lokalization of lib/citeengines/*.citeengines.

7 years agoRemerge strings again after last change
Enrico Forestieri [Sun, 11 Jun 2017 12:02:02 +0000 (14:02 +0200)]
Remerge strings again after last change

7 years agoAdd accelerator
Enrico Forestieri [Sun, 11 Jun 2017 11:58:34 +0000 (13:58 +0200)]
Add accelerator

7 years agoAdd documentation for minted
Enrico Forestieri [Sun, 11 Jun 2017 11:42:35 +0000 (13:42 +0200)]
Add documentation for minted

7 years agoUnify translations
Enrico Forestieri [Sun, 11 Jun 2017 10:34:17 +0000 (12:34 +0200)]
Unify translations

This entry is shared by both listings and minted, so no need to use
different strings.

7 years agoUpdate layouttranslations and remerge po files.
Enrico Forestieri [Sun, 11 Jun 2017 10:24:24 +0000 (12:24 +0200)]
Update layouttranslations and remerge po files.

Only the new field "List of Listings" with same translation as
for "Listings[[List of Listings]]" has been added. No other change
has been done, so layouttranslations might actually change again
when automatically updated.

7 years agoUpdate sk.po
Kornel Benko [Sun, 11 Jun 2017 09:41:51 +0000 (11:41 +0200)]
Update sk.po

7 years agoChange the name of the "List of listings" for minted
Enrico Forestieri [Sun, 11 Jun 2017 08:38:44 +0000 (10:38 +0200)]
Change the name of the "List of listings" for minted

I actually checked that minted calls "List of Listings" the list of
listings, contrarily to the listings package.

7 years agoMake a string translatable
Guillaume MM [Sun, 11 Jun 2017 04:01:04 +0000 (06:01 +0200)]
Make a string translatable

7 years agoClearer message when about to discard an unsaved document entirely.
Guillaume MM [Sun, 11 Jun 2017 04:01:04 +0000 (06:01 +0200)]
Clearer message when about to discard an unsaved document entirely.

7 years agoQuote backspace in string
Enrico Forestieri [Sat, 10 Jun 2017 21:12:49 +0000 (23:12 +0200)]
Quote backspace in string

7 years agoWas forgetting to add the caption to the list of listings
Enrico Forestieri [Sat, 10 Jun 2017 19:00:43 +0000 (21:00 +0200)]
Was forgetting to add the caption to the list of listings

7 years agoAllow captions also on non-floating minted listings
Enrico Forestieri [Sat, 10 Jun 2017 16:43:23 +0000 (18:43 +0200)]
Allow captions also on non-floating minted listings

Minted provides for captions only with floating listings. However,
listings always allows captions, and our machinery is geared accordingly.
So, instead of discriminating the floating and non-floating cases,
always allow for captions with minted, too. When minted does not provide
for a caption, we will provide one.
In the child document case the caption will always be before the listing,
while for the inset case the caption will be before the listing if it
is entered as the first line, after the listing otherwise.

7 years agoOops: currentData() is Qt 5 only.
Juergen Spitzmueller [Sat, 10 Jun 2017 16:17:43 +0000 (18:17 +0200)]
Oops: currentData() is Qt 5 only.

7 years agoCorrect restoration of citation style selection between engine switches
Juergen Spitzmueller [Sat, 10 Jun 2017 12:29:07 +0000 (14:29 +0200)]
Correct restoration of citation style selection between engine switches

We stored the combo position index, but this changes on engine switch.

This also fixes a crash due to out-of-bound index at engine switch.

Fixes: #10692
7 years agoWas forgetting this at 4722e955
Enrico Forestieri [Sat, 10 Jun 2017 00:43:16 +0000 (02:43 +0200)]
Was forgetting this at 4722e955

7 years agoRemove the minted external template
Enrico Forestieri [Fri, 9 Jun 2017 22:12:22 +0000 (00:12 +0200)]
Remove the minted external template

That functionality is now provided by the new support for minted.
Also change the example file and accordingly rename it.

7 years agoTypo in comment
Scott Kostyshak [Fri, 9 Jun 2017 17:15:58 +0000 (13:15 -0400)]
Typo in comment

7 years agodoc - last updates are from 2015.
Pavel Sanda [Fri, 9 Jun 2017 10:49:58 +0000 (12:49 +0200)]
doc - last updates are from 2015.

7 years agoAmend fd075614
Enrico Forestieri [Fri, 9 Jun 2017 10:35:01 +0000 (12:35 +0200)]
Amend fd075614

Actually, only when using minted it is not possible to insert a
caption in a non-floating listing.

7 years agoGive a 2 pixels space for markers around math objects
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 13:22:03 +0000 (15:22 +0200)]
Give a 2 pixels space for markers around math objects

This is necessary when markers are nested. Ideally this should only be
done when there is risk of nesting.

Fixes (part of?) bug #10688.

7 years ago Update fr.po
jpc [Fri, 9 Jun 2017 07:39:24 +0000 (09:39 +0200)]
     Update fr.po

7 years agoExtend minted support to listings as child documents
Enrico Forestieri [Thu, 8 Jun 2017 17:33:54 +0000 (19:33 +0200)]
Extend minted support to listings as child documents

This was slipping through the cracks, apparently...

7 years agoUpdate translation of Listings by Jari-Matti Mäkelä
Kornel Benko [Thu, 8 Jun 2017 17:32:11 +0000 (19:32 +0200)]
Update translation of Listings by Jari-Matti Mäkelä

Correction for layouttranslations from  Jari-Matti Mäkelä <jmjmak@utu.fi>

7 years agoUpdate fi.po
Kornel Benko [Thu, 8 Jun 2017 17:28:06 +0000 (19:28 +0200)]
Update fi.po

Translations from Jari-Matti Mäkelä <jmjmak@utu.fi>

7 years agoUpdate sk.po
Kornel Benko [Thu, 8 Jun 2017 15:59:56 +0000 (17:59 +0200)]
Update sk.po

7 years agoAmend 268ae66: Enable use of '\\' chars and empty lines in HelpText
Kornel Benko [Thu, 8 Jun 2017 15:57:32 +0000 (17:57 +0200)]
Amend 268ae66: Enable use of '\\' chars and empty lines in HelpText

7 years agoRevert "Fix drawing of collpsable insets"
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 14:47:26 +0000 (16:47 +0200)]
Revert "Fix drawing of collpsable insets"

This was definitely not meant to be pushed, especially since I
reverted it recently. Sorry folks.

This reverts commit 6fc72a1a1ffc6abb321ce1b7921eed5655302b40.

7 years agoRevert "Fix bad cursor positioning when entering an inset"
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 14:46:49 +0000 (16:46 +0200)]
Revert "Fix bad cursor positioning when entering an inset"

This is not ready yet.

This reverts commit 7ca7873112314963c3a43987f32484749ec3af58.

7 years agoRevert "Give a 2 pixels space for markers around math objects"
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 14:46:19 +0000 (16:46 +0200)]
Revert "Give a 2 pixels space for markers around math objects"

This is not ready yet.

This reverts commit 5a3962958f2a2c5370b302d6dfea0967343b9a46.

7 years agoProperly use top/bottom edit marker for grid inset
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 14:03:14 +0000 (16:03 +0200)]
Properly use top/bottom edit marker for grid inset

This was an oversight when marker() was introduced.

Fixes part of #10688.

7 years agoGive a 2 pixels space for markers around math objects
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 13:22:03 +0000 (15:22 +0200)]
Give a 2 pixels space for markers around math objects

7 years agoFix bad cursor positioning when entering an inset
Jean-Marc Lasgouttes [Thu, 8 Jun 2017 09:35:05 +0000 (11:35 +0200)]
Fix bad cursor positioning when entering an inset

The test added at 359aef92 was incorrect. Actually, Inset::editXY
returns the inset when it is edited and also when it is not, which
can be confusing. So if we are unlucky and the slices positions in the
text area and in the inner inset match, the code below triggers and
many bad things can happen.

editXY() should probably have a documented way to indicate whether the
cursor has entered the inset, although the test used right now is
probably OK. The inset value is useful mainly for context menus or
tasks that need to know which inset the (x, y) coordinates
point to.

Note finally that the documentation of TextMetrics::editXY is
incorrect concerning the return value. It will return a non-null value
if the cursor is on a not editable inset.

Fixes #10691.

7 years agoFix drawing of collpsable insets
Jean-Marc Lasgouttes [Wed, 7 Jun 2017 10:20:33 +0000 (12:20 +0200)]
Fix drawing of collpsable insets

This is a follow-up to e194c9ce. There was actually no reason to let
InsetCollapsable and InsetText draw their own background. It is more
correct to remove the existing code and let the generic
Inset::drawBackground take command.

This allows to revert d207e85c.

Fixes bug #10587.

7 years agoSimplify preamble code when using listings
Enrico Forestieri [Thu, 8 Jun 2017 02:24:29 +0000 (04:24 +0200)]
Simplify preamble code when using listings

Following an idea from Guillame.

7 years agoOvertake layout translations from fi.po, ja.po, zh_CN.po
Kornel Benko [Wed, 7 Jun 2017 16:27:32 +0000 (18:27 +0200)]
Overtake layout translations from fi.po, ja.po, zh_CN.po

7 years agoUpdate sk.po
Kornel Benko [Wed, 7 Jun 2017 16:20:53 +0000 (18:20 +0200)]
Update sk.po

7 years agoDon't allow captions in non-floating listings
Enrico Forestieri [Wed, 7 Jun 2017 16:15:59 +0000 (18:15 +0200)]
Don't allow captions in non-floating listings

It was possible to insert a caption in a listing not marked as
floating. This didn't cause errors but the caption simply was
disappearing in the output.

7 years agoRevert "Fix drawing of collpsable insets"
Jean-Marc Lasgouttes [Wed, 7 Jun 2017 14:01:11 +0000 (16:01 +0200)]
Revert "Fix drawing of collpsable insets"

This patch cuses unintended issues (see #10587).

This reverts commit 18fb9cd7f9886295dbae66eb6ac060f9ac367f2d.

7 years agoFix a small glitch
Enrico Forestieri [Wed, 7 Jun 2017 13:31:13 +0000 (15:31 +0200)]
Fix a small glitch

When choosing a code language that has dialects in the languages
combo box, the dialects combo gets activated also when minted is
in use. However, minted does not support the concept of dialects
and the combo should not be enabled. This is harmless because the
dialects are simply ignored and the dialects status is restored
after apply, but it may fool the user in thinking that a dialect
can be actually selected. So, always disable it with minted.

7 years agoFix drawing of collpsable insets
Jean-Marc Lasgouttes [Wed, 7 Jun 2017 10:20:33 +0000 (12:20 +0200)]
Fix drawing of collpsable insets

This is a follow-up to e194c9ce. There was actually no reason to let
InsetCollapsable and InsetText draw their own background. It is more
correct to remove the existing code and let the generic
Inset::drawBackground take command.

This allows to revert d207e85c.

Fixes bug #10587.

7 years agoFix warning about signed/unsigned
Jean-Marc Lasgouttes [Wed, 7 Jun 2017 09:05:29 +0000 (11:05 +0200)]
Fix warning about signed/unsigned