Commit Graph

662 Commits

Author SHA1 Message Date
Enrico Forestieri
10f1370464 On windows, allow saving a document whose pathname contains unicode chars.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33539 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-22 19:34:25 +00:00
Enrico Forestieri
37974532f6 Fix bug #5238: LyX 1.6 fails with non-ascii chars in path (on Windows)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33524 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-21 04:51:27 +00:00
Enrico Forestieri
f5cc73f583 Avoid unnecessary exceptions.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33516 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-19 16:31:15 +00:00
Jürgen Spitzmüller
90e28136b6 * Buffer.cpp:
- Issue a warning if a path contains uncodable characters (bug 6301).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33514 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-19 14:47:19 +00:00
Vincent van Ravesteijn
5441eb16e5 Correct r33454.
I like braces.. too much.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33455 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-12 23:03:43 +00:00
Vincent van Ravesteijn
2a8fb9ae52 Fix bug #6525: Autosave error when renaming a new file.
Don't try to move the autosave file if it does not exist.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33454 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-12 23:01:36 +00:00
Pavel Sanda
70e12ff55d Fix #6496, patch from Vincent.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33450 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-12 14:23:50 +00:00
Pavel Sanda
5942071ccb Fileformat++ as a safety measure.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33430 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-12 01:57:49 +00:00
Pavel Sanda
a97f1ddf06 Connect to InsetInfo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33426 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-12 01:44:04 +00:00
Uwe Stöhr
8bb69f24b6 support for multirows in tables:
- fileformat change (lyx2lyx code follows the next days)
- the patch is a joint work of Edwin and me

The patch is huge but the major parts work already. I put it in now as the minor known issues can be solved step by step the next days. I think this is the best solution because collaborating with such large patches already lead to copy/paste bugs.

The known issues are listed here:
http://wiki.lyx.org/Devel/Multirow

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33414 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-11 01:07:54 +00:00
Abdelrazak Younes
d77a22e2f9 Today is a sad day, LyXView has passed over... long live GuiView!
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33393 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-09 17:06:40 +00:00
Abdelrazak Younes
377cdd5f6c Transfer LyXfunc code to GuiApplication::dispatch() and getStatus(). Now
a lot of simplification is possible. Except some instability period...


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33389 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-09 16:11:13 +00:00
Jürgen Spitzmüller
a70e21a34e Patch by John McCabe-Dansted to fix bug #6502:
Wrong line count with parent math macros:

* TeXRow.{cpp,h}:
	- new helper function to insert multiple newline at once.

* mathed/MacroTable.{cpp,h}:
* mathed/MacroTemplate.{cpp,h}:
	- make write() an int, returning number of newlines

* Buffer.cpp (writeLaTeXSource):
	- update texrow's newline on parent macro output.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33367 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-08 17:39:55 +00:00
Jürgen Spitzmüller
a61eeb1fb2 Allow to switch buffer languages via the menu.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33366 a592a061-630c-0410-9148-cb99ea01b6c8
2010-02-08 17:15:00 +00:00
Vincent van Ravesteijn
046a43fe5f Revert r33295. This seems to be a not so great idea. The assert already fires when copying something.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33301 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-31 20:51:15 +00:00
Vincent van Ravesteijn
9065f48ead Add an assert to check for a fully loaded Buffer before trying to save it.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33295 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-31 16:20:47 +00:00
Vincent van Ravesteijn
d49438e76c Return failure if the file ended unexpectedly.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33293 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-31 15:59:23 +00:00
Abdelrazak Younes
9eabfb51ac Buffer: Pimpl private methods and fix a few constness issue.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33227 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-25 18:39:08 +00:00
Abdelrazak Younes
a4e56ba613 Buffer: Pimpl gui_ and remove unused code. support/SignalSlot* should
probably go also as we agreed that if we need signal/slot in src/ we'll
directly use Qt's.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33224 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-25 14:32:39 +00:00
Abdelrazak Younes
d9f22c0233 Get rid of mostly unused methods.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33223 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-25 14:13:04 +00:00
Abdelrazak Younes
11474f6b89 Get rid of Buffer::setReadOnly() pseudo signal.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33222 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-25 13:31:07 +00:00
Richard Heck
bb044b16c9 Formatting.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33132 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-21 18:12:23 +00:00
Richard Heck
caa4e94bf0 Get rid of some magic booleans in updateLabels() and related routines.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33110 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-20 19:42:12 +00:00
Richard Heck
22dc345e8c Better XHTML output for InsetRef.
The idea here is to implement something like \refstepcounter for LyX. We
do this by tracking the "active" counter in Counters.cpp. We also have
to track when we go in and out of environments to which counters are
local, and so on and so forth.

This all gets done in updateLabels(), but only if we are producing
output, which is why I added the output boolean a while ago.

I expect there are bugs in here, though it seems to work pretty well
with the documents I've tested.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33108 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-20 19:03:17 +00:00
Richard Heck
37f4de4cd2 The BufferList does not know about cloned buffers, so the parent of a
cloned Buffer is always "unloaded" as far as the BufferList is
concerned.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33105 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-20 17:53:18 +00:00
Richard Heck
1832a388c5 Collect the title for XHTML output, and use it.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33097 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-19 19:43:15 +00:00
Richard Heck
c4d8a27585 Better error messages for failed conversion.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33034 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-14 17:11:02 +00:00
Richard Heck
14f8faa01a A couple changes related to cloning:
(i) release the macro lock after we've cloned, so that...
(ii) we can regenerate the macro caches before doing XHTML output.
It may be worth doing the regeneration in the clone() routine itself,
but it appears that the export routines now all do it anyway.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32983 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-12 15:25:04 +00:00
Richard Heck
ce87e6767c Check the bibliography cache only when we really need to do so. This (a)
prevents weirdness that might happen if the .bib file were to change
during updateLabels(), (b) prevents even further weirdness that might
happen if it changed during the output routines, and (c) ought to avoid
slowness caused by the repeated calls to QFileInfo::refresh() needed to
check the cache status.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32972 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-11 16:29:26 +00:00
Jürgen Spitzmüller
7a7ab8f14b Add an option to assure that all aux files are maintained when using the includeonly feature, so that the
page numbering and the references of the master file are maintained in the included children (bug 1005).

