Commit Graph

2928 Commits

Author SHA1 Message Date
Richard Heck
30c7f6f019 Revert last commit.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23965 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-26 04:08:20 +00:00
Richard Heck
0922e29029 Make InsetText store a Buffer.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23964 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-26 03:54:44 +00:00
Abdelrazak Younes
8946ff512d Fix some issues with cursor settings with mouse button3 (text3:LFUN_MOUSE_RELEASE), simplify and correct InsetCollapsable mouse events.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23957 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 21:44:30 +00:00
Edwin Leuven
cc786534d8 don't know what i am doing here, but removing this doesn't seem to have any side effects
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23956 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 21:36:54 +00:00
Edwin Leuven
998787c78b make selecting several rows/col more convenient
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23955 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 21:26:03 +00:00
Edwin Leuven
30a290743d more border tweaks
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23954 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 20:48:48 +00:00
Richard Heck
2df6a6a378 Require a buffer on construction of InsetGraphics and InsetExternal. Eventually, this idea should probably be extended to all Insets, one or two at a time.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23950 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 16:08:39 +00:00
Edwin Leuven
4806c3f4cc rename some methods
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23947 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 13:32:38 +00:00
Edwin Leuven
5e6343c9d1 take care of overlooked contingency
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23945 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 11:40:16 +00:00
Abdelrazak Younes
fb25ff1819 Cleanup mouse/selection/context-menu interactions.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23944 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 10:54:38 +00:00
Jürgen Spitzmüller
d2a4c97ab8 Merge the diverse newpage insets into one.
* src/Buffer.cpp:
	- file format change to 323
* development/FORMAT:
	- document file format change

* src/insets/InsetNewpage.cpp:
	- the former four separate derivates are now merged into one inset
	  with proper Params and Mailer. This simplifies the structure and allows for
	  switching between the various kinds.

* factory.cpp:
	- The newpage insets are now being generated with 
	   newpage-insert [newpage|pagebreak|clearpage|cleardoublepage]

* src/Text.cpp:
	- Newpage inset is now a proper inset with opening and closing tag.

* src/FuncCode.h:
* src/LyXAction.cpp:
* src/Text3.cpp:
* src/insets/InsetCollapsable.cpp:
	- remove LFUN_PAGEBREAK_INSERT, LFUN_CLEARPAGE_INSERT
	  and LFUN_CLEARDOUBLEPAGE_INSERT

* lib/lyx2lyx/LyX.py:
* lib/lyx2lyx/lyx_1_6.py:
	- conversion and reversion routines for newpage insets.

* lib/ui/stdmenus.inc:
	- adapt menu and add context menu to switch between newpage variants.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23942 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 09:26:03 +00:00
Jürgen Spitzmüller
4b1cfb9852 * stdmenus.inc:
* src/insets/InsetCollapsable.inc:
	- specific context menu for conglomerate insets

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23940 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 06:17:18 +00:00
Jürgen Spitzmüller
e7e67bb9e9 * src/insets/InsetCaption.cpp:
- better fix for the inset-toggle crash resovled in rev. 23929.
	  Now, collapsing works again as in 1.5.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23939 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 05:33:39 +00:00
Richard Heck
7460abc627 Fix bug 4651. Bo, if you read this: Is there a cleaner way to do this, so that we can set parameters the way we used to? i.e., via setParam(p) here? rather than having to go through these hoops in updateParam()?
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23938 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-25 05:13:38 +00:00
Richard Heck
82a738b853 Fix branch insets.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23931 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-24 19:18:18 +00:00
Jürgen Spitzmüller
499d2a991d * src/BufferView.cpp:
- reintroduce check for dispatch state

* src/insets/InsetCaption.cpp:
	- disable LFUN_INSET_TOGGLE

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23929 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-24 18:22:54 +00:00
Jürgen Spitzmüller
241a8442d7 fix the general collapsable context-menu:
* src/InsetCollapsable.cpp (getStatus):
	- fix the logic

* src/BufferView.cpp:
	- fix next-inset-toggle
	- don't require argument for inset-settings

* lib/stdmenus.inc (context-collapsable):
	- use next-inset-toggle instead of inset-toggle
	- add (optional) inset-settings

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23928 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-24 16:33:56 +00:00
Edwin Leuven
8aae2dcd3b remove cruft (simplify code)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23922 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-24 14:03:00 +00:00
Jürgen Spitzmüller
e1ac6d4118 Some context menu work:
* src/BufferView.cpp:
* src/FuncCode.h:
* src/LyXAction.cpp:
	- new LFUN_NEXT_INSET_MODIFY

