Commit Graph

4704 Commits

Author SHA1 Message Date
Pavel Sanda
154319d063 Remove some header leftovers based on Scott's script hints.
False positive rate of hints is quite high. Although the includes can be
technically removed (due to other includes) they logically belong to the
header.
2013-05-02 00:30:16 -07:00
Richard Heck
76c96c22ac Another assertion that got changed wrongly.
I've read back through that patch, and everything else looks good.
2013-04-27 18:12:27 -04:00
Richard Heck
d79225ae98 Remove all messages to user related to assertions. We'll just use
a basic message which is defined in lassert.cpp now.
2013-04-27 17:52:55 -04:00
Richard Heck
1b1f8dd235 Audit all the LASSERT calls, and try to do something sensible at
each failure.

There are several places I was not sure what to do. These are marked
by comments beginning "LASSERT:" so they can be found easily. At the
moment, they are at:

Author.cpp:105: // LASSERT: What should we do here?
Author.cpp:121: // LASSERT: What should we do here?
Buffer.cpp:4525:        // LASSERT: Is it safe to continue here, or should we just return?
Cursor.cpp:345:         // LASSERT: Is it safe to continue here, or should we return?
Cursor.cpp:403:         // LASSERT: Is it safe to continue here, or should we return?
Cursor.cpp:1143:                // LASSERT: There have been several bugs around this code, that seem
CursorSlice.cpp:83:     // LASSERT: This should only ever be called from an InsetMath.
CursorSlice.cpp:92:     // LASSERT: This should only ever be called from an InsetMath.
LayoutFile.cpp:303:                     // LASSERT: Why would this fail?
Text.cpp:995:           // LASSERT: Is it safe to continue here?
2013-04-25 17:27:10 -04:00
Vincent van Ravesteijn
262f58ddc3 Fix the size of the hAlign combobox in GuiTabular
The default sizeAdjustPolicy is AdjustToContentsOnFirstShow. As the
combobox is initially filled with all items, it will not change size if we
later remove the 'At Decimal Separator' item.
2013-04-25 22:35:56 +02:00
Vincent van Ravesteijn
6f8a74791b Adjust CMake for Qt5 2013-04-23 21:45:49 +02:00
Scott Kostyshak
b75ecdfaf0 GuiRef: only enable "Group" CB if non-empty refs 2013-04-22 15:39:16 -04:00
Scott Kostyshak
21d1f97cad GuiRef: do not insert a category as a ref
Before, if a user had "Group" checked in GuiRef and double-clicked
on a category, that category would be inserted as a (broken)
reference. Now, when a category is double-clicked, nothing happens.
2013-04-22 15:39:16 -04:00
Scott Kostyshak
647ae51a46 GuiRef: do not hide labels that start with ':'
If a label starts with ':' and 'Group' is checked,
the label is now shown under "<No prefix>" instead of
not shown.

Note that labels starting with ':' can be valid in LaTeX.
2013-04-22 15:39:16 -04:00
Scott Kostyshak
9887dd48ca GuiRef: only show "<No prefix>" if non-empty
If "Group" is checked, "<No prefix>" is shown only if there exists a
label with no prefix. Before, it was shown even when it was empty and
even when there were no labels at all.
2013-04-22 15:39:16 -04:00
Uwe Stöhr
0050245151 PrefInputUi.ui: change 2 strings
because all over the docs we refer to the keyboard maps as primary and secondary
2013-04-21 20:20:08 +02:00
Juergen Spitzmueller
be0610362d Revert "Fix the zombie toolbar problem (bug #8520)"
This reverts commit d00ec4dece.
2013-04-20 11:42:21 +02:00
Juergen Spitzmueller
f3bb757f97 Revert "avoid redundant toolbar initialization"
This reverts commit 0f26aabeee.

