Commit Graph

15324 Commits

Author SHA1 Message Date
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
14845fcaec * XeTeX can be launched via the toolbar now
* non-functional view formats are now disabled in the toolbar

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29123 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-06 09:27:05 +00:00
Enrico Forestieri
56210f5a39 Don't wrap characters marked as mathalpha in the unicodesymbols file.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29121 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-06 09:04:00 +00:00
Jürgen Spitzmüller
ca6d526ba1 * BufferParams.cpp:
- move loading of the xetex packages xunicode and xltxtra
	  to the end of the preamble

Now the UserGuide compiles with XeTeX!

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29120 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-06 08:10:50 +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
Enrico Forestieri
ed6f569fc8 Don't create nested text-in-math environments.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29118 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 23:34:22 +00:00
Vincent van Ravesteijn
326a035a5b Fix bug #2213 (part 5): GuiChanges lacks "Previous Change" button.
Make sure we jump to the next or previous change when we switch search direction. Without this patch, the same Change will be found and only the cursor is moved from the end (or begin) to the begin (or end) of the selection.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29115 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 20:16:32 +00:00
Uwe Stöhr
a97b097768 major code cleanup for fractions:
- InsetMathFrac.cpp/h:
    - InsetCFrac, InsetDFrac, and InsetTFrac are now included as kind of InsetMathFrac
    - InsetDBinom and InsetTBinum are now included as kind of InsetMathBinom
    - support for the optional argument of \cfrac (cursor position still needs to be fixed, see post in mailing list)

- stdtoolbars.inc:
    - add entries for \cfrac
    - remove entry for \atop since atop is outdated and only in LaTeX2e for compatibility reasons (according to the LaTeX companion, you get warnings from amsmath in the LaTeX log when using atop)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29114 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 19:52:53 +00:00
Vincent van Ravesteijn
58b87df638 Fix bug #2213 (part 4): GuiChanges lacks "Previous Change" button.
Also show the Merge dialog when we are behind the last change.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29111 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 19:26:26 +00:00
Vincent van Ravesteijn
bb5b02a362 Fix bug #2213 (part 3): GuiChanges lacks "Previous Change" button.
Add Button to GuiChanges.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29110 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 19:15:52 +00:00
Vincent van Ravesteijn
03671821d3 Fix bug #2213 (part 1): GuiChanges lacks "Previous Change" button.
Add LFUN_CHANGE_PREVIOUS.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29109 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 19:14:37 +00:00
Vincent van Ravesteijn
5a1dc72483 Fix bug #2213 (part 1): GuiChanges lacks "Previous Change" button.
*lyxfind: Add findPreviousChange().

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29108 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 19:11:25 +00:00
Enrico Forestieri
8f52d3b7db The \text macro does not require the full AMS package. Also load amstext
when a text-in-math environment is used, such that super and subscripts
are typeset in the correct size.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29098 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 02:11:07 +00:00
Enrico Forestieri
67cbe895fe No need to call t.character() as the char is already available in c.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29097 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 01:49:25 +00:00
Enrico Forestieri
376f3f08bd Unicode symbols entered or pasted in math are wrapped in \text{} by default.
Unwrapped symbols can be obtained either by dissolving the text inset or by
verbatim paste (Ctrl+Shift+V). In such a case, the symbols are wrapped in
\lyxmathsym when exporting to latex, as usual.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29096 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-05 01:14:10 +00:00
Richard Heck
bd8a0686fb Fix the year display in InsetCitation.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29095 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 21:10:35 +00:00
Richard Heck
f7164212b1 Simplify.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29094 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 21:04:26 +00:00
Richard Heck
920bfedf1f Manage the initial setting of Default or Plain Layout more simply.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29093 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 19:34:14 +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
64c3229bd7 Hum...
Copy&paste bug fix.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29091 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 16:55:13 +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
1352592874 Fix assertion in trunk, and add a comment about why this needs to
be done twice.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29085 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 13:48:30 +00:00
Uwe Stöhr
a9c466ae2f InsetMathFrac.h: forgot to add my name in r28639
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29082 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 11:33:13 +00:00
Vincent van Ravesteijn
12ba68f6ef * LyXAction.cpp: Document the optional parameter of LFUN_BUFFER_ZOOM_IN/OUT.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29081 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 10:26:51 +00:00
Pavel Sanda
6eddca5440 Compilation fix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29080 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 10:15:06 +00:00
Pavel Sanda
9420fbedf4 Revert unintended commit
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29078 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 09:31:34 +00:00
Vincent van Ravesteijn
6b5ce8a999 Fix bug #3038: wish for lfuns for zoom-in and zoom-out
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29077 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 09:14:38 +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
Richard Heck
dd8a3f6f83 Fix comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29072 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 03:10:54 +00:00
Richard Heck
292b27e74b Routine no longer exists.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29071 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-04 03:10:38 +00:00
Vincent van Ravesteijn
e207b0250f Make sure that the document is only scrolled to the cursor when the cursor is/was visible before resizing .
Resizing can occur by toggling toolbars (bug 4733), or by creating or closing buffers which causes the tabbar to toggle (e.g. bug 4174, comment 5).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29066 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-03 21:39:06 +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
Pavel Sanda
5806be1528 Fix bug http://www.lyx.org/trac/ticket/5812
(Icons replacement broken)

