Commit Graph

34591 Commits

Author SHA1 Message Date
Enrico Forestieri
c057d4e7ee Make sure an unzipped file has correct extension.
If a mask is missing, the TempFile class appends it to the filename.
This may be a problem with applications relying on the extension,
so explicitly add a mask.
2015-03-13 17:28:18 +01:00
Kornel Benko
d9c867da19 Cmake build: QtGui now needed also for filetools.cpp 2015-03-13 14:22:12 +01:00
Enrico Forestieri
a3f8554103 Move svg icons to proper place.
You have to manually delete the lib/images/svg directory as git
tracks only files.

There may be warnings on the terminal due to some faulty icons that have
to be found and corrected. Moreover, some of the icons are not rendered
too well at the default size. These ones should be properly tweaked.
Kudos to Jürgen for putting together such a large number of icons.
2015-03-13 01:29:37 +01:00
Enrico Forestieri
7be2a5d815 Prefer svg icons.
If a compressed svg icon is present, load it instead of a png one.
Also introduce two more sizes (huge and giant icons) that should be
useful when using hires displays, as svg icons automatically scale
to the desired size without loss of quality.
2015-03-13 00:47:21 +01:00
Enrico Forestieri
d00dcc2ca7 Use the nominal theme's icon size for displaying the icon in an info inset. 2015-03-13 00:38:05 +01:00
Enrico Forestieri
bd9f5408cf Properly name an uncompressed sgvz file.
Some tools may rely on the extension and do not actually check whether
a svg file is compressed or not.
2015-03-13 00:34:53 +01:00
Enrico Forestieri
cbad159ac2 Make sure a temporary file is always created in the global temporary dir. 2015-03-13 00:31:08 +01:00
Georg Baum
d752334ec4 Fix tex2lyx script output
tex2lyx did not use the InsetLayout for the script insets, so it did not know
that it had to use Plain Layout. However, there is still a possible pitfall:
InsetScript uses a hard coded plain layout for the InsetText constructor, so
if anybody would remove ForcePlain 1 and MultiPar false from the InsetLayout
then LyX would still write script insets with plain layout, but tex2lyx would
output standard layout again.
2015-03-11 22:20:44 +01:00
Georg Baum
361967e613 whitespace 2015-03-11 22:03:29 +01:00
Georg Baum
d8ed62f496 Update tex2lyx test references
tex2lyx outputs the correct layout ("Plain Layout") for captions since
9d824a04d1. Previously, it did output  "Standard", which was wrong.
2015-03-11 21:02:59 +01:00
Kornel Benko
da46f6566a Preparation to support translations with python3
Thanks to José.
2015-03-11 20:54:28 +01:00
Jean-Marc Lasgouttes
58b3971eeb Avoid crash with after a params undo.
When doing a non-atomic undo, one should not try to merge with a previous params undo.

This fixes bug #7740.
2015-03-11 16:55:51 +01:00
José Matos
0a03528376 First step to make po python files to support both python 2 and python 3 (3.3+)
Most of the changes are related with dictionaries returning iterators instead of
    lists. (Iterators and not views as I wrote in the previous commit message)

    xrange -> range (since xrange is gone in python 3)
2015-03-11 13:41:10 +00:00
José Matos
9a0d70a45f First step to make lyx2lyx code support both python 2 and python 3 (3.3+)
Most of the changes are related with dictionaries returning views instead of
lists.

xrange -> range (since xrange is gone in python 3)

The code that is special to support both python 2 and 3 is enclosed in a comment
 \# Provide support for both python 2 and 3
and
 \# End of code to support for both python 2 and 3

And so later it can be removed safely when python 2 is no longer supported.
2015-03-11 12:09:18 +00:00
Scott Kostyshak
50b570e05a ctests: revert a MultilingualCaptions XeTeX test
This file and format exports correctly since 5753760b.
2015-03-10 23:35:49 -04:00
Georg Baum
24d011117f Remove unsupported macros from autocompletion
We have some math macros that exist only because LyX can display them easily,
but which require user preamble code. These commands should not appear in
autocompletion, they are only there to make the formulas of users who actually
need thgese symbols and know what to put into the preamble more beautiful.
2015-03-10 20:53:56 +01:00
Jean-Marc Lasgouttes
e86cc0135a Fix generation of lyx_commit_hash.h
Now version.o is not recompiled on already built tree.
2015-03-10 19:13:06 +01:00
Juergen Spitzmueller
9d824a04d1 Properly define MultiPar status of caption in the layout definition.
Also remove hardcoded paragraph break disabling.

Candidate for branch.
2015-03-10 18:31:55 +01:00
Kornel Benko
dbc4c71ef5 Cmake preparation to support python3 2015-03-10 17:29:58 +01:00
Jean-Marc Lasgouttes
c85ad29f11 Take in account the parent's getStatus in macro templates
This avoids invoking the insert space dialog instead of the math version. Thereafter, spaces are correctly inserted inside macro templates.

This is the last part of the fix to #9432.
2015-03-10 16:17:29 +01:00
Jean-Marc Lasgouttes
97c6e6d1ba Do not sanitize the anchor of cursor when selection is not set
Additionally, move the code to write to a stream from Cursor to CursorData (so that debugging undo is easier). We loose x_target, but I am not sure it is important.

