Commit Graph

34955 Commits

Author SHA1 Message Date
Enrico Forestieri
d275d034c0 Check whether the buffer pointer is valid before using it 2015-06-25 01:25:42 +02:00
Enrico Forestieri
fee356eb56 Assure not to miss requirements on loading with instant preview on 2015-06-25 00:49:15 +02:00
Enrico Forestieri
f3b03699ef Fix crash when copying a macro with instant preview on
The MacroData pointer is updated by MathData::metrics() which is not
called when selecting a math inset with instant preview for math on.
Thus, we have to update it in the copy constructor otherwise a crash
is almost assured when hitting Ctrl+C.
2015-06-24 23:38:53 +02:00
Stephan Witt
e4fada8c57 #7896: LyX templates folder is empty - create a symlink to system templates in user template directory at run time 2015-06-23 08:41:43 +02:00
Stephan Witt
bfc7c4d379 #7896 add support for symlink creation by the LyX binary itself 2015-06-23 08:41:43 +02:00
Enrico Forestieri
cd046f0e0c Avoid an exception when the lyxpreview2bitmap.py script fails completely
If latex fails to generate any output, the forked process was not removed.
Now, if a snippet was changed a new one was started but, if also the zoom was
changed, things went awry because the 2 concurrent processes were asked to
process again the same snippet. Previously this would have simply caused a
waste of resources because the changed snippet would have not been regenerated.
Also reset the guard due to the early exit.
2015-06-23 02:39:48 +02:00
Enrico Forestieri
592219c1f1 Properly reschedule refresh of previews
If the zoom factor is changed right while the previews are being
regenerated, the refreshPreviews() method is a no-op. So, reschedule
the refresh until everything is ready.
2015-06-21 17:21:19 +02:00
Enrico Forestieri
2973108a62 Make really sure to wait for previews after zoom changes
Relying on the fact that the timer is not active anymore does not
guarantee that the previews at the correct zoom are ready because
the regeneration process may take several seconds and during this
time the zoom factor may be changed again. So, we need an additional
guard for assuring that everything has settled down.
2015-06-21 11:21:59 +02:00
Enrico Forestieri
dd09a5cabc Use the draft option for microtype
Instead of redefining \usepackage for avoiding the microtype package
when generating previews in dvi mode, the draft option can be used
for disabling it. This also allows to somewhat simplify the
fix_latex_file function.
2015-06-20 21:58:19 +02:00
Enrico Forestieri
cabc7c4be1 Fix another couple of issues spotted by Guillaume
* Take into account macro redefinitions in the legacy route
* Take into account macros inside nested macro definitions
2015-06-20 16:37:12 +02:00
Enrico Forestieri
b610c13f67 Amend 98a5072a
We only look once for the definition of the same macro, but we have
to always check its arguments when the same macro appears more than
once in a math inset. So, move earlier this check.
2015-06-20 03:05:50 +02:00
Enrico Forestieri
98a5072a58 Fix a couple of issues with macros and previews
* Fix typo causing to only account for the first char of a macro name
* Also check for macros as arguments of other macros
2015-06-20 01:44:22 +02:00
Juergen Spitzmueller
46aed6d2b9 Refine lang nesting fix 2015-06-19 19:03:11 +02:00
Kornel Benko
b2e4989212 Cmake export tests: Luatex tests pass now on some more files. 2015-06-19 10:54:40 +02:00
Juergen Spitzmueller
bd05bf71ef \frenchbsetup is a babel command 2015-06-19 10:11:17 +02:00
Juergen Spitzmueller
b1c68dccf8 Fix language nesting problem with polyglossia
Part (?) of #9633
2015-06-19 09:25:11 +02:00
Jean-Marc Lasgouttes
8b36c090b7 Simplify the code for "auto" toolbars handling
Instaead of passing a number of booleans, it make more sense to pass
the relevant visibility values in a single flag.
2015-06-18 15:51:53 +02:00
Juergen Spitzmueller
406d710131 Force local font switch in caption.
It is needed with polyglossia. With babel, it does not harm (and looks
more sensible).
2015-06-18 14:17:18 +02:00
Enrico Forestieri
d3bcb90839 Remove superfluous separators
These were added when the user guide was converted to latest format.
Their purpose is assuring that the vertical spacing is not changed for
old documents. Given that they also assure that the bad spacings in
nested item environments is preserved, let's simply get rid of them.
2015-06-17 11:31:10 +02:00
Juergen Spitzmueller
d722f5ed8e Properly pass char to stream (probably fix bug #9632) 2015-06-17 10:22:46 +02:00
Uwe Stöhr
1c71f1eaab UserGuide.lyx: merge changes to all language variants
(The UserGuide is currently not compilable because of bug #9632)
2015-06-17 01:23:57 +02:00
Uwe Stöhr
35f9acd11d SpaceMarker.png: fix image
fixes bug #9581
2015-06-17 00:53:53 +02:00
Enrico Forestieri
d12307449c Update it.po 2015-06-16 19:44:20 +02:00
Enrico Forestieri
cd14673834 Avoid unnecessary growth of python lists
The path argument of checkProg* was added to the PATH list in a nested
loop such that the list doubles in size each time the loop is executed,
thus also slowing down detection of missing programs.
2015-06-16 17:03:32 +02:00
Kornel Benko
75580f5f13 Update sk.po 2015-06-16 10:47:51 +02:00
Juergen Spitzmueller
97fbc64977 de.po 2015-06-16 09:48:33 +02:00
Juergen Spitzmueller
4c0e99ac3d Check for, and report, uncodable characters in user preamble.
Fixes: #9599
2015-06-15 21:08:40 +02:00
Enrico Forestieri
11c2b7792c Replacement for commits bc47054b and ad0d0f6d
The strategy adopted in bc47054b had some drawbacks related to the way
instant preview snippets are generated. See the subthread starting at
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg187916.html
for details.

The strategy adopted in this commit is that of adding macro definitions
only for the macros actually used in a preview snippet, independently
of whether some macro was already used in a previous snippet. In this way
the snippets don't need to be changed according to whether they are
compiled as a whole or separately from each other. This fact was causing
the regeneration of a preview snippet whenever the cursor entered the
corresponding inset, even if the generated image would have not changed.
The problem of defining or redefining a macro is taken care by the
python scripts.
2015-06-14 18:10:29 +02:00
Enrico Forestieri
bdec44d614 Revert bc47054b and the related commit ad0d0f6d
As discussed on the devel list. See the subthread starting at
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg187916.html
Soon to be replaced with the same strategy adopted in the stable branch.
2015-06-14 18:05:39 +02:00
Uwe Stöhr
643f9ad4da configure.py: add support for pandoc and docx
- make LyX aware of the docx format
- add converters to odt and docx using the program Pandoc
2015-06-14 17:27:21 +02:00
Georg Baum
f61555cf48 Improve alignment 2015-06-14 14:16:49 +02:00
Juergen Spitzmueller
ca1aea5427 Revert "remove unneeded notermination tags in unicodesymbols (bug #9615)"
This reverts commit a6fdc1196b.

The issue needs more discussion. See #9615.
2015-06-14 13:44:50 +02:00
Georg Baum
a2f127f8c3 Fix lyx2lyx unicodesymbols escaping
The escaping of symbols read from unicodesymbols was inconsistent, which lead
to wrong replacements (bug 9559). Now the escaping is consistent: unicode_reps
contains unescaped LaTeX commands, the needed escaping for LyX files is
applied in put_cmd_in_ert() and lyx2latex().
2015-06-14 12:44:44 +02:00
Juergen Spitzmueller
aa4d41d282 Fix reversion of mathtools xarrows (bug #9620). 2015-06-14 10:47:31 +02:00
Scott Kostyshak
a7a43d0866 Update description to reflect arg improvements 2015-06-14 01:42:41 -04:00
Uwe Stöhr
1b74cc421e lyx2lyx/lyx_2_2.py: fix typo in comment 2015-06-14 02:15:30 +02:00
Juergen Spitzmueller
77fa81a902 Fix revert_textcolor method (bug #9620) 2015-06-13 12:48:36 +02:00
Juergen Spitzmueller
f0923ebadc GuiParagraph: Fix remaining glitch when entering custom line spread
while immediate apply is activated.
2015-06-13 12:31:03 +02:00
Juergen Spitzmueller
930fef9d8d GuiParagraph: fix thinko (bug #9621) 2015-06-13 12:17:11 +02:00
Jean-Marc Lasgouttes
c783ef962d Fix cursor setting in right-aligned text
Fixes bug #9619.
2015-06-13 12:09:53 +02:00
Juergen Spitzmueller
111102909b Escape backslash 2015-06-13 11:37:36 +02:00
Georg Baum
6f84ceb821 Make tex2lyx tests green again
Unfortunately I overlooked in 44f73b0650 that the first three whitespace
changes in box-color-size-space-align.lyx.lyx were actually correct, so they
should not have been reverted. In detail:
1), 2): The space after \raggedleft must not be part of the ERT inset, but it
        is ouput by check_space() as part of the standard text which follows.
3):     The space in front of www is caused by the fact that there is a
        newline between the opening brace of the parbox and the \centering
        command, so this space is not the one after \centering (which is
        correctly swallowed). This additional space is in fact not needed,
        and the contents would look better in LyX without it, but since it is
        not caused by special code I'll put it back in the refernce for now.
        We can still improve this in the future if anybody has a good idea.

The remaining whitespace issues are all fixed by a simple change in
parse_text(): Instead of always eating whitespace after detecting \centering
et al, and always output a space as part of the ERT if these commands need an
ERT, let the standard space handling mechanism kick in: skip whitespace if
no ERT is used (in this case LyX will always output the needed space), and
do not touch whitespace if an ERT is used.
2015-06-11 22:25:00 +02:00
Georg Baum
0cd7d1f699 Support very much greater/less than
This is bug #9612. The patch is from Günter Milde. He wrote:
The patch uses the "long" macro names (\llless and \gggtr) to minimize
name-clash probability. (There is, e.g., a name clash of \lll with Babel's
polish.ldf (cf. bug #6197))
2015-06-11 20:40:04 +02:00
Georg Baum
90a524a075 Fix comments
The FIXME is not needed, this is how StyleChanger and FracChanger work:
In the constructor, they change the state of the FontInfo, and in the
destructor the state is set back. Therefore, all code that needs the changed
state, needs to be executed while the objects do still exist.
2015-06-11 20:40:04 +02:00
Jessica Hamilton
7cd2e55d1f Qt4: Prevent crash on Haiku when clicking in a document
Fixes bug #8595.
2015-06-11 18:12:35 +02:00
Jean-Marc Lasgouttes
ba13a832d6 Do not require libm when searching for system boost
Doing so breaks building under Haiku, which does not have libm.

See ticket #7568 for details.
2015-06-11 18:08:19 +02:00
Jean-Marc Lasgouttes
7da18d9db9 Add Jessica Hamilton to credits. 2015-06-11 17:41:09 +02:00
Juergen Spitzmueller
664ef2c459 Report missing characters on conversion with XeTeX or LuaTeX (bug #9610)
As discussed on trac, we treat this as error, since it severely
corrupts the output (dataloss).
2015-06-11 11:32:17 +02:00
Juergen Spitzmueller
a6fdc1196b remove unneeded notermination tags in unicodesymbols (bug #9615)
Patch by Guenter Milde
2015-06-11 11:14:01 +02:00
Juergen Spitzmueller
0c8019a903 consistent replacement for CEDILLA in unicodesymbols (bug #9614)
Patch by Guenter Milde
2015-06-11 11:11:26 +02:00