I made this optional since some people use \includeonly to save compilation time, but a proper aux file update
needs a full compilation of the complete master prior to the compilation of the \includeonly master.

Hence, a new buffer param is introduced (file format change). 

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32936 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-10 13:25:41 +00:00
Abdelrazak Younes
e4e43f63d2 Buffer cloning: copy the different bib caches.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32920 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-09 18:16:07 +00:00
Abdelrazak Younes
fefd99e836 Fix memory leak.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32913 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-09 16:21:37 +00:00
Richard Heck
a397cc81c2 Style.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32912 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-09 16:15:46 +00:00
Abdelrazak Younes
cda980db51 Fix multipart document background compilation. I am not fully satisfied with this solution (see FIXME in Buffer::clone()). There might be some memory leaks...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32910 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-09 14:47:47 +00:00
Vincent van Ravesteijn
e0a6a7a542 Move some code from Buffer::loadLyXFile to LyXVC::file_not_found_hook. Accoring to the description of the latter, this should already be the case.
Furthermore, make sure that the read-only flag is always set to both true and false, since now the buffer can be read-only during a reload.

Last, set the buffer clean after a successful reload.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32896 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-08 18:48:36 +00:00
Richard Heck
c90b4fcb87 Use calculated labels in XHTML output.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32892 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-08 18:19:37 +00:00
Richard Heck
295b84e8fb Fix a BibTeX caching bug. Because we only set the last modified time
when the cache was valid, we did not set it the first time through and
so always read the cache twice.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32890 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-08 18:18:05 +00:00
Richard Heck
012be55afd Move the collection of citations and sorting routines into BiblioInfo.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32887 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-08 16:40:41 +00:00
Abdelrazak Younes
cf3baab621 On the road to fix #6415. The texrow object contains the correspondance
table between tex rows and the lyx paragraph ids.
Not fixed yet it seems as the texrow object do not copy correctly.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32876 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-08 09:00:28 +00:00
Vincent van Ravesteijn
d95aaa0e5b Move reloadBuffer from GuiView to Buffer.
This fixes bug #6314: reloading master document makes emergencies of modified children.

Now also the version control handling could be moved to Buffer as well, and the hack in ensureBufferClean is removed.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32875 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-08 02:15:56 +00:00
Vincent van Ravesteijn
570f96bc6e Add a boolean to GuiWorkArea::redraw to indicate whether the metrics must be updated. The current test "lyx_view_ != guiApp->currentView() || lyx_view_->currentWorkArea() != this" is not enough, especially not if the buffer is changed and buffer->changed() is called. Moreover, there are a lot of combinations of updateMetrics() followed by buffer->changed(), these can now be replaced by one call to buffer->changed(bool).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32874 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-08 02:03:54 +00:00
Jürgen Spitzmüller
1ccfe14914 * Add native support for \includeonly (bug 5360).
File format change.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32826 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-07 10:01:26 +00:00
Abdelrazak Younes
50e673f041 Add a FIXME for asynchronous export and preview and child buffers.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32768 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-05 13:29:01 +00:00
Abdelrazak Younes
24f3ddef3f typos.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32767 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-05 13:20:57 +00:00
Abdelrazak Younes
744ee152fa Cleanup a bit the pargraph ids generation in order to (trying to) fix
#6415
Enrico please verify that reverse dvi is fixed.

* Text and InsetText: create two private constructors and transfer some
initialisation code from InsetText.

* Paragraph: id generation is transfered to Text. May be transfered to
Buffer in the future, we'll see.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32766 a592a061-630c-0410-9148-cb99ea01b6c8
2010-01-05 13:16:55 +00:00
Richard Heck
28e9474f7a Some BufferParams for XHTML output.
These are not actually implemented yet, but I wanted to make sure to get
them into the format now, so even if I can't implement them before the
1.7 release, I can do so during the release cycle, without a format
change. I don't expect that to happen, but you never know....


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32683 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-30 22:22:33 +00:00
Tommaso Cucinotta
5da4ccb931 Implemented the "Current Buffer" & "Current (Master) Document" scopes in the Advanced Find and Replace feature.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32678 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-30 18:40:18 +00:00
Richard Heck
97a4f77443 Restore the privacy of the parent_buffer. We want all access to go via
the accessors, so we can do appropriate checks.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32628 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-24 19:19:53 +00:00
Peter Kümmel
8049e3f510 move calls to Buffer::errors and Buffer::message to GUI thread
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32606 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-21 13:11:17 +00:00
Vincent van Ravesteijn
45b0c6be47 Fix the threaded preview and reenable it.
Buffer::Impl::inset was set in the ctor Buffer::Impl::Impl to be a clone. However, in the Buffer::Buffer ctor the inset was set again, now to a new and empty InsetText.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32589 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-19 15:46:45 +00:00
Abdelrazak Younes
bea0925f8c Converter: add a safe guard to Alerts because those cannot be called from another thread. The whole Alert system must be rethought I am afraid.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32585 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-18 22:59:59 +00:00
Abdelrazak Younes
4ed0169064 Detach Buffer preview and update preview in a new thread. Only for Qt4.4 users. This new feature can be disabled by setting EXPORT_in_THREAD to 0 in GuiView.cpp.
Two things are missing (but are fixable):
- the lack of feedback of the background latex compilation
- the error list is not shown in case of compilation error.