Patch from Martin Engbers.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29057 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-03 17:00:09 +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
Vincent van Ravesteijn
e90b43444a Fix bug 4067: Incorrect indentation in Description environment
http://www.lyx.org/trac/ticket/4067

If we are in the first pos, we are never in the body and always in the label.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29033 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-02 21:36:30 +00:00
Richard Heck
404f1dc80a Whoops. I somehow undid the reordering with that last commit. Anyway,
this fixes that again.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29020 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-02 18:59:25 +00:00
Richard Heck
62beaaa37f There are too many things here named `table'.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29019 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-02 18:57:19 +00:00
Richard Heck
ab0d757bed Just re-ordering stuff.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29018 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-02 18:51:38 +00:00
Richard Heck
275c9cde02 Fix crash when hitting delete key once more after deleting
all the keystrokes associated with an LFUN in the shortcut
dialog.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29017 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-02 18:19:33 +00:00
Richard Heck
be0991288a Now these don't have to be public.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29016 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-02 15:56:12 +00:00
Richard Heck
9098af80aa Clean up a bit.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29015 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-02 15:53:23 +00:00
Vincent van Ravesteijn
cdaefbf484 GuiViewsource:
* Revert cs 28992 and do something better to fix the bug that the view source window remains disabled forever when autoUpdate is not checked and the view source window gets disabled or LyX is closed.
* Update the source window, when autoUpdate checkbox is toggled.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28999 a592a061-630c-0410-9148-cb99ea01b6c8
2009-04-01 20:32:26 +00:00
Vincent van Ravesteijn
14d0e66eae Fix bug that the view source window remains disabled forever when autoUpdate is not checked and the view source window gets disabled or LyX is closed.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28992 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-31 15:29:51 +00:00
Jean-Marc Lasgouttes
67bafed7bb Mark status of branches in the Button. This uses two dingbat symbols (check
and cross). I'll revert if people do not like it (otherwise it is candidate
for branch).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28988 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-31 10:31:28 +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
Enrico Forestieri
d786fa0ab8 Partly revert r28731 (see discussion in bug 5836).
Essentially, it is not true that Cyrillic characters in math are to be typeset
in italic by default, and LyX already permits to style them as desired. 


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28981 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-30 22:40:27 +00:00
Jean-Marc Lasgouttes
30afece93d Kill next-inset-toggle and expand inset-toggle to provide the same functionality
* src/LyXAction.h: introduce new function attribute AtPoint: this is 
	for lfuns that should first look at cursor postion whether there
	is an inset, before dispatching to container inset.
	* src/LyXAction.cpp: remove LFUN_NEXT_INSET_TOGGLE; 
	mark LFUN_INSET_TOGGLE as AtPoint.
	* src/BufferView.cpp (dispatch, getStatus): remove handling of
	LFUN_NEXT_INSET_TOGGLE.
	* src/LyXFunc.cpp (dispatch, getStatus): handle functions marked 
	AtPoint.	
	* lib/*/*: replace next-inset-toggle with inset-toggle.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28980 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-30 13:49:52 +00:00
Jean-Marc Lasgouttes
827c72e1f5 Simplify and fix the TOGGLE_INSET code for branch inset. If it turns out
that the extra complexity was intended, I would be interested to know
what the idea was.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28979 a592a061-630c-0410-9148-cb99ea01b6c8
2009-03-30 12:45:33 +00:00