Commit Graph

16 Commits

Author SHA1 Message Date
Richard Heck
3b0bfc4c52 Fix bug noted by Uwe.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20948 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 17:34:49 +00:00
Richard Heck
0787ade6c0 This is the first part of a cleanup of how we handle the InsetCommand hierarchy. This part starts to disentangle the type of the inset from the command that a single instance of the inset represents. This involves two sorts of changes:
(i) The file format is changed, so that command insets are represented as:
    \begin_inset CommandInset insetype
    LatexCommand command
    ...
    \end_inset
This involves some lyx2lyx and changes to the readInset() routine in factory.cpp
(ii) The InsetCommand and InsetCommandParams classes also have to be changed, as the command name was used in these classes for various purposes for which the inset type ought really to be used.
Further clean-up to come.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20544 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-27 18:24:18 +00:00
Abdelrazak Younes
237c132c1e * Inset:
- get rid of the cached Dimension. Text inset dimensions are saved in ParagraphMetrics and mathed maintain their own dimension where needed.
- width(), ascent(), descent(): deleted.
- dimension(): now needs a valid BufferView.
- metrics(): now void.

* BufferView::getCoveringInset(): simplify.

* ParagraphMetrics(): now cache inset dimensions.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20420 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-21 20:39:47 +00:00
Abdelrazak Younes
4c82dd1fc8 Inset coords shall not be recorded in Inset::draw() because this can create problems with inheritance (which often modify the coords but not the Inset pointer itself). Right now there three kind of inset containers: paragraphs, tables and math arrays. The coords caching is fixed in the first two.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20376 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-20 10:58:38 +00:00
Jürgen Spitzmüller
59c2e75e41 * src/insets/InsetCommand.{cpp,h}:
- implement edit function that opens the inset's dialog.
* src/BufferView.cpp (doDispatch):
	- call inset->edit (i.e. open dialog) for EDITABLE insets on next-inset-toggle (bug 2907)
* src/Text3.cpp (doDispatch: INDEX_INSERT):
	- move inset->edit to where it belongs.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20193 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-10 16:06:01 +00:00
André Pönitz
ed858d73e5 use bald pointers in clone()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19920 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 18:03:17 +00:00
Abdelrazak Younes
0fcae6cc10 * BufferView::buffer() returns a reference instead of a pointer.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19691 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-21 13:03:55 +00:00
Lars Gullik Bjønnes
897436efbb Whitespace cleanup
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18550 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-28 22:27:45 +00:00
Jean-Marc Lasgouttes
e499a5428e Fix bug 3301 (selecting buttons (e.g. a citation) with the mouse opens dialog)
* insets/InsetExternal.cpp (doDispatch):
	* insets/InsetGraphics.cpp (doDispatch):
	* insets/InsetInclude.cpp (doDispatch):
	* insets/InsetCommand.cpp (doDispatch):
	* insets/InsetVSpace.cpp (doDispatch): do not open dialog if a 
	selection is set.

	* insets/InsetRef.cpp (doDispatch):
	* insets/InsetCharStyle.cpp (doDispatch): act on mouse release, not
	mouse press.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18473 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-23 10:35:57 +00:00
Michael Schmitt
a746aa5214 "fix" bug #3332 (plain text export depends on the menu language)
Please note that method B_ (translate text to buffer language) is presently broken (at least on Windows)!


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18143 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-01 08:26:40 +00:00
André Pönitz
e0d54dd3b4 LyXText -> Text
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18103 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 23:33:02 +00:00
André Pönitz
32871c1284 rename InsetBase to Inset
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18089 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 13:39:47 +00:00
André Pönitz
42123ab8a7 rename LCursor->Cursor
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18040 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 14:56:30 +00:00
André Pönitz
39e79d8602 rename LyXLex into Lexer
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18033 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 11:30:54 +00:00
Bo Peng
00e305c9d9 Rename .C ==> .cpp for files in src, part one
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18018 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 04:41:58 +00:00
Bo Peng
c8d00ed127 Rename insets/insetxxx to insets/InsetXxx, part 2
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17965 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-25 01:25:51 +00:00