* Buffer:
- create a "cloned buffer" type.
- Transfer LFUN_MASTER_BUFFER_UPDATE, LFUN_MASTER_BUFFER_VIEW, LFUN_BUFFER_UPDATE and LFUN_BUFFER_VIEW to GuiView. This is good itself as these LFUN are GUI oriented.

* GuiView: detach the above LFUNs to a new thread as was already done for autosave. 


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32584 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-18 22:51:06 +00:00
Abdelrazak Younes
622e3b1e4d For Qt4.4 and up: Detach Buffer autosave into a new thread.
* Buffer: new clone() method. When this new autosave method is used the old autoSave() is not of course.

* GuiView: clone the current document buffer and save it in a new thread.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32512 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-13 21:00:46 +00:00
Vincent van Ravesteijn
8c8675e2ca Fix a crash when spellchecking when a Math inset is the last inset in the document. Make sure that the words between a math inset and the next inset are spellchecked. Also fix the count of the number of words when there are math insets.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32489 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-12 02:56:06 +00:00
Richard Heck
69666056ca Cosmetic repairs to my updateLabels() changes, thanks to Andre's
comments. Added comments per Pavel's suggestion.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32453 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-10 13:25:31 +00:00
Jean-Marc Lasgouttes
52061b8313 Speedup updateMacroInstances. This has some effect on document loading time:
it was a significant part of this time


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32435 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-08 22:41:10 +00:00
Jürgen Spitzmüller
123a589bf8 * Fix bug #2144: Merge the two identical classes g-brief-de and g-brief-en into one class g-brief.
The German layouts are replaced by the English ones.
German localization is now done as it is supposed to be: via gettext.

A file format change was needed to do this.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32406 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-07 11:53:25 +00:00
Richard Heck
025138f30c Minor XHTML fix.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32378 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-06 22:53:47 +00:00
Richard Heck
996505c2ae This patch introduces an optional argument to Buffer::updateLabels(), so
as to allow us to call the routine when we are preparing for output and
so to do certain things we might not want to do every time. 

This is an abuse of updateLabels(), in a way, but updateLabels() long
ago became the general recurse-through-the-Buffer routine, and to
implement the sort of thing I want to do here in validate(), say, much
of the code in updateLabels()---in particular, the counter-update
code---would have to be duplicated. So I believe this is the best, and
easiest, way to go.

Actual use of the new argument will follow.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32318 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-04 03:03:38 +00:00
Richard Heck
82cb512ebb Typo.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32311 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-03 23:30:26 +00:00
Richard Heck
e70c04b350 CSS for InsetBibtex. We include this via the validate mechanism, and
borrow the LatexFeatures::addPremableSnippet() method to do it.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32301 a592a061-630c-0410-9148-cb99ea01b6c8
2009-12-03 21:06:41 +00:00
Jürgen Spitzmüller
df329341aa * Add support for per-document fontenc setting (bug 5730)
File format change.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32228 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-29 14:43:00 +00:00
Richard Heck
27ed87b8f9 I think it's sufficient to export once. Fixes 6307.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32131 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-21 22:24:47 +00:00
Richard Heck
7aebcc787f I am now going to proceed to break XHMTL output, and then reconstruct it
a piece at a time, using the new XHTMLStream.

This just gets the basic structures working, and fixes a bunch of iconv
errors in the process. 