It turned out this breaks session.
2013-04-20 11:40:40 +02:00
Georg Baum
60448bf681 Whitespace 2013-04-19 21:34:05 +02:00
Georg Baum
c14b9e67bc Implement paste from LaTeX and HTML (bug #3096)
As discussed on the list. No automatic contents detection is done, the user
needs to use the special paste menu instead. I used the new TempFile class
for safe temporary file handling.
The documentation would go into section 2.2 of UserGuide.lyx, but I am not
allowed to edit that document.
2013-04-14 19:45:36 +02:00
Georg Baum
0613a218aa Also put HTML on the clipboard when copying
The HTML export is now mature enough so that it can be used to transfer
formatted text to the clipboard. This enhances interoperability e.g. with
office applications.
2013-04-12 22:12:47 +02:00
Vincent van Ravesteijn
ea7d36912b Use setSectionResizeMode from qt_helpers
This is needed to compile with Qt5.
2013-03-30 12:41:08 +01:00
Richard Heck
5fbbd863db Remove "List of" from outliner dropdown. 2013-03-28 08:33:21 -04:00
Richard Heck
410c716bf7 Add Nomenclature to the TOC. 2013-03-27 20:03:32 -04:00
Vincent van Ravesteijn
cb93f034d4 Add an LFUN for continuous spell checking
This fixes the first part of #8589.
2013-03-24 20:28:37 +01:00
Vincent van Ravesteijn
a31df78133 Do not sort formats in BufferParams::exportableFormats
We only need to sort the formats when it is really necessary, i.e. for GUI
purposes.

This also prevents 11000 requests for translation everytime the toolbars
are updated.
2013-03-24 18:06:32 +01:00
Vincent van Ravesteijn
2662386077 Small simplification 2013-03-24 16:47:03 +01:00
Richard Heck
cca2d4c927 Crush warning. 2013-03-23 09:14:44 -04:00
Georg Baum
c61ef8b205 Support \caption* (bug #3209)
This was a low hanging fruit which would have to wait for a long time because
of a file format change if it was not implemented before 2.1.
2013-03-22 22:23:38 +01:00
Uwe Stöhr
22ad7e4369 support for \mbox and \fbox
- fileformat change
- it was a pity that LyX did not yet support a simple rectangular frame without a defined width but LyX did this for e.g. oval frames
- \fbox and \mbox often occur in TeX files and can now be imported
2013-03-22 01:33:58 +01:00
Juergen Spitzmueller
0f26aabeee avoid redundant toolbar initialization 2013-03-20 13:59:25 +01:00
Juergen Spitzmueller
d00ec4dece Fix the zombie toolbar problem (bug #8520) 2013-03-20 13:01:48 +01:00
Scott Kostyshak
ccd46cbe8e GuiTabular: disabling is now done on textChanged()
Before, it was done on editingFinished(). The new behavior is more
intuitive because it is easier for the user to see how editing the box
is connected with enabling/disabling the other widgets. Before, the user
would not get instant feedback and would have to click away before the
connection is revealed. This new behavior is less efficient, however,
because checkEnabled() is called after every keystroke.
2013-03-19 14:48:20 -04:00
Scott Kostyshak
429b39bc0c GuiTabular: LC and ED should both be disabled
Previously, only columnWidthED was disabled.
2013-03-19 12:25:38 -04:00
Richard Heck
6dac777dbc Don't try to show the status message if we are busy.
Intended to fix #8523.
2013-03-18 19:49:33 -04:00
Vincent van Ravesteijn
41843646b7 Fix monolithic build 2013-03-18 20:42:28 +01:00
Richard Heck
bb36296275 Remove unused code. 2013-03-08 16:22:01 -05:00
Juergen Spitzmueller
9b0f907871 Minor UI polishment 2013-03-02 16:23:51 +01:00
Juergen Spitzmueller
0f48953a7d Re-Introduce translatable line breaks in tool tips
Real line breaks in (recent?) designer are not recognized by lyx_pot.py
2013-03-02 14:30:56 +01:00
Juergen Spitzmueller
dc7029dbf7 Small tweaks to the new pref pane(s) 2013-03-02 14:15:11 +01:00
Juergen Spitzmueller
a4a610221a Split the overcrowded and chaotic UI pref pane into two (#7524) 2013-03-02 12:24:32 +01:00
Juergen Spitzmueller
3861fa1cb4 Maths packages: Further GUI improvements 2013-03-02 10:03:08 +01:00
Juergen Spitzmueller
e53b5972c3 Improve math packages GUI 2013-03-01 15:59:37 +01:00
Kornel Benko
8f36aef17a Added "cancel" to the GUI handled list of LaTeX packages.
Generalized convert_use_???() and revert_use_???() routines in lyx2lyx.
2013-02-27 13:12:03 +01:00
Julien Rioux
9dd1b7c578 Use the LyX name of encodings instead of the LaTeX names.
- Use the LyX name of encodings instead of the LaTeX names.
  The LyX name must be unique, while the name used by LaTeX
  not necessarily, e.g. different packages might implement
  support for the same encoding.

- Rename koi8 to koi8-r, so that the LyX and LaTeX names match.

- Rename euc-jp-plain to euc-jp-platex, jis-plain to jis-platex
  and shift-jis-plain to shift-jis-platex.

- Add utf8-platex encoding (fixes #8408).

LyX file format incremented to 463.
2013-02-18 23:52:42 +01:00
Juergen Spitzmueller
a063defd9f If a LaTeX font has a monolithic option for all expert sets (Osf, SC), honor this in the GUI (#8547) 2013-02-11 15:02:24 +01:00
Pavel Sanda
75090250d4 Add very simple revision comparison for git.
At this moment we do not allow comparison between arbitrary hashes,
but except GUI the code is ready.
Thanks to the powerful way of git addressing we could even ask
for comparisons like '-2 weeks back' if someone wants to play
with GuiCompareHistory.
2013-02-09 19:35:22 -08:00
Richard Heck
57d8b059e0 Remove references to Counter LabelType from source code. The
intention is to use Static in its place, and we now expand the
label for these, as well.
2013-02-09 13:44:05 -05:00
Georg Baum
0526eb9d47 Implement VCS copy and rename
The advantage of having this in LyX is the intelligent file name handling
of included files. Implementation as discussed on the list, but ensure also
that an attempt to use locked files fails.
2013-02-06 20:38:54 +01:00
Jean-Marc Lasgouttes
14e01a92a4 Rename Path.h to PathChanger.h (actual name of the class) 2013-02-06 11:51:06 +01:00
Georg Baum
d33450a592 Fix inconsistent VCS checkin return values
It is not possible to transport the different error/abort/success conditions
of a VCS checkin through a simple empty or nonempty string. Therefore it was
no wonder that the return values were used inconsistently for different VCS.
Now the log and return status are decoupled, and all VCS are handled
consistently. This is a prerequisite for proper locking detection of the
upcoming rename command.
2013-02-04 22:01:59 +01:00
Stephan Witt
141fbb6f8c Prepare LyX code to compile and link with Qt5:
* some functionality is in new modules now
  new header locations and library names: QtConcurrent and QtWidgets
* method setResizeMode is renamed to setSectionResizeMode
* deprecated QAbstractItemModel::reset() is dropped now
* platform specific code like QApplication::syncX() is not common anymore
* QString::fromAscii() is dropped now
* some QDesktopServices methods has been moved to QStandardPaths
2013-02-03 19:26:21 +01:00
Juergen Spitzmueller
0de23da9cd Tooltip change as suggested by Jean-Pierre 2013-02-02 09:08:42 +01:00
Jean-Marc Lasgouttes
652512a38c Clarify two strings in PDF properties
This is a patch from Martin Vermeer.
2013-02-01 15:00:41 +01:00
Juergen Spitzmueller
e199ec0310 Fix typo spotted by Jean-Pierre 2013-01-20 15:33:33 +01:00
Julien Rioux
6c58e3faa9 Highlight warning and errors in the BibTeX log. 2013-01-15 16:13:20 +01:00
Georg Baum
d2b49e54b9 Add remaining images for math symbol toolbar
Most images are generated by development/tools/generate_symbols_images.py, but
some were drawn manually. Now there is no image missing from the ones the
script can generate.
2013-01-10 21:22:55 +01:00
Juergen Spitzmueller
b57f585109 GuiSymbols: Use a grid with appropriat size 2013-01-10 13:19:14 +01:00
Juergen Spitzmueller
0dd91a1fd7 do not setUniformItemSizes since the symbols have different width (bug #5707) 2013-01-10 11:33:09 +01:00
Juergen Spitzmueller
f164ffd093 do not try to expand arguments in mathed (bug #8482) 2013-01-05 09:41:53 +01:00
Georg Baum
a98f7ad02d Fine tune image generation 2012-12-31 18:22:05 +01:00
Juergen Spitzmueller
2a273ce4c1 Remove redundant 'Caption' string 2012-12-31 10:18:05 +01:00
Georg Baum
ee3ce572a0 Fix import of shift-jis and big5 CJK texts.
These encodings were not defined, since they must not be used as document
encodings (the characters {, } and \ may appear in high bytes, and latex
would be confused). However, they are supported by CJK.sty (which uses a
preprocessor to circumvent the limitations of the latex executable). These
encodings are now defined, but used for import in tex2lyx only.
The test case CJK.tex contained fake tests for shift-jis and big5 (the
japanese and chinese characters were entered using the utf8 encoding), and
therefore the wrong interpretation of these encoding looked as if it worked.
The comments about missing iconv support of shift-jis and big5 were wrong as
well (otherwise shift-jis-plain would not work either).
2012-12-30 20:52:50 +01:00
Juergen Spitzmueller
c246076ed5 Fix the 'caption inset mess' (bug #4647) 2012-12-30 18:29:02 +01:00
Georg Baum
56ece75ad9 Fix bug #8464: stackrel with subscript.
The fix is basically mechanical, the additional code for fraction like insets
with three arguments was stolen from \unitfrac. As any math package,
stackrel.sty needs a buffer parameter to switch it off.
I also added the two stackrel flavours to the toolbar.
2012-12-28 20:08:43 +01:00
Vincent van Ravesteijn
a19a0edfc0 qt5: Use QStyleOptionTabWidgetFrame
QStyleOptionTabWidgetFrameV2 is identical to QStyleOptionTabWidgetFrame.
2012-12-28 14:07:43 +01:00
Georg Baum
23b74a9111 Add toolbar images for stmaryrd.sty symbols
These are all generated by development/tools/generate_symbols_images.py, the
only manual adjustments were renamings due to case sensitive file systems on
windows.
2012-12-28 13:25:41 +01:00
Juergen Spitzmueller
37f41fd4b5 Support for command argument placement after the workarea argument 2012-12-28 11:21:24 +01:00
Vincent van Ravesteijn
bec9c1325e Introduce Layout::args() and simplify code 2012-12-17 22:26:11 +01:00
Vincent van Ravesteijn
8db4faa160 Move LengthCombo into namespace lyx::frontend 2012-12-17 21:38:57 +01:00
Vincent van Ravesteijn
d87c43d1b9 The first include must be <config.h> 2012-12-17 21:38:53 +01:00
Georg Baum
01a6d4252b Full delimiter support for llbracket and rrbracket
stmaryrd.sty sets these symbols up as variable size math delimiters (i.e.
they may be used with \left and \right). Now LyX knows about that and offers
them in the delimiter dialog as well as single symbols.
2012-12-16 15:49:42 +01:00
Georg Baum
f67cf6f4bb Add support for stmaryrd.sty (bug #8434)
The stmaryrd package adds support for lots of math symbols, using a font
designed to accompany the computer modern fonts. The changes in detail:

- Fix generate_symbols_list.py to work with stmaryrd.sty. It loooks like it
  was automatically translated from a perl version and never used.
- Generate the new symbols in lib/symbols using generate_symbols_list.py and
  add some manual adjustments
- Generate stmary10.ttf by a simple ttf export from stmary10.sfd with fontforge
- Add license info for stmary10.ttf
- Create a test file with all symbols from stmaryrd.sty. Actually it would be
  nice to have this for the other fonts as well.
- The mechanics: lyx2lyx, tex2lyx, font machinery etc.
2012-12-15 13:10:31 +01:00
Vincent van Ravesteijn
3a96ef6dca qt5: add/remove some includes 2012-12-15 11:11:55 +01:00
Vincent van Ravesteijn
ce8d52f813 qt5: Use Qt::WindowFlags instead of Qt::WFlags 2012-12-15 11:07:35 +01:00
Vincent van Ravesteijn
0cd8c03d17 CMake: Put projects into subdirs
This patch puts all projects into subfolders (at least for MSVS). In this
way, there is a better overview (especially if the number of test projects
will be increasing).
2012-12-15 11:02:06 +01:00
Juergen Spitzmueller
625e25264b Consider filtering when selecting from categorized combo (#8452) 2012-12-10 12:52:23 +01:00
Juergen Spitzmueller
25ef8e7eef Allow to separate menu string from label string for arguments 2012-12-09 19:15:41 +01:00
Georg Baum
99ffb47cc3 Replace some hard coded numbers with names
And prevent a crash if LaTeX is accidentally output for a math font.
2012-12-09 13:05:19 +01:00
Jean-Marc Lasgouttes
0425500be5 Set window title correctly at start up 2012-12-05 22:46:29 +01:00
Richard Heck
ae7bc12ab6 Disentangle moduleCanBeAdded for ordinary layout modules and the
new (but not yet functioning, it seems) citation modules. This
fixes a bug reported on the list:
  http://marc.info/?l=lyx-users&m=135456590710371&w=2
2012-12-05 11:16:21 -05:00
Juergen Spitzmueller
1500e44cba Support for \item arguments 2012-11-29 15:34:20 +01:00
Pavel Sanda
ad42e885e6 Rescue monolithic build after 32fde61c8f. 2012-11-24 17:48:47 +01:00
Juergen Spitzmueller
182d13ee6a Do not separate the shortcut from the label string 2012-11-23 18:26:02 +01:00
Juergen Spitzmueller
9914f21bce Context menu for InsetArgument 2012-11-23 14:44:45 +01:00
Juergen Spitzmueller
2e69c66195 InsetArgument revision, first working version 2012-11-19 14:21:02 +01:00
Georg Baum
9d99d3dbea Implement extractFromVC() for CVS and SVN.
Both cvs and svn are able to retrieve non-existing files from repository,
but this was only implemented for rcs. This is a prerequisite for the
planned move and copy VCV operations. I also improved error schecking and
used extractFromVC() also for files specified on the command line if they
do not exist (in GUI mode, it was already the case in non-GUI mode).
2012-11-15 22:01:19 +01:00
Pavel Sanda
d7ed0ba7e4 Autosaving is now always threaded. 2012-11-04 16:51:18 +01:00
Pavel Sanda
4f24d123b2 Next leftover. 2012-11-04 01:38:34 +01:00
Pavel Sanda
eb9151c599 Close tab button started with 4.5. 2012-11-04 01:37:54 +01:00
Pavel Sanda
38c836f65d Leftover. 2012-11-04 01:29:08 +01:00
Pavel Sanda
4a0911f25e Header sorting. 2012-11-04 01:26:11 +01:00
Pavel Sanda
0a9735c5f7 LyX 2.1 will support only Qt>=4.5.
(http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg175737.html)

Now start with simple cases.
2012-11-04 01:22:32 +01:00
Kornel Benko
d91d6e3343 Cmake build:
Cleanup the use of path-variables
2012-11-02 13:33:22 +01:00
Lars Gullik Bjønnes
d52c9fda34 Use new T not new T() 2012-10-27 01:25:38 +02:00
Lars Gullik Bjønnes
43f6b1672b Use empty() to check empty and non-empty'ness not size()
Also add FormatList::empty().
2012-10-27 01:25:38 +02:00
Lars Gullik Bjønnes
dd2189656b More idiomatic way of checking if a shared_ptr has an associated managed object 2012-10-25 12:12:49 +02:00
Kornel Benko
1b65a03c13 Cmake build: cleanup 2012-10-25 11:19:09 +02:00
Kornel Benko
d1ca207e94 Cmake build:
Next try to create Resources.qrc on the fly.
This time using a cmake-script instead of trying to rebuild the cache
2012-10-25 10:45:28 +02:00
Scott Kostyshak
250f60f36b Simplify LFUN_BUFFER_FORALL
buffer-forall only takes one parameter now, which is the LFUN to
dispatch on all non-hidden buffers. A hidden buffer is defined as being
internally open in LyX, but not visible in any window (view).

Thanks, JMarc.
2012-10-15 10:05:20 -04:00
Stephan Witt
593276f87d MenuTranslator::translate() should be const 2012-10-14 14:36:18 +02:00
Vincent van Ravesteijn
9547725c38 Disambiguate std::bind, boost::bind, std::ref, boost::ref (2)
This fixes compilation with MSVC2012.

See also [2b0a7a5e/lyxgit].
2012-10-12 21:29:57 +02:00
Jean-Marc Lasgouttes
06f394a3d4 Show keyboard binding when a layout selection is done in LayoutBox
The obnoxious messages in Private::setFilter cover any message set by lyx::dispatch. The solution I chose is to return early when the filter is not changed.

If this makes sense, then the same optimization should be added to CategorizedCombo, IMO.
2012-10-11 00:21:38 +02:00
Kornel Benko
648e197021 Cmake build: Define for 'DEVEL_VERSION' already done in development/cmake/config.h.cmake 2012-10-09 22:45:12 +02:00
Juergen Spitzmueller
c85135090e Stick to bformat 2012-10-09 16:12:32 +02:00