This is the second part of bug #9432.
2015-03-10 16:17:29 +01:00
Jean-Marc Lasgouttes
17e435c47e Check that DocIterator::sanitize only adds editable insets
This fixes the crash on ticket #9432, but the bug there has other causes.
2015-03-10 16:17:29 +01:00
José Matos
631bbab889 First step to support python 2(.7) and 3(.3+)
When the work is finished the moniker "work in progress" should be removed.
2015-03-10 13:55:59 +00:00
Kornel Benko
4ac32ef351 Forgotten in previous commit
This is not needed bacause the command 'grep' is not
so language sensitive as pcregrep. It's only for the sake of consistence
2015-03-09 10:38:07 +01:00
Kornel Benko
0ed7f301ea Remove the need of specific language packs for keytests
The command pcregrep failed trying to set locales to
not installed language pack.
2015-03-09 09:41:34 +01:00
Enrico Forestieri
a78340e302 Reduce size of some svg icons.
The svg files produced by vector editors may end up containing a lot
of unused elements that increase their size without any impact on
quality. For example, this occurs when copy/pasting between images
such that unused effects or shadings simply clutter the files.
Removing these elements in some cases may reduce the size to one half
or one third of the original one, leaving unmodified the image quality.
2015-03-09 02:38:12 +01:00
Enrico Forestieri
9bcdf14e06 Add another bunch of svg icons.
Also tweaked some existing icons for better rendering at default size.
2015-03-08 20:25:40 +01:00
Uwe Stöhr
94d872696c pdfcomment.module: fix dependencies 2015-03-08 03:41:08 +04:00
Uwe Stöhr
5753760b59 MultilingualCaptions.lyx: port recent changes to master 2015-03-08 03:39:54 +04:00
Uwe Stöhr
297f607fda French MultilingualCaptions.lyx: this time really the french version 2015-03-07 13:16:35 +04:00
Jean-Marc Lasgouttes
f07ffaee84 Some code factorization for the Change template
The original motivation is to initialize the change_ member but do it only once.

This fixes coverity issue 23432.
2015-03-05 16:52:49 +01:00
Jean-Marc Lasgouttes
a0fd54b2e7 Remove variable properly now
This is a follow-up to db1979f398.
2015-03-05 12:48:01 +01:00
Jean-Marc Lasgouttes
24737eeceb Reset stream properties after changing them
Fixes coverity issue 23468.
2015-03-05 12:46:40 +01:00
Jean-Marc Lasgouttes
db1979f398 Remove unused member.
Fixes coverity issue 23413.
2015-03-05 12:30:12 +01:00
Jean-Marc Lasgouttes
0e2ef88b43 Fix uninitialized member in Lexer constructor
Fixes coverity issue 23501.
2015-03-05 12:24:47 +01:00
Jean-Marc Lasgouttes
c925748126 Fix uninitialized members in Language constructor
Fixes coverity issue 23412.
2015-03-05 12:17:52 +01:00
Jean-Marc
4e2f16e84e Fix uninitialized member in LaTexFont constructor
Fixes coverity issue 23382
2015-03-04 23:21:34 +01:00
Jean-Marc
1e94fc4fea Fix uninitialized member in Floating constructor
Fixes coverity issue 23402.
2015-03-04 23:13:06 +01:00
Jean-Marc
3705fd4eba Fix uninitialized members in Cursor and CursorData constructors
Fix coverity issues 23401, 23407, 23416 and 23429.
2015-03-04 23:00:07 +01:00
Jean-Marc
0fbc402141 Fix unitialized members in CacheItem
Fixes coverity issue 23380.
2015-03-04 22:50:37 +01:00
Jean-Marc
8d882e662b Add test for null buffer
This is actually not needed in practice.

Fixes coverity issue 23306.
2015-03-04 22:46:48 +01:00
Jean-Marc
a5a01b6af3 Fix uninitialized members in Compare::Impl
Fixes coverity issue 23418.
2015-03-04 22:35:40 +01:00
Jean-Marc
08c9f208fb Pass parameters by reference (performance)
Fixes coverity issues 23339 and 23347.

Some additional spacing changes sneaked in.
2015-03-04 22:26:28 +01:00
Jean-Marc
fbe333245e Fix unintialized member of BufferView::Private
Fixes coverity issue 23404.
2015-03-04 22:17:51 +01:00
Jean-Marc
fac7cb922a Fix missing break in switch
Fixes coverity issue 23350.
2015-03-04 22:13:20 +01:00
Jean-Marc Lasgouttes
9448e89879 Remove unused variable BufferParams::quotes_times
This was pointed out inadvertently by coverity issue 23484: the
variable was not properly initialized.
2015-03-04 18:21:58 +01:00
Jean-Marc Lasgouttes
0552563c99 Initialize Buffer::Impl members correctly
In practice the variables were initialized later as needed.

Fixes coverity issue 23497.
2015-03-04 17:57:29 +01:00
Jean-Marc Lasgouttes
1d2b7fb1ec Initialize object properly
Fixes coverity issue 23363
2015-03-04 17:48:44 +01:00
Enrico Forestieri
afeae62f3f Update cygwin script.
Recent versions of the cygwin X11 server come with a startup script
that explicitly uses '-nolisten tcp' for improved security. This means
that mentioning a host part in the DISPLAY variable precludes correct
operation. So, leave blank the host part such that only local connections
are attempted. Even if a user can override this setting in the own
~/.lyxprofile, novice users (and even experienced ones, at first) would be
probably confused by the "Error: Can't open display: localhost:0" message
and thus it is better to make this work out of the box.
2015-03-03 18:17:37 +01:00
Enrico Forestieri
b4b02da31f Add another bunch of missing svg icons.
I also tweaked some existing icons to make them look better at default size.
Moreover, some text was replaced with paths, because the required font may
not exist on a system and font substitution would take place, making the
icons look different on different systems.
2015-03-03 15:43:10 +01:00