I hate iconv errors.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32085 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-19 17:51:06 +00:00
Jean-Marc Lasgouttes
3f22ae8f1d revert previous fix for Snow Leopard crashes and apply new one
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32067 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-17 17:04:47 +00:00
Richard Heck
70f035b189 This can be a private method.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32000 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-15 01:42:49 +00:00
Richard Heck
487053deb8 We need truly XHTML output to get MathML to display in Firefox, etc.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31982 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-14 16:21:21 +00:00
Richard Heck
7814909d3b Add TEXT flavor, just in case we need it.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31973 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-14 12:54:12 +00:00
Richard Heck
b56faec8f4 Change the order of these backends.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31952 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-11 23:50:54 +00:00
Uwe Stöhr
d5099c8605 - introduce option to suppress the LaTeX package mhchem, fileformat change
The fileformat change is also needed because of our mistake that we load mhchem since LyX 1.6.4 automatically so that files created with LyX 1.6.4 won't compile under LyX 1.6.3. Now at least all files created or opened with LyX 1.7 can be reverted to the fileformat of LyX 1.6.x and can therefore be read by all LyX 1.6.x versions.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31941 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-11 01:48:07 +00:00
Richard Heck
a79722b1c0 Const.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31913 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-09 03:00:19 +00:00
Enrico Forestieri
f83a6cc3af Don't use updateMacros() in the math parser, in order to avoid
performance problems when loading documents with lots of macros.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31907 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-08 18:47:33 +00:00
Abdelrazak Younes
82c7e15e64 Uniformize Inset construction (passing Buffer * everywhere). Lots of cleanup to do still...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31901 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-08 15:53:21 +00:00
Abdelrazak Younes
ff4460603e Make Buffer argument mandatory in most of the InsetMath based class... boring work...
Math manual loads and save correctly it seems but expect some instability period.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31898 a592a061-630c-0410-9148-cb99ea01b6c8
2009-11-08 11:45:46 +00:00
Vincent van Ravesteijn
25e5dfe330 Do not issue the warning introduced in r31809 if we are setting the parent for the first time, or we are removing the parent.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31810 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-30 15:33:54 +00:00
Vincent van Ravesteijn
0379518340 Issue a warning if a document has two parents. We should do something smart then, but what?
- Do we want to ask the user which of the parents he would like to be the document's parent ?
- Do we want to disable any functionality related to parents ? Like references, bibliography, document outline etc.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31809 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-30 15:24:35 +00:00
Vincent van Ravesteijn
d156d11738 Fix part of bug #6251: When closing a buffer, only close the direct children. All grandchildren will be closed recursively by the children _and_ before it will be close by the grandparent.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31797 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-29 23:28:08 +00:00
Vincent van Ravesteijn
5d9fdda299 Move the call to LFUN_SET_COLOR from the handling of LFUN_BRANCH_ADD_INSERT to LFUN_BRANCH_ADD. Now, the sequence "branch-add A" + "branch-insert A" doesn't result in an undefined branch Inset in the document.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31792 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-29 22:06:27 +00:00
Vincent van Ravesteijn
ed98a0000d Remove const modifier from the correct function.
see r31737.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31738 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-25 14:00:29 +00:00
Vincent van Ravesteijn
bdf69de113 Don't set the read-only flags of the documents. The GuiCompare is modal anyway, so the user shouldn't be able to change something.
This reverts part of r31736.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31737 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-25 13:56:44 +00:00
Vincent van Ravesteijn
7227566e86 Call the Compare thread from the GuiCompare dialog.
Furthermore:
- increase safety, 
- improve error handling,
- minor cleanups,
- set documents to read-only while running the thread.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31736 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-25 13:41:46 +00:00
Richard Heck
14bb003b7e Add an HTML output flavor, and do something with it.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31719 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-25 01:48:14 +00:00
Pavel Sanda
8962886acb String formatting
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg155067.html


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31656 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-18 03:58:20 +00:00
Pavel Sanda
da55181c33 More info into emergency dialog. This is especially useful in case
more master/child emergency files were detected.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31642 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-15 21:37:09 +00:00
Abdelrazak Younes
d38ca04ff7 Move Undo::beginUndoGroup() and Undo::endUndoGroup() calls to where they are used and necessary, hopefully.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31492 a592a061-630c-0410-9148-cb99ea01b6c8
2009-10-03 19:12:21 +00:00
Abdelrazak Younes
898dbc2699 Fix gcc compile bug... weird...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31401 a592a061-630c-0410-9148-cb99ea01b6c8
2009-09-19 14:42:07 +00:00
Abdelrazak Younes
1be79d02e5 Move LFUN_BUFFER_LANGUAGE to Buffer and enables it only when the document is not read-only.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31399 a592a061-630c-0410-9148-cb99ea01b6c8
2009-09-19 14:20:05 +00:00
Abdelrazak Younes
93998bb239 * Move Buffer specific LFUNs to Buffer::dispatch() and Buffer::getStatus().
There is a FIXME in there that says that if some LFUN need to be dispatched even if the Buffer is internal then we should add some code. But I couldn't find any for now.
* Move LFUN_BUFFER_IMPORT status to GuiView where it belongs.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31398 a592a061-630c-0410-9148-cb99ea01b6c8
2009-09-19 14:05:52 +00:00
Abdelrazak Younes
226ebea2bf Transfer LFUN_BUFFER_TOGGLE_READ_ONLY to Buffer.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31397 a592a061-630c-0410-9148-cb99ea01b6c8
2009-09-19 11:59:39 +00:00
Vincent van Ravesteijn
b53b9b9941 buffer_pimpl.C doesn't even exist.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31357 a592a061-630c-0410-9148-cb99ea01b6c8
2009-09-09 05:03:38 +00:00
Tommaso Cucinotta
f3b3f62d5b Added isInternal() method, mapped temporarily on check about ".internal" filename extension (minimum impact on current code).
Replaced various replica of such check with the invocation of the new method.
TocBackend now does not call addToToc() for internal buffers.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31340 a592a061-630c-0410-9148-cb99ea01b6c8
2009-09-08 01:29:07 +00:00
Richard Heck
74cd0fab48 Better message.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31279 a592a061-630c-0410-9148-cb99ea01b6c8
2009-09-04 13:53:12 +00:00
Vincent van Ravesteijn
c863a953b2 Now we have disentangled writeSession() and closeWorkAreaAll(), we can release child buffers together with the master.
This basically solves bug #6162 in trunk (this cannot be done in branch until we take measures to prevent dataloss when closing a master and dirty children).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31149 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-19 20:31:49 +00:00
Vincent van Ravesteijn
81403e78fc If we are in a close_event all children will be closed in some time, so no need to do it here. This will ensure that the children end up in the session file in the correct order. If we close the master buffer, we can close or release the child buffers here too.
We don't want a master buffer to release all its children immediately because that would close dirty childs without saving and would make it impossible to store the childs in a proper way in the session file. 

As, we close all children of a buffer together with the master itself, it is also no longer necessary to do it automatically. 

I'll leave it commented out for a while in case someone objects to it.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31130 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-18 21:18:21 +00:00
Jürgen Spitzmüller
bb3ac8a865 * Buffer.cpp: fix the fix (r31082): only add a default index if we do not have one.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31086 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-17 08:28:57 +00:00
Jürgen Spitzmüller
06cf68b542 * Buffer.cpp (readHeader): restore the default index after cleaning up.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31082 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-17 07:34:01 +00:00
Vincent van Ravesteijn
67c59b8f49 Fix a bunch of assertions.
The first thing that bformat does is to check whether the string contains "%1$s". Otherwise it asserts.