* src/insets/InsetBox.{cpp, h}:
* src/insets/InsetCommand.{cpp,h}:
* src/insets/InsetNote.{cpp,h}:
* src/insets/InsetSpace.{cpp,h}:
* src/insets/InsetVSpace.{cpp,h}:
	- implement context menu and access to some changes

* lib/ui/stdmenus.ui:
	- new context menus for Box, Space, VSpace, Note.
	- extend the context menu for InsetRef.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23920 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-24 13:33:48 +00:00
Bo Peng
057dd755f5 Move LFUN_GRAPHICS_EDIT and LFUN_EXTERNAL_EDIT from LyXFunc.cpp to BufferView.cpp so that a valid inset can be retrieved and called upon; add context-menu for InsetGraphics and InsetListings
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23910 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-24 04:27:43 +00:00
Jürgen Spitzmüller
48778460a0 * src/insets/InsetSpace.{cpp, h}:
- this inset is now editable. Mark as such and add an editable method (allows for opening the inset dialog with
	  "next-inset-toggle".
	- implement context menu (no actual menu yet).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23907 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-23 15:19:01 +00:00
Richard Heck
4219c529c2 Help us out here.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23906 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-23 14:40:29 +00:00
Richard Heck
ec5ac0486a Revert 23899 and introduce the correct fix.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23904 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-23 14:26:13 +00:00
Edwin Leuven
41a01648a7 simplify logic
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23901 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-23 11:35:46 +00:00
Bo Peng
46f37cfd3a Fix GRAPHICS_EDIT of InsetGraphics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23899 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-23 04:02:33 +00:00
Richard Heck
6a2921d119 Needless comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23888 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-21 19:38:02 +00:00
Richard Heck
94e0c24753 Make decoration default to, uh, Default. Flex insets will then default to conglomerate.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23886 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-21 18:49:23 +00:00
Abdelrazak Younes
de6f93296f Context menu for collapsing minimalistic insets such as ERT.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23880 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-21 18:02:47 +00:00
Richard Heck
b922cfd3b3 Another attempt at 2178. This is a "minimal" patch designed to fix the bug with the minimum amount of new code. A better fix, suggested by Andre, would merge InsetTableCell and CellData into one class, in which case InsetTableCell::cell_data_ can be removed. A definite plus. I'll do that later if this works. But let's get it right first.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23879 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-21 17:45:14 +00:00
Edwin Leuven
ed58c7dcd9 remove unused code
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23860 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-21 09:53:25 +00:00
Richard Heck
e995e8556b Prepare for InsetTableCell.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23858 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-21 06:16:05 +00:00
Bo Peng
8753847055 Listings: Move \label{} outside of caption={}
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23853 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-20 16:04:22 +00:00
Edwin Leuven
b7406da7f0 * new function to set border around selection
* add to toolbar + icon
* update border icons to match in size

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23846 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-20 08:45:40 +00:00
Richard Heck
f2cd36e8ad Change the signature of forceEmptyLayout(), so that we can pass a cell index with it. We'll need this to get tables right.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23829 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-19 16:21:33 +00:00
Pavel Sanda
826d0fc879 Change strings.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23819 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-18 23:35:57 +00:00
Edwin Leuven
e01e14872d Free line setting in tabulars. FILE FORMAT CHANGE.
- gets rid of the M_TOGGLE_LINE_... functions
- allows arbitrary clines without multicol
- sets arbitrary vertical lines through multicol 
- drop row/col line properties, everything is now stored at the cell level

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23812 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-18 18:08:32 +00:00
Jürgen Spitzmüller
18101eea7b ** add support for protected horizontal fill. FILE FORMAT CHANGE. **
* src/Buffer.cpp:
	- increment file format to 320.

* src/insets(InsetSpace.{cpp, h}:
	- add HFILL_PROTECTED, a protected horizontal fill
	  (LaTeX: \hspace*{\fill})

* src/factory.cpp:
* src/frontends/qt4/GuiHSpace.{cpp, h}:
	- handle the new space type.

* lib/lyx2lyx/LyX.py:
* lib/lyx2lyx/lyx_1_6.py:
	- reversion routine for protected hfill.

* development/FORMAT:
	- document file format change

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23805 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-18 12:11:28 +00:00
Uwe Stöhr
b1e077a7d2 compilation fixes
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23797 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-17 21:11:17 +00:00
Jürgen Spitzmüller
f2e8cd3cd9 *** File Format Change: UI and enhancement for InsetSpace ***
* src/insets/InsetSpace.{cpp,h}:
	- merge in HFill inset, add support for dotfill, hrulefill,
	  hspace and hspace*
* src/insets/InsetHFill.{cpp,h}:
	- remove

* src/frontends/qt4/GuiHSpace.{cpp,h}:
* src/frontends/qt4/ui/HSpaceUi.ui:
* src/frontends/qt4/GuiView:
	- new GUI for Space insets.

* src/insets/Inset.{cpp,h}:
* src/insets/InsetCode.h:
* src/insets/InsetCollapsable.cpp:
* src/insets/InsetCommandParams.cpp:
	- remove HFILL_CODE and LFUN_HFILL_INSERT, add SPACE_CODE where necessary,
	  new Inset member isStretchableSpace() to indicate HFill and friends.

* Buffer.cpp: 
	- increase format to 319
* lib/lyx2lyx/LyX.py:
* lib/lyx2lyx/lyx_1_6.py:
	- conversion/reversion routines
* development/FORMAT:
	- document file format change

* src/Makefile.am:
* src/frontends/qt4/Makefile.am:
* development/scons/scons_manifest.py:
	- deal with UI changes.

* src/LyXAction.cpp:
	- remove LFUN_HFILL_INSERT

* src/LyXFunc.cpp:
	- handle space dialog.

* src/factory.cpp:
* src/Paragraph.cpp (isHFill):
* src/Text.cpp:
* src/Text3.cpp:
* src/TextMetrics.cpp:
	- adapt to changes

* lib/ui/classic.ui:
* lib/ui/stdmenus.ui:
	- add HSpace dialog, remove HFill.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23787 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-17 09:23:43 +00:00
Stefan Schimanski
9e499117e3 * possibility to disable the completion cursor in text. All those
"*supported" methods maybe should be merged with a bit-enum as return value.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23776 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-16 17:07:10 +00:00
Richard Heck
bfdb31d076 Fix silly mistake uncovered by Helge.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23774 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-16 15:49:41 +00:00
Bo Peng
ccb09162e5 Embedding: paste an inset with an embedded file may fail, if the source buffer has been closed and the embedded file has been removed. This patch fixes this.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23771 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-16 05:10:41 +00:00
Edwin Leuven
781c2babeb fix append column when cursor is in multicol cell
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23764 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-15 16:44:00 +00:00
Stefan Schimanski
cdbebdf093 * moved text completion logic into Text class
* added completion support to InsetTabular


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23763 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-15 12:22:28 +00:00
Bo Peng
5ffc0d19c1 Embedding: when an inset with an embedded file is copied to another buffer, the embedded file needs to be copied, to an external file or to the temporary directory of that buffer. Otherwise, pasted insets will become invalid when the source buffer is closed and the embedded files are removed.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23758 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-15 04:48:31 +00:00
André Pönitz
0cb39e6f8b earder cleanup; cosmetics;
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23744 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-15 00:02:41 +00:00
Stefan Schimanski
6688fc1f1e * cosmetic
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23719 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-14 16:35:44 +00:00
Edwin Leuven
9f088c828e remove unused variable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23714 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-13 23:47:29 +00:00
Bo Peng
4ce363fcc6 Embedding: move file validation from InsetExternal to GuiExternal
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23711 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-13 17:27:20 +00:00
Bo Peng
3192307c86 Embedding: move file validation from InsetBibtex to GuiBibtex
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23710 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-13 17:19:36 +00:00
Bo Peng
dc177e2546 Embedding: move file validation from InsetGraphics to GuiGraphics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23709 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-13 16:49:04 +00:00
Bo Peng
ded962802e Embedding: prepare params()[embed] in GuiInclude rather than InsetInclude
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23708 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-13 14:16:47 +00:00
Jean-Marc Lasgouttes
72c26ac6d1 two uninitialized variables uncovered by valgrind, and a gcc warning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23707 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-13 10:28:02 +00:00
Bo Peng
fd34e3def1 Embedding: adjust how parameters are passed from the graphics dialog to InsetInclude
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23694 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-12 21:42:55 +00:00
Stefan Schimanski
10c974461d * typo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23671 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-12 00:19:07 +00:00
Bo Peng
4461cc2fda fix a typo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23669 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-11 19:29:16 +00:00
Bo Peng
d3f33c2106 Embed: fix a bug in initialize embedded file in InsetInclude
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23668 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-11 19:21:34 +00:00
Richard Heck
7a5576c13b Try again to fix bug 2178.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23662 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-11 15:16:58 +00:00
Abdelrazak Younes
04e46436ad * add "List of Graphics"
* don't append "(embedded)" to embedded list items.
* limit the number of entry to 30 items and offer to open the Navigator if above.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23659 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-11 10:27:33 +00:00
Abdelrazak Younes
f53467871f add "Embedded Files" to Navigator.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23658 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-11 09:04:09 +00:00
Abdelrazak Younes
b1742b5736 * InsetInclude::addToToc(): show embedded status if any in Navigator.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23657 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-11 08:37:30 +00:00
Abdelrazak Younes
4f1d3f2162 * add "Child Documents" navigate submenu.
* move secondary lists to "Other Lists" navigate submenu as the menu started to be crowded.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23656 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-11 08:25:13 +00:00
Abdelrazak Younes
2ab77c16f6 Introduce Inset::isLabeled() in order to avoid reimplementing Inset::initView() everywhere we need a labels update.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23637 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-10 15:30:32 +00:00
Abdelrazak Younes
346839b59f fix http://bugzilla.lyx.org/show_bug.cgi?id=4608
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23636 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-10 15:01:57 +00:00
Stefan Schimanski
76dc2c0d30 * make macros global. This is conceptionally much easier for the user,
and moreover simplifies the code a lot.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23616 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-10 12:49:02 +00:00
Pavel Sanda
635b2c1cc3 Start some context-edit menu.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23609 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-09 23:30:02 +00:00
Jürgen Spitzmüller
3f7d2a66f5 * src/insets/InsetNote.h:
- implement missing noFontChange.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23601 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-09 17:43:16 +00:00
Abdelrazak Younes
51a5db7110 General support for InsetCommand context menu. For this to work properly I had to disable all actions triggered by mouse right-clicking. This was bad ui in any case.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23579 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-09 11:22:39 +00:00
Bo Peng
6dc7cbe1e7 Continue working on the embedding feature. An additional parameter updateFile is passed to
EmbeddedFile::enable() and EmbeddedFiles::enable() to differentiate different usages.
A member variable bibfiles_ is added to InsetBibtex because it is not efficient to obtain
EmbeddedFileList each time from params()['bibfiles'] and params()['embed'].


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23576 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-09 06:05:22 +00:00
Abdelrazak Younes
22aa0137d3 Transfer general edit context menu from BufferView to InsetText.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23574 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-08 22:57:22 +00:00
Abdelrazak Younes
6e807d67ec * Inset::buffer(): assert when buffer_ is not set.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23557 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-08 11:56:20 +00:00
Richard Heck
c7a0329a87 Fix crash.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23549 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-08 00:08:03 +00:00
Abdelrazak Younes
5da55588f2 * Buffer::getLabelList(): Speed up and simplify by using the tocBackend.
* Inset and derived class: get rid of getLabelList()
* BufferView::gotoLabel(): Speed up and simplify by using the tocBackend.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23541 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-07 19:46:04 +00:00
Abdelrazak Younes
af3852b12c fix memory leak
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23537 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-07 13:36:39 +00:00
Abdelrazak Younes
8998dac1a7 InsetInclude: use InsetLabel instead of handling "label" parameter manually.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23536 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-07 13:33:33 +00:00
Richard Heck
6edb3984bf BaseClassList --> LayoutFileList
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23532 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-07 03:53:21 +00:00
André Pönitz
e13cc7e90d start moving MenuBackend to the frontend
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23523 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-06 21:50:27 +00:00
Richard Heck
a01cb111a0 Change the interface to a paragraph's layout. We still store a LayoutPtr, but now privately, and make a Layout const & available to clients.
The need for a LayoutPtr arises from the fact that (a) we do not want to give our clients a Layout &, since we do not want them to be able to change our Layout; but (b) we also need to be able to change which layout is ours. So we cannot store a Layout const &. Or so it seems to the compiler.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23522 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-06 21:31:27 +00:00
Abdelrazak Younes
258cca4b3b Delete child buffer at InsetInclude destruction.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23521 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-06 20:58:59 +00:00
Richard Heck
f401ce5d29 Changes LayoutList from a vector<LayoutPtr> to a vector<Layout>.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23519 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-06 20:01:30 +00:00
Abdelrazak Younes
af6e88250a Load child documents unconditionally at updateLabels() time.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23513 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-06 18:13:04 +00:00
André Pönitz
75999ba650 make code look a bit more uniform
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23468 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-05 00:21:05 +00:00
André Pönitz
a694476ac6 try to pass a Buffer & to inset construction if some buffer(param)
access is needed


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23465 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-04 22:28:18 +00:00
Abdelrazak Younes
37b429e347 Add citations to Navigator.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23458 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-04 17:47:47 +00:00
Stefan Schimanski
cd63c1380b * remove some garbage from the "buffer in inset" change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23453 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-04 14:58:10 +00:00
Abdelrazak Younes
3974c5f230 add missing break, should fix the remaining problem in revision 23420.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23422 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-04 07:33:43 +00:00
Jürgen Spitzmüller
5fce07a02b * src/insets/InsetLabel.[cpp,h}:
* src/insets/InsetCommand{.cpp,h}:
	- rename update to updateCommand

* src/CutAndPaste.cpp:
* src/insets/InsetBibitem{cpp,h}:
	- add duplicate check. There's a remaining glitch: the warning message after setting a bibitem
	  key in the dialog to a duplicate pops up twice.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23420 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-04 06:41:47 +00:00
Abdelrazak Younes
c084b71a9b get rid of LFUN_INSET_REFRESH
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23418 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 18:06:27 +00:00
Abdelrazak Younes
017ba3c4c7 Sanitize a bit the way InsetRef and InsetCommand button are drawn.
* Inset::validate(): renamed to initView()

* InsetCommand:
- get rid of unneeded refresh() and updateButtonLabel_
- setParams(): call initView()

* InsetRef:
- implement initView()
- screenLabel(): transfer code to updateLabels()
- addToToc(): prefix name with BROKEN if the reference is broken.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23417 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 17:58:26 +00:00
Jürgen Spitzmüller
45520d7ced * src/insets/InsetLabel.cpp (doDispatch):
- typo.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23413 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 13:58:18 +00:00
Abdelrazak Younes
aef2959b26 Add "DUPLICATE:" prefix to screen labels. 1.6 won't allow them now but importing a 1.5 documents can contain duplicate labels.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23412 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 13:31:44 +00:00
Abdelrazak Younes
34d15c9150 revert 23410 and fix InsetLabel::update() instead. It seems that the const_iterator used in InsetLabel::update() did not please gcc.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23411 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 13:16:23 +00:00
Jürgen Spitzmüller
6f455a916b * src/insets/InsetLabel.cpp (doDispatch):
- restore call to changeRefsIfUnique.

The references were not updated if the label name was changed.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23410 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 12:22:17 +00:00
Jürgen Spitzmüller
ffc4554815 add label/refs validation on pasting.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23407 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 09:35:26 +00:00
Jürgen Spitzmüller
eef138f77b * src/insets/InsetLabel.cpp:
- minor fixes to the label validation.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23406 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 08:19:36 +00:00
Richard Heck
264ee9f584 Nasty mistake here.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23405 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-03 04:19:50 +00:00
Abdelrazak Younes
00d6906d04 Introduce Inset::validate() for Inset validation purpose upon interactive creation. In this commit this is used to validate a newly inserted label. As an added bonus, broken cross-references will be automatically fixed if the corresponding label is created.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23399 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-02 18:14:12 +00:00
Abdelrazak Younes
132003aac5 Avoid duplicate labels when the user change an InsetLabel.
* InsetLabel:
- update(): new method for changing the label. Uses the Buffer reference cache instead of a lookup.
- LFUN_INSET_MODIFY: use update() instead of Buffer::changeRefIfUnique().




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23393 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-02 17:04:10 +00:00
Jürgen Spitzmüller
ce2a68ce8d * src/insets/InsetWrap.{cpp,h}:
- fix the fix of rev. 23390. Thanks, Abdel.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23392 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-02 16:56:57 +00:00
Jürgen Spitzmüller
4398113ee9 * src/insets/InsetWrap.{cpp,h}:
- button label has to be set before drawing (bug 4602).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23390 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-02 16:34:17 +00:00