Commit Graph

114 Commits

Author SHA1 Message Date
Richard Heck
7ca8f5a5ec Cosmetics, and comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28552 a592a061-630c-0410-9148-cb99ea01b6c8
2009-02-19 03:24:51 +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
5a10add52e * "Copy as Reference" in the context menu of a label
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27575 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-16 19:19:07 +00:00
André Pönitz
f8f5a7b28d move updateLables to buffer
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27562 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-16 16:43:49 +00:00
André Pönitz
f1cba8ff64 more latin1..utf8 schanges. all of src/* should be utf8 now
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27425 a592a061-630c-0410-9148-cb99ea01b6c8
2008-11-14 15:58:50 +00:00
Abdelrazak Younes
070d75f1c6 revert hazardous part of r26957 and add a comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27169 a592a061-630c-0410-9148-cb99ea01b6c8
2008-10-28 17:51:08 +00:00
Enrico Forestieri
96007ce5ac Fix bug 5374
http://bugzilla.lyx.org/show_bug.cgi?id=5374


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26983 a592a061-630c-0410-9148-cb99ea01b6c8
2008-10-19 20:55:54 +00:00
Abdelrazak Younes
6a8219c190 Paragraph:
- constify some parameters
- getFontSettings():
- getFirstFontSettings(): return a const ref instead of a copy. This brings a consistent 4% improvement in LateX generation. Might speedup rtl handling too.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26957 a592a061-630c-0410-9148-cb99ea01b6c8
2008-10-19 07:03:44 +00:00
André Pönitz
4c7fdddd74 streamlining setter syntax. using mutable references seems a bit
outlandish compared to the rest of LyX


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26527 a592a061-630c-0410-9148-cb99ea01b6c8
2008-09-24 21:27:41 +00:00
Abdelrazak Younes
d28a762ec7 Fix copy & paste of inset inside table cell.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26420 a592a061-630c-0410-9148-cb99ea01b6c8
2008-09-15 17:03:15 +00:00
Abdelrazak Younes
f83a38b3de Paragraph::inInset() shall not be used if the owner inset was not initialized. Make this rule clear and unavoidable.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26385 a592a061-630c-0410-9148-cb99ea01b6c8
2008-09-13 17:01:54 +00:00
Abdelrazak Younes
7d888cc5e0 Fix silly bug spotted by Vincent in r26372
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26383 a592a061-630c-0410-9148-cb99ea01b6c8
2008-09-13 15:32:26 +00:00
Abdelrazak Younes
6cc68a2663 I forgot this in previous rev.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26371 a592a061-630c-0410-9148-cb99ea01b6c8
2008-09-12 13:43:48 +00:00
Abdelrazak Younes
227ae7c2c7 Get rid of indirections and add a check.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26370 a592a061-630c-0410-9148-cb99ea01b6c8
2008-09-12 13:36:40 +00:00
Jean-Marc Lasgouttes
4d63bd347b constification without any code change. This is part of and effort to see whether BufferView::cursor() could be made const
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26141 a592a061-630c-0410-9148-cb99ea01b6c8
2008-08-13 13:46:19 +00:00
Richard Heck
f1f6ca0963 Yet more empty-->plain.
By the way, can someone check around line 722 of CutAndPaste.cpp?


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26028 a592a061-630c-0410-9148-cb99ea01b6c8
2008-08-01 21:58:27 +00:00
Richard Heck
cca78e3c8a Change the "empty layout" to the "plain layout", to try to avoid confusion.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26025 a592a061-630c-0410-9148-cb99ea01b6c8
2008-08-01 20:57:27 +00:00
Abdelrazak Younes
3bbe1facb4 Fix crash with Menu->Edit->Paste recent
As an added bonus, the selection will be adapted to current Buffer (for quites, etc).


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26001 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-30 09:09:23 +00:00
Abdelrazak Younes
3b6e5373c2 Add FIXME.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25980 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-29 13:50:17 +00:00
Abdelrazak Younes
fa1305ccd3 InsetText: remove InsetText default ctor and make text_ member private.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25974 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-29 12:07:08 +00:00
Abdelrazak Younes
396a90decb Ensure that the Buffer pointer is correctly set with Clipboard operations.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25844 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-23 12:49:22 +00:00
Jürgen Spitzmüller
05dd160c87 * CutAndPaste.cpp: fix bug 5070.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25755 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-21 08:11:10 +00:00
Abdelrazak Younes
ba7e6e2b03 avoid that the internal Buffer used for cut&paste is visible in View menu.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25732 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-20 17:55:38 +00:00
Pavel Sanda
9c87bee68d Introduce Debug::SELECTION mainly for copy/paste primary-selection debugging.
Up to now it was hell to debug it, since the selection messages was under different
debug classes and the messages also get completely lost from mouse action events.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25624 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-14 23:47:54 +00:00
Abdelrazak Younes
d6e9c4eec0 Stay on the safe side: prevent filename clashing.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25599 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-14 09:00:11 +00:00
Abdelrazak Younes
e61643b43b Fix again http://bugzilla.lyx.org/show_bug.cgi?id=5010
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25598 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-14 08:48:25 +00:00
Abdelrazak Younes
7b7f95a439 temporarily fix http://bugzilla.lyx.org/show_bug.cgi?id=5026
This will reopen bug 5010 temporarily. Please don't touch this until I am finished.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25593 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-14 06:29:04 +00:00
Bo Peng
763ef015ce Improve the local layout feature by better handling of unknown textclass, unknown layouts, and switch between textclasses.
* src/TextClass.h[.cpp]: add addLayoutIfNeeded() and createDefaultLayout()
	* src/Layout.h[.cpp]: add unknown_ to mark if a layout is a default layout for an unknown one.
	* src/LayoutFile.cpp: add addDefaultClass and change addLayoutFile to addLocalLayout.
	* src/Text.cpp: add unknown layouts that are not recognizable by a new textclass.
	* src/frontends/qt4/GuiToolbar.cpp: display (unknown) for unknown layouts.
	* src/frontends/qt4/GuiDocument.cpp: restore 'browse layout' button.
	* src/frontends/qt4/ui/LaTeXUi.ui: restore 'browse layout' button.
	* src/CutAndPaste.cpp: do not convert unknown layouts from pasted text
	* src/BufferParams.cpp: add a default textclass when a document with unknown textclass is loaded.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25555 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-11 02:43:02 +00:00
Richard Heck
780bce0f96 Rename empty layout stuff to plain layout stuff.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25541 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-10 17:41:52 +00:00
Richard Heck
2b70ed0204 Thanks, Abdel.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25524 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-09 21:58:13 +00:00
Richard Heck
663043fd22 Fix the rest of bug 5010.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25523 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-09 21:27:15 +00:00
Richard Heck
341e4480df Typo.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25476 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-07 15:41:36 +00:00
Abdelrazak Younes
c3c49d8a0b Fix http://bugzilla.lyx.org/show_bug.cgi?id=4954
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25335 a592a061-630c-0410-9148-cb99ea01b6c8
2008-06-20 11:57:43 +00:00
Richard Heck
d216aacabf Fix bug 4712. Forgot the case where we need to reset layout from empty to default.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24884 a592a061-630c-0410-9148-cb99ea01b6c8
2008-05-22 14:06:23 +00:00
Abdelrazak Younes
eb28cb8755 Unify Paragraph::asString() methods.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24882 a592a061-630c-0410-9148-cb99ea01b6c8
2008-05-22 14:01:33 +00:00
Richard Heck
8a69ffd3bf Complete the removal of the embedding stuff. Maybe. It's hard to be sure we got everything, but this does compile, and it seems to work at least reasonably well. Any problems should of course be reported to the list.
For the record, this developer is sorry that the problems with this code were not noticed much earlier. It's not fun to do so much work and then have it all reverted.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24373 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-20 03:08:11 +00:00
André Pönitz
7f461f4392 infrastructure for 'graceful asserts'
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24216 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-10 21:49:34 +00:00
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
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
André Pönitz
a98f82c292 s/kb_action/FuncCode/g
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23749 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-15 01:20:36 +00:00
Stefan Schimanski
e01f7e7105 * fix a serious data loss problem: undo did not save the whole
selection in mathed if more than one cell was selected.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23675 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-12 00:59:29 +00:00
Stefan Schimanski
40c4d50c82 * fix for http://bugzilla.lyx.org/show_bug.cgi?id=4566
"Eqnarray multiple cells size change erases what they contain"

  We now loop over the selected cells and change the font in each of them.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23673 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-12 00:19:31 +00:00
Stefan Schimanski
b2e8d557cc * only use selection of current cell when starting a macro (fixes http://bugzilla.lyx.org/show_bug.cgi?id=4566 for macros)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23670 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-12 00:18:39 +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
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
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
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
Richard Heck
87795753e1 Header.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23302 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-28 03:55:08 +00:00
Richard Heck
d8a6b5bfd0 Remove TextClassPtr without losing the type safety it provided.
See these threads:
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg136112.html
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg136062.html
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg135997.html
for some background.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23299 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-28 01:42:02 +00:00