Why didn't we see this happen before ? This was revealed by the emergency saves that Richard introduced in the Buffer dtor.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31062 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-15 20:47:46 +00:00
Richard Heck
8adc7197fb As discussed on the list: Check for dirty Buffer when destroyed.
Write emergency file if necessary.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31057 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-15 16:39:36 +00:00
Richard Heck
c5487a3682 Move emergencyWrite() from BufferList to Buffer.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31056 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-15 16:34:54 +00:00
Uwe Stöhr
33eec90086 new document option to suppress the default date, fileformat change, fixes #5823
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31028 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-14 00:52:33 +00:00
Pavel Sanda
06bc0ad306 Fix bug #2120 - Emergency saves removal.
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg143251.html
http://marc.info/?l=lyx-devel&m=124938609111483&w=2


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30976 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-11 08:20:43 +00:00
Abdelrazak Younes
8c053ea10c Move depthHook(), outerHook(), isFirstInSequence(), outerFont() to Text methods.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30957 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-09 18:35:39 +00:00
Abdelrazak Younes
2b9e44cb01 Move contents of paragraph_funcs.* to Text.h and Text.cpp.
The goal is to simplify the code afterwards.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30955 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-09 17:30:41 +00:00
Abdelrazak Younes
4916bd41d3 Get rid of Buffer::insertStringAsLines().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30948 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-09 16:37:30 +00:00
Abdelrazak Younes
5425c53fd1 Now that Text knows its owner, use the associated Buffer access.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30941 a592a061-630c-0410-9148-cb99ea01b6c8
2009-08-09 15:29:34 +00:00
Vincent van Ravesteijn
966687d98b Fix bug #6058: Change tracking not usable in version control.
This patch makes sure that there are minimal changes when loading and saving a file with change tracking.

- the authors are assigned a buffer_id, such that when the file is saved, they get the same id,
- the authorlist is sorted according to the buffer_id,
- the buffer_id is written to the file in the author list (file format change)
- the ids start with 1, because 0 is internally reserved for the current Author,
- when writing the file, the current author is assigned an id if he didn't already have it.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30756 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-23 20:08:05 +00:00
Uwe Stöhr
0b33b9d090 allow to use glue lengths in the HSpace dialog; file format change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30724 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-21 11:51:43 +00:00
Uwe Stöhr
efd4f71fbd allow the usage of relative lengths in the HSpace and the VSpace dialog; file format change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30710 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-20 11:22:51 +00:00
Uwe Stöhr
6b970c0339 GuiDocument.cpp: allow to use percent lengths for the paragraph skip separation; file format change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30696 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-19 22:08:58 +00:00
Uwe Stöhr
53e7a92494 support to specify the paragraph indentation in the document settings dialog; introduces the new class HSpace; - file format change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30694 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-19 21:13:27 +00:00
Vincent van Ravesteijn
fc5e189c52 * Buffer.cpp: whitespace.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30632 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-16 18:29:16 +00:00
Jürgen Spitzmüller
e6f922009f * Add possibility to append active branch names to the output file name (#3105).
File format change.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30546 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-13 14:30:08 +00:00
Jean-Marc Lasgouttes
95e983c382 Remove Layout::labelstring_appendix method; add a bool parameter to Layout::labelstring instead.
Fix the rest of the code, whih implies fixing a few potential bugs where the appendix status was not taken in account.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30524 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-12 21:48:50 +00:00
Jean-Marc Lasgouttes
e9d19b82d4 Make sure that the new caching mechanism for flattened labels respects languages.
* Counters.cpp (flatLabelString): return a cache of the flattened strings for each used language
 * Counters.cpp (theCounter, counterLabel, flattenLabelString): add a lang parameter; in theCounter, populate the cache as needed.

 * insets/InsetCaption.cpp:
 * insets/InsetFoot.cpp:
 * insets/InsetBibitem.cpp:
 * insets/InsetCollapsable.cpp:
 * Paragraph.cpp:
 * Buffer.cpp: pass a language argument to counter methods.

 * Paragraph.cpp (translateIfPossible): use the function with same name in gettext.cpp.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30520 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-12 20:09:53 +00:00
Jean-Marc Lasgouttes
c355edfb6d revert r30515: too many files there
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30516 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-12 17:30:56 +00:00
Jean-Marc Lasgouttes
834bfe5e21 fix a couple warnings after the number localization patch
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30515 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-12 17:28:46 +00:00
Uwe Stöhr
424943af89 - support for longtable alignment, fileformat change
- GUI support for table alignment

(all comments to the polished layout of the table dialog welcome)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30477 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-11 13:09:45 +00:00
Jürgen Spitzmüller
c650dcd540 * Buffer.cpp:
- rewrite getUsedBranches() with an InsetIterator approach.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30465 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-11 08:29:30 +00:00
Jürgen Spitzmüller
808dfaabea * Buffer.{cpp,h}:
- rewrite LFUN_BRANCHES_RENAME with an InsetIterator approach.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30464 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-11 08:18:26 +00:00
Jürgen Spitzmüller
ca070ea260 * Buffer.cpp: squash compiler warning.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30463 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-11 06:50:18 +00:00
Jürgen Spitzmüller
cfdda3ad08 * Buffer.cpp (renameBranches): record undo.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30459 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-11 05:08:44 +00:00
Jürgen Spitzmüller
5fdd2daa9c * Add ability to rename branches (bug 4128).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30442 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-10 06:49:51 +00:00
Jürgen Spitzmüller
17986e7509 Ease the pain with unknown branches:
* on paste, ask if unknown branches shall be added to the branch list
	  (entails new LFUN_BRANCH_ADD)
	* add a list of undefined branches to the buffer and the GUI

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30419 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-09 09:48:34 +00:00
Abdelrazak Younes
b8c470d55f Spellchecker Bug fix: found word was not filled in.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30351 a592a061-630c-0410-9148-cb99ea01b6c8
2009-07-04 18:00:01 +00:00
Abdelrazak Younes
5e01b2dfa1 Buffer::Spellcheck(): Fix infinite loop when a math inset is met... stupid me!
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30231 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-22 21:43:39 +00:00
Abdelrazak Younes
5b2ba34ac6 Buffer::spellCheck(): don't spellcheck math.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30227 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-22 21:00:48 +00:00
Abdelrazak Younes
c75fb1f6e0 First fix the spellchecker. Now, it find the next misspellec word.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30223 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-22 17:30:57 +00:00
Abdelrazak Younes
694399b16c Simplify Buffer::spellCheck() by using Paragraph::spellCheck().
Paragrah::isMisspelled() is split in two.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30222 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-22 16:38:11 +00:00
Abdelrazak Younes
f4f5178d4f Revert previous to this file, stupid copy&paste bug fix, sorry.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30212 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-21 14:33:13 +00:00
Abdelrazak Younes
5387379c24 Introduce Paragraph::isWordSeparator() and use it instead of Paragraph::isLetter(). Note here a change in behavior WRT to word selection: a deleted character is not considered a word separator. This new behavior will impact word finding and spellchecking.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30211 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-21 14:30:57 +00:00
Jürgen Spitzmüller
5a54d11157 * Pop up error dialog if issuing master-buffer-[view|update] and errors occured.
Navigating in such dialogs does not work yet, but at least the user is informed
  at all that LaTeX wasn't succesful.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30209 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-21 12:26:41 +00:00
Jürgen Spitzmüller
9388e76dc0 * Buffer.cpp:
- make LaTeX logfile dialog work for child documents and master-buffer-[view|update]:
	  if there's only a master file log or if the master file log is newer, it is displayed.
* Buffer.h: typo.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30206 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-21 09:44:10 +00:00
Jean-Marc Lasgouttes
889fdbd39b get rid of the \use_alt_language pref, which was not used. Instead, we test whether \alt_language is empty
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30159 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-18 15:31:43 +00:00
Jürgen Spitzmüller
bd4c74b3b7 * add support for the applemac encoding. File format change.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30064 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-12 08:47:38 +00:00
Richard Heck
70899f0c15 Separate HTML preamble information. This could be used for javascript,
or anything else one would like to add to the header.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29967 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-05 19:42:56 +00:00
Richard Heck
397ebabfa4 Rename a couple routines in preparation for more.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29966 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-05 19:30:42 +00:00
Richard Heck
92a69bb790 Basic output routines for HTML.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29950 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-05 17:44:35 +00:00
Richard Heck
f28c1a2cce Allow customization of enumerate counters.
This patch is from JMarc, except the docs, which are due to me.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29906 a592a061-630c-0410-9148-cb99ea01b6c8
2009-06-02 16:02:29 +00:00
Jean-Marc Lasgouttes
864773d7d9 Allow literate documents other than noweb to work out of the box. Currently
only sweave is supported (for building documentation, not programs).

Layout files allow a new OutputFormat tag 

Modules can be conditionned on a feature of the type from->to, indicating that
it should be possible to convert from format 'from' to format 'to'.

Layout format incremented to 15.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29874 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-28 08:59:25 +00:00
Jürgen Spitzmüller
1d494512fc empty file format change due to r29840.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29841 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-25 08:27:12 +00:00
Jürgen Spitzmüller
322eb96219 * Allow manual setting of bibliography indendation
that overrides bibitemWidest (bug 5960).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29840 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-25 08:13:56 +00:00
Enrico Forestieri
00a62b7c0a Fix reverse search when the View Source window is active.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29834 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-24 01:38:33 +00:00
Jürgen Spitzmüller
e9cbe2f80f A GUI for nomencl settings. Adds the possibility to enter a custom length.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29779 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-22 16:26:15 +00:00
Jürgen Spitzmüller
18cfe15b64 file format change due to r29770.
No automatic width calculation is done for old documents, because these might rely on settings in
nomencl.cfg.

A GUI to alter this is needed.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29775 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-22 08:31:43 +00:00
Jürgen Spitzmüller
7ba2bfb81d * Per-document setting for bibtex and makeindex.
File format change.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29774 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-22 07:20:00 +00:00
Pavel Sanda
8e15c27a9c Next attack on the background color. Thanks Juergen.
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg151267.html


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29723 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-18 10:53:02 +00:00
Pavel Sanda
0920fd7b5e Introduce new format as a safety measure
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg150868.html
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg150895.html



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29552 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-06 16:58:15 +00:00
Pavel Sanda
6fde8f8067 Introduce double underline and wavy underline styles from ulem
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg150803.html


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29542 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-05 09:26:28 +00:00
Pavel Sanda
381b86788d Introduce strikeout text style (strike-through)
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg150743.html

Somewhat related to http://www.lyx.org/trac/ticket/4248 .


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29523 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-03 22:45:14 +00:00
Vincent van Ravesteijn
af39d35545 Adjust the location of the autosave file for unnamed docs.
If the document is unnamed try to save in the backup dir, else in the default document path, and as a last try in the filePath, which will most often be the temporary directory.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29508 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-03 10:24:12 +00:00
Vincent van Ravesteijn
aa4c7e7ef5 Fix bug #5879 (try 2): Move the autosave file of a buffer when the filename changes.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29507 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-03 10:21:21 +00:00
Vincent van Ravesteijn
11ecc24c0c Revert r29505. We forgot that we cannot retrieve the new autosavefile yet, because the buffer might still be marked as unnamed. So, we should first finish this administration, before we can get the location of the new autosave filename.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29506 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-03 10:16:49 +00:00
Vincent van Ravesteijn
dce037ed5a Fix bug #5879: Move the autosave file of a buffer when the filename changes (patch by Richard).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29505 a592a061-630c-0410-9148-cb99ea01b6c8
2009-05-03 09:09:33 +00:00
Jürgen Spitzmüller
dd930b4535 * final splitindex feature addition: support for \printindex* and \printsubindex*
File format change.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29419 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-27 06:10:25 +00:00
Jürgen Spitzmüller
0bd5c5fca8 * Add support for splitindex's \printsubindex command. File format change.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29409 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-26 11:24:38 +00:00
Jean-Marc Lasgouttes
26b1c55e03 whitespace only
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29393 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-24 12:37:56 +00:00
Jürgen Spitzmüller
c52bd08442 Introduce splitindex support. File format change.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29255 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-16 07:29:01 +00:00
Uwe Stöhr
4d30bc7579 support for \pagecolor, fileformat change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29220 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-11 21:40:11 +00:00
Jürgen Spitzmüller
60d2b3295a * new per-document default output format. File format change.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29181 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-10 11:06:53 +00:00
Uwe Stöhr
305ac4e923 Buffer.cpp: fix due to compiler warning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29170 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-09 22:58:51 +00:00
Jürgen Spitzmüller
cb0bfc9445 * Buffer.cpp (getDefaultOutputFormat):
- prevent crash if no formats are found (and return an empty string).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29141 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-07 11:54:02 +00:00
Jürgen Spitzmüller
25a14730ed * First step towards default view format.
The icons could be replaced by something nicer.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29134 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-07 05:01:08 +00:00
Richard Heck
4daf7b5dfc The Buffer::dispatch() patch.
This patch enhances the Buffer::dispatch() method to make it a full-fledged
member of the dispatch sequence. The most immediate payoff is that LFUNs that
are handled in Buffer::dispatch() can be used from the command line.

We make better use of the DispatchResult object and return error information 
through it, rather than using return values. (This was JMarc's suggestion.) We 
also introduce a  corresponding Buffer::getStatus() method, and modify 
BufferView::getStatus() to return a flag indicating whether a decision has been 
made, as is already done in some other cases.

Finally, some LFUNs are moved to Buffer::dispatch(), including LFUN_BUFFER_PRINT.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29125 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-06 12:12:06 +00:00
Jürgen Spitzmüller
737e9b2c20 start XeTeX support.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29119 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-06 06:58:30 +00:00
Abdelrazak Younes
193074b384 Spellchecker: More simplifications.
This change makes it possible (at long last!) to go to the work area, do some edition and then come back to the SpellChecker. We probably need a [Continue] button.

* Buffer::nextWord(): go back a bit to return the current word.

* SpellChecker and Dialog: get rid of the complicated, useless exitEarly() handling.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29092 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 17:25:14 +00:00
Abdelrazak Younes
a4169da139 More SpellChecker cleanups.
* Buffer::spellCheck() new method constructed from mutiple bits of GuiSpellchecker.cpp.

* GuiSpellchecker: lots of simplifications.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29090 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 16:40:47 +00:00
Richard Heck
876dc0d54e Fix up a few little things after r29065. If we're calculating the autosave
filename in a different way, we need to make sure we always do it the same
way. Makes more sense to do this in Buffer anyway.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29073 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 03:13:46 +00:00
Vincent van Ravesteijn
4ec167330f Store the autosave file in the default document path as long as the document is 'unnamed'.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29065 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-03 20:07:43 +00:00
Richard Heck
46c5596462 Add a comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29056 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-03 16:04:45 +00:00
Jürgen Spitzmüller
49fdaa8507 Buffer.cpp:
- re-assign a master's children if a child was reloaded (bug 5873)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29046 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-03 11:07:53 +00:00
Richard Heck
c8d03a4d81 Fix bug 5859.
http://www.lyx.org/trac/ticket/5859



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29037 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-03 00:44:33 +00:00
Jean-Marc Lasgouttes
6c422712e1 Extend the branch-(de)activate functions to work without a parameter. In
this case, when the cursor is on a branch inset (using the AtPoint mechanism)
the branch to which the branch inset belongs will be (de)activated.

This functionality can now be used through the branch inset context menu



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28987 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-31 09:38:07 +00:00
Abdelrazak Younes
966ea2752e Buffer::nextWord(): simplify a bit.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28964 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-28 19:08:38 +00:00
Abdelrazak Younes
1ec0b390f5 Transfer some general code from GuiSpellchecker to Buffer and DocIterator.
* Buffer::nextWord(): new method to search for next word.
* DocIterator.cpp: new function isLetter() moved from GuiSpellchecker.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28963 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-28 19:02:49 +00:00
Vincent van Ravesteijn
74741ca5b9 Some cleanup in InsetInclude:
* use the UpdateScope, introduced recently, to prevent the 'strange' calls to setParent which also causes the update mechanism to run,
* remove the buffer parameter of loadIfNeeded and all function,
* remove doubled code from getChildBuffer.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28919 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-26 00:48:32 +00:00
Richard Heck
d1c255d99d Whitespace (and a commit check).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28894 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-25 12:14:24 +00:00
Richard Heck
af68d27725 Cosmetics.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28882 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-20 19:36:37 +00:00
Richard Heck
22ba8256b2 So we do, sometimes, need the setBuffer calls that were removed in r28720.
This patch encapsulates the needed call in Buffer::setBuffersForInsets(),
and calls it from Undo::Private::textUndoOrRedo(). As noted in the FIXME,
this is still a bit of a "hammer" and ought to be replaced with the sort of
more refined approach taken in r28709. But I don't at the moment see how to
do that. The place to do it, though, is in doTextUndoOrRed().
 


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28757 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-12 20:10:46 +00:00
Richard Heck
3aecc2c4ff Use an enum to make things a little clearer here.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28756 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-12 20:02:12 +00:00
Richard Heck
80c7326663 Remove setBuffer() calls that are no longer needed.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28720 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-07 21:09:41 +00:00
Jürgen Spitzmüller
d7601a684b fix bug 5833
* Buffer.{cpp, h}:
	- new method getChildren() that returns included (and sub-included) files

* GuiView.cpp (closeEvent):
	- do not just close dirty child documents.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28712 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-07 16:33:03 +00:00
Vincent van Ravesteijn
0aca981637 Fix bug 5699 (crash when using outliner in child document while the master is not opened).
The problem was that, if the master is not opened, no respective guiDelegate exists, and the functions that update the toc do not trigger. The fix is to update the child's toc backend and toc items directly in such cases. 


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28551 a592a061-630c-0410-9148-cb99ea01b6c8
2009-02-19 00:29:04 +00:00
Vincent van Ravesteijn
fe980636db Compile fix for r28492.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28493 a592a061-630c-0410-9148-cb99ea01b6c8
2009-02-14 16:57:52 +00:00
Vincent van Ravesteijn
d1074d1dbc Fix a crash on exit when the child documents are already unloaded.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28492 a592a061-630c-0410-9148-cb99ea01b6c8
2009-02-14 16:49:28 +00:00
Jürgen Spitzmüller
37d89378ca * Buffer.cpp:
- avoid wrong console message while loading a child from a master
	  that lead me on the wrong track when debugging bug 5699.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28491 a592a061-630c-0410-9148-cb99ea01b6c8
2009-02-14 14:21:59 +00:00
Richard Heck
ee36483a8e Let's have a little more info.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28448 a592a061-630c-0410-9148-cb99ea01b6c8
2009-02-11 17:08:51 +00:00
Jean-Marc Lasgouttes
9622577c60 fix faulty documentation
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28344 a592a061-630c-0410-9148-cb99ea01b6c8
2009-02-04 09:52:10 +00:00
Uwe Stöhr
b742ff6406 support for the LaTeX commands \*phantom, fileformat change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28292 a592a061-630c-0410-9148-cb99ea01b6c8
2009-01-30 00:56:37 +00:00
Jürgen Spitzmüller
743a29799b * use ulem instead of soul for change tracking
(fixes bugs 5091, 5480, 5647).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28114 a592a061-630c-0410-9148-cb99ea01b6c8
2009-01-12 08:01:28 +00:00
Jürgen Spitzmüller
2a4a108e60 * Buffer.cpp:
- prevent potential null pointer.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28023 a592a061-630c-0410-9148-cb99ea01b6c8
2009-01-07 11:07:48 +00:00
Jürgen Spitzmüller
bd934ddf3e * Buffer.cpp:
- do not set master_file as master buffer if the document s no real child (bug 5653).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28020 a592a061-630c-0410-9148-cb99ea01b6c8
2009-01-07 07:53:28 +00:00
Vincent van Ravesteijn
dd64c572c2 Allow users to specify toolbar icons for commands with a backslash. This is in the same style as the replacements made for math-insert commands.
See the user's list:
http://thread.gmane.org/gmane.editors.lyx.general/52712

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27979 a592a061-630c-0410-9148-cb99ea01b6c8
2009-01-03 18:33:09 +00:00
Jürgen Spitzmüller
f4b8f4528f * src/buffer_funcs.{cpp,h}:
- add optional bool "acceptDirty" to checkAndLoadLyXFiles. 
	   If true, the method doesn't care for buffer dirtiness
* src/Buffer.cpp:
	- when checking for master buffer, do not care if it's dirty
	  (fix bug 5514)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27774 a592a061-630c-0410-9148-cb99ea01b6c8
2008-12-05 15:49:07 +00:00
Jürgen Spitzmüller
1a24671e1c * Buffer.cpp (readFile):
- set params().compressed (bug 5589).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27768 a592a061-630c-0410-9148-cb99ea01b6c8
2008-12-04 09:14:17 +00:00
Jürgen Spitzmüller
9b39fbf557 Add support for Swiss German (bug 5450). File format change.
Babel doesn't support this variant (yet), so we use ngerman. However, for spell checking and thesaurus, this makes
a difference.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27725 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-28 13:44:03 +00:00
Richard Heck
aeb997e3f0 Make getChildBuffer() and loadIfNeeded() methods rather than standalone
functions. Preparatory to another patch.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27687 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-24 12:40:53 +00:00
Richard Heck
0ad3996fd3 Remove obsolete comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27636 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-19 04:28:03 +00:00
André Pönitz
6192345f60 add Buffer * member to DocIterator
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27603 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-17 11:46:07 +00:00
Stefan Schimanski
412f520892 * "Goto label" in reference dialog works with master and child documents
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27590 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-16 21:28:06 +00:00
André Pönitz
32a53f8d6a move more stuff from buffer_func to Buffer
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27565 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-16 17:49:00 +00:00