Commit Graph

2813 Commits

Author SHA1 Message Date
Abdelrazak Younes
c3452835a8 * MetricsInfo::background_color: int -> ColorCode
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21255 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-29 10:36:20 +00:00
Abdelrazak Younes
d2bfe05827 Forbid implicit conversion from FontInfo to Font.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21250 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-28 23:32:18 +00:00
Abdelrazak Younes
5ddc612b73 Splitup Font in saner bits:
* Font::FontBits -> FontInfo
* Font::FONT_XXX -> all enums transfered to FontEnums.h and renamed to FontXxx

I've replaced Font uses with FontInfo were the language() member was not needed, basically all draw() and metrics methods. There's one problematic cases with InsetQuotes which I solved by taking the Buffer main language.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21240 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-28 18:51:54 +00:00
Martin Vermeer
9bc5e190d4 ERT simplification
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21224 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-27 14:05:05 +00:00
Richard Heck
4ca3a3d59c InsetIndex is no longer an InsetCommand.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21210 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-25 22:29:45 +00:00
André Pönitz
aece85ea30 188094 lines
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21206 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-25 20:36:17 +00:00
Richard Heck
8f2a8c7267 Revert inadvertent commit.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21200 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-25 13:38:42 +00:00
Abdelrazak Younes
eea79637c7 Move Color::color enum to ColorCode.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21198 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-25 12:41:02 +00:00
Martin Vermeer
1f07a7f929 Introduce inset parameters keepempty, freespacing, needprotect and rename verbatim->passthru
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21197 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-25 09:19:26 +00:00
Richard Heck
07b6198f4c Move the findInfo() and defaultCommand() routines out of InsetCommand and into its subclasses, so that the subclasses know what parameters they want, etc. Also, introduce an "isCompatibleCommand()" routine, so the subclasses can tell us which commands they are prepared to accept.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21194 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-25 04:13:56 +00:00
Abdelrazak Younes
1026a87b72 * InsetList: introducing find() and count()
* Paragraph:
- erase numberOfOptArgs() and bibitem()
- move onlyText() to Private.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21180 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-24 15:32:43 +00:00
Martin Vermeer
9e6aa60d0f Move disabling LFUNS from ERT to Collapsable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21178 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-24 11:30:47 +00:00
André Pönitz
b99433e73b cosmetics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21157 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-23 21:41:17 +00:00
Richard Heck
2f4d0ae27e Remove methods marked for removal from InsetCommandParams. Yeah, we can do that now. ;-)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21154 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-23 18:51:04 +00:00
Richard Heck
4064d2c468 InsetInclude becomes an InsetCommand.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21149 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-23 15:02:15 +00:00
Dov Feldstern
662b58497e Getting rid of LTR bias --- part 1/?
This is the first patch in a series meant to remove LTR bias from the code.
Currently, there are many places in the code where "right" and "left" are used,
but where we actually mean "forward" and "backwards" --- which is the same 
thing in LTR text, but not in RTL/Bidi text.

See full details in http://permalink.gmane.org/gmane.editors.lyx.devel/97550.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21128 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-22 22:18:52 +00:00
Martin Vermeer
5ab6d5bf65 Simplify ERT by using verbatim
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21121 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-22 18:01:21 +00:00
André Pönitz
f934b86850 cosmetics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21097 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-21 10:50:56 +00:00
André Pönitz
fbb3abfeac cosmetics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21085 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-20 17:35:27 +00:00
Martin Vermeer
ccacb487f2 Verbatim for URL inset, \protect for special phrases (index inset)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21083 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-20 17:05:28 +00:00
André Pönitz
ee005614a3 saner borderline between buffer and exporter
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21080 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-20 10:51:13 +00:00
André Pönitz
f762cbf3c6 mainly cosmetics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21079 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-20 10:03:45 +00:00
Richard Heck
a46d7ee857 My bad. Sorry Helge!
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21073 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-19 17:49:45 +00:00
Richard Heck
e158e07c29 InsetCommandParams() now takes an InsetCode rather than a string.
These changes are just adaptations to the new signature.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21072 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-19 17:22:55 +00:00
André Pönitz
a02653e4dd isome more FileName shuffling
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21048 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-18 23:03:51 +00:00
André Pönitz
988f372843 use FileName::isDirectory()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21047 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-18 21:10:35 +00:00
André Pönitz
0e08bc5e16 start using FileName::exists()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21044 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-18 19:29:32 +00:00
Abdelrazak Younes
6725b2db59 Reduce header dependencies in Paragraph.h
- Move Changes.h out of Paragraph.h
- pimpl the inset list.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21033 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-18 15:29:51 +00:00
Abdelrazak Younes
55beda376a Refactor Undo/Redo framework into an Undo class owned by a Buffer. This reduces header dependencies from Undo.h which was including lots of stuff previously. This also solves the bug where undo/redo were reset upon buffer switching. Now, each buffer has a truly independant undo/redo architecture.
In the future, when Cursor has been fixed to work correctly with multiple views of the same Buffer, we could transfer the Undo owner from Buffer to Cursor.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21031 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-18 11:51:17 +00:00
Richard Heck
63c10fcdfd Silence some warnings.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21003 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-17 12:33:47 +00:00
Richard Heck
3070a548e6 Fix bug due to empty default commands.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20997 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-16 19:21:00 +00:00
Richard Heck
26fd6a1420 Change how InsetBibTeX does this check.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20996 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-16 18:53:10 +00:00
Richard Heck
13d7df639b Rationalize lyxCode().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20990 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-16 16:48:21 +00:00
Richard Heck
9a097259be Cosmetics.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20987 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-16 08:33:37 +00:00
Uwe Stöhr
9f5b085f44 Fix two author entries.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20964 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-14 10:41:10 +00:00
Uwe Stöhr
c841ecd61b InsetHyperlink.cpp: fix bug 449: handle special characters in the url and name field
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20963 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-14 03:10:51 +00:00
Bo Peng
366b902cdc Fix typos in the comment in InsetInfo.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20962 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-14 01:37:02 +00:00
Bo Peng
4385c156e2 Allow the input of an InsetInfo using command buffer (e.g. "info-insert menu paste"). Document this change in InsetInfo.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20961 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-14 00:47:52 +00:00
Bo Peng
bb35edd0b0 Add Erlang support for listings (bug 4263)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20958 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 20:56:28 +00:00
Bo Peng
07fcacfd8b Document InsetInfo in insets/InsetInfo.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20956 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 20:49:06 +00:00
Uwe Stöhr
7075eaadef The huge URL patch:
- rename the lfun to href-insert.png
- rename the files to Hyperlink...
- the former URLUi produces now \href commands (hyperref)

Only missing thing is the lyx2lyx conversion routine - this will be done by Richard

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20950 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 19:06:09 +00:00
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
Martin Vermeer
1ecd2189f2 Dissolve CharStyle initial implementation.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20944 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 12:59:44 +00:00
Abdelrazak Younes
589170bd4b Remove mostly unused function.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20943 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 12:58:43 +00:00
Abdelrazak Younes
36e9a1fd30 Inset::translate() -> lyx::insetCode()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20942 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 12:50:18 +00:00
Abdelrazak Younes
fb306e4a90 Oups!
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20941 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 10:23:16 +00:00
Abdelrazak Younes
f7b1c86393 Move Inset::Code to InsetCode.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20936 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-13 09:04:52 +00:00
Bo Peng
f847e0776b InsetInfo: add LYXRC_INFO (lyxrc bind_file ==> cua)
NOTE: The syntax in LyXRC.cpp is ugly, and this feature is not extremely useful. Therefore, this patch may be reverted in the end.
	* src/insets/InsetInfo.h|cpp: support LYXRC_INFO
	* src/LyXRC.h|cpp: allow output of a specific RC item.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20908 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-11 15:23:52 +00:00
Bo Peng
4ed5939d2e InsetInfo: add MENU_INFO (menu paste ==> Edit > Paste)
* src/insets/InsetInfo.h|cpp: handle MENU_INFO
	* src/MenuBackend.h|cpp: add searchFunc function


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20907 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-11 15:14:11 +00:00
Bo Peng
62c98f2ffc InsetInfo: add InsetInfo (core)
* src/insets/Inset.cpp: add InsetInfo
	* src/insets/Inset.h
	* src/insets/InsetInfo.cpp
	* src/insets/InsetInfo.h
	* src/LyXAction.cpp: add LFUN_INFO_INSERT
	* src/lfuns.h
	* src/BufferView.cpp: 
	* src/factory.cpp
	* src/Text3.cpp: insert InsetInfo with selected text
	* development/scons/scons_manifest.py: build tools update
	* src/Makefile.am


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20904 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-11 14:52:00 +00:00
Martin Vermeer
04ee2d87fc Introduce allowMultiPar()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20898 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-11 10:13:45 +00:00
Abdelrazak Younes
9a458ec6e9 Move private part of BufferView to a private implementation.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20896 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-11 09:59:01 +00:00
Martin Vermeer
5a2deb94c3 Fix bug, and introduce MultiPar parameter for flex insets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20869 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-09 17:07:24 +00:00
Jean-Marc Lasgouttes
1a53e1099a * src/paragraph_funcs.cpp (breakParagraph): change parameter 'flag' to
simpler 'keep_layout'

	* src/Text.cpp (breakParagraph): change parameter keep_layout to 
	inverse_logic.

	* src/Text3.cpp (dispatch): remove LFUN_BREAK_PARAGRAPH_KEEP_LAYOUT;
	implement "inverse" flag to LFUN_BREAK_PARAGRAPH.

	* src/LyXAction.cpp:
	* src/insets/InsetCaption.cpp (doDispatch):
	* src/insets/InsetFlex.cpp (doDispatch):
	* src/insets/InsetTabular.cpp (doDispatch): 
	* src/insets/InsetIndex.cpp (doDispatch):
	* src/lfuns.h: remove all traces of LFUN_BREAK_PARAGRAPH_KEEP_LAYOUT.

	* lib/bind/cua.bind:
	* lib/bind/xemacs.bind: 
	* lib/bind/emacs.bind:
	* lib/bind/mac.bind: adapt bindings.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20846 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-08 13:17:15 +00:00
André Pönitz
06fe2c019f next one
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20772 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-06 09:19:53 +00:00
Martin Vermeer
9585df177e Get Conglomerate-style rendering back into order
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20769 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-06 08:15:40 +00:00
Uwe Stöhr
a2fe099fc0 GuiBox.cpp: fix update of height checkbox
BoxUi.ui: fix the ui according to r20727
InsetBox.cpp: fix that e.g. "1\width" wasn't output to TeX

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20739 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-05 00:36:38 +00:00
André Pönitz
e462715b01 and this...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20711 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-03 20:18:58 +00:00
André Pönitz
58ab972f71 last commit was incomplete... not sure how I managed this..
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20710 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-03 20:15:49 +00:00
Martin Vermeer
d21a3bb445 Index as collapsible, preserving existing feature set
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20699 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-03 13:38:19 +00:00
André Pönitz
d71a4a71dd cosmetics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20672 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-02 22:10:33 +00:00
André Pönitz
f318fbf36c cosmetics for unused code...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20649 a592a061-630c-0410-9148-cb99ea01b6c8
2007-10-01 22:14:03 +00:00
André Pönitz
fad47c0fe0 boost/utility -> boost/noncopyable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20608 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-30 15:47:00 +00:00
Jürgen Spitzmüller
cb28ab77bc * src/insets/InsetGraphics.cpp (prepareFile):
- Fix wrong external_path that triggered an assert on Windows
	  while exporting to LaTeX (bug 4243).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20607 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-30 12:38:08 +00:00
André Pönitz
cd72af583f cosmetics
(maily move layout related enums into a header of there own to remov
include dependencies, alos rename a few things)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20598 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-29 20:02:32 +00:00
Uwe Stöhr
9259fb187c InsetBox.cpp: fix an issue with the height parameter handling
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20595 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-29 16:47:23 +00:00
André Pönitz
581b67b26e move ChangeLogs to the attic
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20587 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-29 14:12:55 +00:00
Uwe Stöhr
e63f19a97a GuiBox: fix bug 3242 http://bugzilla.lyx.org/show_bug.cgi?id=3242:
make minipage optional height argument optional

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20547 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-27 20:19:06 +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
fb6af9a08a Remove remnant of the past.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20481 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-25 07:41:03 +00:00
Abdelrazak Younes
4b649e746a Fix drawing of horizontal line and page break.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20480 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-25 07:07:11 +00:00
Abdelrazak Younes
82d3607f05 Hopefully fix 'Corners' and 'SubLabel' insets drawing.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20479 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-25 06:49:04 +00:00
Jürgen Spitzmüller
d00ae71b63 Fix bug 4182, partially:
* src/insets/InsetCaption.cpp (draw, metrics):
	- set correct font for caption in Workarea.
* src/insets/insetListings.cpp (latex):
	- try to set correct font for caption in output (doesn't work yet).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20472 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-24 17:51:15 +00:00
Uwe Stöhr
b7d0510502 Fileformat increased to 287: support for optional arguments of package wrapfig that is used for wrap floats
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20462 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-24 13:43:58 +00:00
Abdelrazak Younes
a7058ad9c7 * CoordCacheBase::covers(): new method.
* CoordCache: correct and extend documentation.

* Inset::covers(): use CoordCacheBase::covers().


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20459 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-24 08:05:49 +00:00
Abdelrazak Younes
137158532b Put mathed on a diet: transfer dimension cache from inset to BufferView.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20457 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-23 22:39:49 +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
André Pönitz
3ff14b8300 Pavel Sanda's "PDFOptions" patch
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20389 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-20 22:31:18 +00:00
André Pönitz
82309f0c2d Remove a few includes from Text.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20386 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-20 20:44:08 +00:00
Richard Heck
aa01777060 Change LFUN_FONT_CODE to LFUN_FONT_TYPEWERITER, possibly in preparation for a move to character-style-based font changes, etc.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20381 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-20 18:02:39 +00:00
Martin Vermeer
417c25c91b Robustify this
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20379 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-20 14:11:37 +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
Abdelrazak Younes
7fca730b3b Remove TextMetrics.h header.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20373 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-20 08:51:58 +00:00
Richard Heck
0917ffc697 Indentation fix.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20369 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-20 06:22:07 +00:00
Martin Vermeer
4cc0355468 Polish
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20354 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-18 20:48:39 +00:00
Martin Vermeer
dc23701244 Pick up some stitches dropped by Abdel ;-)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20353 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-18 20:18:50 +00:00
Abdelrazak Younes
516ff470d8 Fix InsetBox drawing and remove remnant of the wide() hack.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20334 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-18 08:52:38 +00:00
Abdelrazak Younes
745d9ac46e * InsetCollapsable::draw(): replace use of dim_ with InsetText::dimension().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20331 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-17 22:18:07 +00:00
Abdelrazak Younes
85fa1e9efd remove InsetCaption::drawSelection(): this was not used.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20328 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-17 21:51:32 +00:00
Abdelrazak Younes
2dc0945bda remove InsetCollapsable::drawSelection(): this was not used.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20327 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-17 21:48:25 +00:00
Abdelrazak Younes
74acf6b528 Cleanup the TEXT_TO_INSET_OFFSET mess. This correction is done now once in InsetText. Various other cleanup resulting from this change. In particular, pave the way to the removal of Dimension Inset::dim_ member by registering the inset dimension in RowPainter::paintInset() instead of InsetXXX::draw().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20326 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-17 21:45:14 +00:00
Bo Peng
6258199fe8 make index label translatable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20318 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-16 14:43:10 +00:00
Bo Peng
18d587cb7e Display index name in InsetIndex label
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20313 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-16 14:08:16 +00:00
Lars Gullik Bjønnes
26f336769a Remove warnings reported with gcc 4.3:
- Modifier on return type ignored
	- Ambigous else
	- Ambigous logical operators
	- Semi-colon instead of empty block
	- Missing header files
	- Missing using std::XX
	- Initialization out of order


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20304 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-16 10:36:57 +00:00
Bo Peng
93196b1f73 Embedding: add a check box to InsetGraphic and show/change embedding status
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20297 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-15 18:31:32 +00:00
Martin Vermeer
a750970781 Force current font to red typewriter in ERT
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20261 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-13 14:29:44 +00:00
Bo Peng
ca281eaa0c Embedding: update related insets when the embedding status of a fileitem is changed
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20240 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-12 14:27:47 +00:00
André Pönitz
887bd847c6 remove unnneded #include
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20233 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-11 22:31:24 +00:00
André Pönitz
9b8e429a64 remove unnecessary includes
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20228 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-11 21:43:55 +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
Bo Peng
3189e7b5dd Embedding: prepare to read/write manifest in .lyx file
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20186 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-10 03:54:02 +00:00
Uwe Stöhr
17112f655d Helge's wrapfig patch:
- Format incremented to 284
- LaTeX-package wrapfig is now used instead of flotflt for wrap floats (this allows us to implement now also a table wrap float)

(the optional overhang argument of wrapfig will be implemented later)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20185 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-09 23:47:22 +00:00
Abdelrazak Younes
c3e3534148 * TextMetrics::draw(): withdraw first row ascent before drawing because the convention is that the baseline of a multirow text is the baseline of the first row.
All other files: adapt to above change.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20177 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-09 20:21:43 +00:00
Bo Peng
2a1a156f47 Embedding: store inset pointer instead of ParConstIterator to enable more accurate navigation in the Embedding dialog
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20164 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-09 07:07:13 +00:00
Martin Vermeer
2e5355e4c2 Convert CharStyle to Flex also in file format
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20138 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-08 13:01:29 +00:00
Bo Peng
d4a2219813 Embedding: remove AUTO feature, barely make it compile
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20119 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-07 03:02:24 +00:00
Martin Vermeer
2ddba774ce y-coord in Conglomerate, this time properly
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20103 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-06 14:17:03 +00:00
Martin Vermeer
6089258acc Fix y co-ordinate for Conglomerate-style inset
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20102 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-06 14:06:07 +00:00
Abdelrazak Younes
ea87429a23 Nicely align inset buttons with surrounding text.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20101 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-06 12:25:30 +00:00
Abdelrazak Younes
2d8b08b63c InsetCollapsable::draw(): Rename 'top' local variable to baseline as that's what it is really.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20100 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-06 12:00:32 +00:00
Abdelrazak Younes
95e09581c5 Fix alignment of text within insets.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20083 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 22:08:41 +00:00
Abdelrazak Younes
d9d7af7019 Fix drawing of collapsable inset without button.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20082 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 21:52:12 +00:00
Abdelrazak Younes
67905de3fc Fix tabular text y-positioning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20080 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 21:02:49 +00:00
Abdelrazak Younes
7e2d8d3955 Fix caption text y-positioning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20079 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 20:54:15 +00:00
Martin Vermeer
fe0f7858c2 Renaming CharStyle -> Flex, finishing touch
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20076 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 18:40:56 +00:00
Bo Peng
c1e4304322 Embedding feature patch 5: handling of embedded files (operation without external files)
*  src/insets/InsetGraphicsParams.h|cpp:
	*  src/insets/InsetExternal.cpp: read/write buffer with embedded file
	*  src/insets/InsetGraphics.cpp: ditto
	*  src/EmbeddedFiles.h|cpp: add find() function


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20075 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 17:50:07 +00:00
Martin Vermeer
12e1d4bc8d Name change CharStyle -> Flex
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20072 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 15:29:04 +00:00
Abdelrazak Younes
67a2b3f28f Fix text frame drawing.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20071 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 14:19:52 +00:00
Abdelrazak Younes
6a35e705a4 Fix cursor positioning withing collapsable insets.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20070 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 14:15:07 +00:00
Alfredo Braunstein
8158e25ab7 (InsetCollapsable::draw) restore background color (avoid psychedelic effects when selecting a note)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20069 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 13:52:43 +00:00
Abdelrazak Younes
d1813ca269 * TextMetrics::draw(): get rid of the first par ascent offset.
* BufferView::draw(): adapt to above change.

* InsetCollapsable::draw(): ditto -> get rid of textdim_ member.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20068 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 13:45:58 +00:00
Abdelrazak Younes
eed6514dd0 Move selection painting closer to row painting. Single row painting is now possible for selection.
* Row:
- setSelection(): set selection begin and end for this row.
- sel_beg, sel_end: new public members.

* BufferView::draw()
- do not trigger a full repaint for selection.
- use TextMetrics::draw() instead of hand calling TextMetrics::drawParagraph().

* InsetText::draw(): don't call TextMetrics::drawSelection().

* InsetMathMBox::drawSelection(): remove.

* TextMetrics:
- drawSelection(): simplify a bit. Now private.
- redoParagraph(): memorize Row selection status.
- x2pos(): fix crash when selecting with PageDown.
- draw(): fill-in the ParPos cache before everything else and not in drawParagraph().
- drawParagraph(): take care of row selection painting.







git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20066 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-05 13:04:05 +00:00
Edwin Leuven
e5c0c385ca rename method
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20043 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-04 18:13:19 +00:00
Edwin Leuven
39ee5b3fb2 renaming of some methods that hurt the eyes + removal of:
- column and row count, 
- tabular width and method that goes with it
- method declaration without implementation: void delete_column(col_type)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20032 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-04 10:52:08 +00:00
Alfredo Braunstein
a8ed1add4d rename Paragraph::isRightToLeftPar -> isRTL for the sake of consistence
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20031 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-04 10:27:55 +00:00
Abdelrazak Younes
2ea432bab1 * TextMetrics: getDisplayFont() and isRTLBoundary() takes pit instead of Paragraph.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20015 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 22:28:49 +00:00
Abdelrazak Younes
d35d25460b * Text: Move some more stuff from Text to TextMetrics:
- getFont() becomes TextMetrics::getDisplayFont()
- setCharFont() now needs a display font.
- setInsetFont() and setFont() now needs a BufferView, will be transferred to TextMetrics too.
- isRTL(): moved to TextMetrics
- isRTLBoundary(): ditto
- font_: ditto

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20014 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 21:48:49 +00:00
Abdelrazak Younes
bc6304d760 Don't save background color in Text. Hand it down at drawing time.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20002 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 14:34:15 +00:00
Abdelrazak Younes
e5ec07d513 * InsetText::font_: removed, this was not used anywhere.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20000 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 13:50:37 +00:00
Abdelrazak Younes
af06ed5ff1 Transfer current_font and real_current_font from Text to Cursor.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19999 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 13:35:48 +00:00
Abdelrazak Younes
7150b25b7e * InsetCollapsable::metrics(): Allow a bit more inlined size.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19993 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 10:35:36 +00:00
Abdelrazak Younes
4048448236 Transfer metrics and screen related methods from Text to TextMetrics.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19991 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 09:44:08 +00:00
Martin Vermeer
3f358459fc Final touch on minimalistic branches
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19989 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-02 08:38:09 +00:00
Abdelrazak Younes
452348f4ce * InsetCollapsable::metrics(): Put back the test previous to revision 14472 for openinlined_
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19985 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-01 23:01:21 +00:00
Martin Vermeer
8906059a0a Cleanup painting of corners
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19978 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-01 20:38:25 +00:00
Martin Vermeer
e0db6e2679 small cleanup collapsable; label fix branch
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19976 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-01 17:55:21 +00:00
Martin Vermeer
ed6f900552 Use Minimalistic for branches
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19973 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-01 11:40:09 +00:00
Abdelrazak Younes
fb74d5a476 * InsetCollapsable::metrics(): it seems we don't need to refit anymore. Saves an InsetText::metrics() call and enable single Row painting within opened inline insets.
* TextMetrics::drawParagraph(): force full repaint on Insets that are within the current repainting row.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19968 a592a061-630c-0410-9148-cb99ea01b6c8
2007-09-01 09:24:20 +00:00
Alfredo Braunstein
c94eb3deeb cosmetics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19959 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-31 20:24:15 +00:00
Alfredo Braunstein
d44c6722f0 fix two metrics bug + remove an extra metrics call
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19954 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-31 17:32:27 +00:00
Abdelrazak Younes
6c111008dc Hack: full repaint of text inset in Tabular. This will do until I can optimize it. We've never done anything but full repaint anyway in tabular.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19948 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-31 14:02:12 +00:00
Martin Vermeer
92e8e19363 Further cleanup, decoration -> geometry, bugfix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19944 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-31 12:05:41 +00:00
Abdelrazak Younes
2bff0157b6 Transfer Text::drawSelection() to TextMetrics.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19940 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-31 10:05:12 +00:00
Martin Vermeer
2854410d7b Cleanup: Replace decoration() calls by geometry(). (And get rid of unused call)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19937 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-31 07:15:32 +00:00
Abdelrazak Younes
3e77ba1eab remove unneeded drawSelection() method.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19936 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-31 07:10:24 +00:00
Abdelrazak Younes
44812bdec2 Transfer Text::drawSelection() from InsetText::drawSelection() to InsetText::draw(). This enables to take care of the background at one place. This will also enable to draw only the selection in the future (and not the full inset).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19934 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 22:46:22 +00:00
Abdelrazak Younes
32a0ece3de compil fix.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19927 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 22:30:14 +00:00
Abdelrazak Younes
d0b8d63d2c fix text background painting.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19925 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 22:12:13 +00:00
Bo Peng
692363bbca Embedding patch two: read/write embedded files'
*  src/insets/InsetGraphics.h
	*  src/insets/InsetExternal.cpp
	*  src/insets/InsetGraphics.cpp
	*  src/insets/InsetInclude.cpp
	*  src/insets/Inset.h
	*  src/insets/InsetInclude.h
	*  src/insets/InsetExternal.h: register embedded files
	*  src/EmbeddedFiles.h|cpp: core of embedded files
	*  src/Buffer.h|cpp: read/write embed file
	*  src/BufferParams.h|cpp: embedded flag
	*  src/Makefile.am
	*  po/POTFILES.in
	*  development/scons/scons_manifest.py: build system updates


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19924 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 20:46:42 +00:00
Abdelrazak Younes
9b9168c31a Fix redrawing bug for multirow inlined collapsable inset.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19921 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 19:27:33 +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
a088c6754a Finally enable single row repainting within insets! The inset width needs to stay fixed of course.
* BufferView::draw(): makes use of PainterInfo::full_repaint
* TextMetrics::drawParagraph(): ditto.
* InsetText::drawSelection(): don't fillRectangle() if there's no selection.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19918 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-30 15:17:38 +00:00
Richard Heck
8a947f63da This is one of a series of patches that will merge the layout modules development in personal/branches/rgheck back into the tree.
Design goal: Allow the use of layout "modules", which are to LaTeX packages as layout files are to LaTeX document classes. Thus, one could have a module that defined certain character styles, environments, commands, or what have you, and include it in various documents, each of which uses a different document class, without having to modify the layout files themselves. For example, a theorems.module could be used with article.layout to provide support for theorem-type environments, without having to modify article.layout itself, and the same module could be used with book.layout, etc.

This patch adds the backend. The ModuleList class holds a list of the available modules, which are retrieved from lyxmodules.lst, itself generated by configure.py. There are two LFUNs available: modules-clear and module-add, which do the obvious thing; you can test by typing these into the minibuffer, along with the name of one of the available modules: URL (a CharStyle), Endnote (a Custom Inset), and---with the spaces---End To Foot (View>LaTeX and look at the user preamble), which are themselves in lib/layouts. There are some others, too, that allow theorems to be added to classes like article and book.

The GUI will come next.

Issues: (i) The configure.py script could be improved. It'd be nice, for example, if it tested for the presence of the LaTeX packages a particular module needs. But this would mean re-working the LaTeX script, and I don't know how to do that. Note that at present, the packages are ignored. This will change shortly. (ii) I've used std::string in LyXModule, following what seemed to be a precedent in TextClass. If some of these should be docstrings, please let me know, and I'll change them. (iii) There is at present no distinction between LaTeX and DocBook modules. Should there be? That is: Should there be modules that are available when the document class is a LaTeX class and others that are available only when it is DocBook? Or should there just be one set of modules? Each module can of course indicate for what it is suitable in its description.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19893 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-29 17:59:49 +00:00
Abdelrazak Younes
235312c376 * InsetCollapsable::setStatus(): remove the Buffer::changed() signal emission. This causes a WorkArea redraw before the BufferView metrics update happens.
* WorkArea::dispatch(): replace the redraw() call with a Buffer::changed() signal emission in order to update all views of the Buffer, even though some view won't need the redraw...



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19867 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-28 18:13:17 +00:00
Abdelrazak Younes
86624539f4 header cleanup.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19853 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-28 15:08:03 +00:00
Abdelrazak Younes
55f184563e - Transfer rowpainter.cpp:paintTextInset() to TextMetrics::draw()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19842 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-27 22:36:20 +00:00
Martin Vermeer
def5620e58 Fix black float background
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19839 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-27 20:27:02 +00:00
Abdelrazak Younes
b52c339cce Bug fix: correctly redraw a Row containing and inset which Dimension slightly changed. This replace the need for the former leftEdgeFixed boolean in rowpainter.C:paintPar() before the removal of the wide() hack in revision 19834.
* Inset::dimension(): access to dim_

* TextMetrics::redoParagraph(): don't trust Inset::metrics() returned boolean as the internal dimension is changed down in the inheritance chain for InsetFoot->InsetCollapsable->InsetText.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19838 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-27 16:30:57 +00:00
Abdelrazak Younes
3c92c2ab13 Remove the wide() hack. This simplifies quite a few things...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19834 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-27 14:38:29 +00:00
Martin Vermeer
77b575e562 Move background colour into the layout files -- for all collapsables
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19813 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-26 20:32:58 +00:00
Martin Vermeer
5541f145fa Set up decoration handling for all collapsable insets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19798 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-25 20:12:50 +00:00
Martin Vermeer
30506f8e11 Clean-up in CharStyles, externalize detection of undefined styles to
layout files



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19790 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-25 14:43:59 +00:00
Martin Vermeer
e4a160c6cf Make Richard happy, add inset layout parm 'Decoration'
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19786 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-25 09:57:32 +00:00
Martin Vermeer
89287ef7ee Oops -- cut off wrong part of label
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19771 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-24 14:42:41 +00:00
Alfredo Braunstein
09b0a337ca move forwardIdx to CursorSlice from DocIterator, as it was the only one able to travel into an invalid cursor position
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19763 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-23 21:35:40 +00:00
André Pönitz
39c7e2faf0 rename Layout_ptr into LayoutPtr
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19758 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-23 19:59:07 +00:00
Richard Heck
6e93e77f22 This is one of a series of patches that will merge the layout modules development in personal/branches/rgheck back into the tree.
Design goal: Allow the use of layout "modules", which are to LaTeX packages as layout files are to LaTeX document classes. Thus, one could have a module that defined certain character styles, environments, commands, or what have you, and include it in various documents, each of which uses a different document class, without having to modify the layout files themselves. For example, a theorems.module could be used with article.layout to provide support for theorem-type environments, without having to modify article.layout itself, and the same module could be used with book.layout, etc.

This first patch does some reworking of the infrastructrue. We need to distinguish between the TextClass that a particular document is using and the layout of that document, since modules, in particular, can modify the layout. The solution adopted here is to add a TextClass pointer to BufferParams, which will hold the layout. The layout itself is then constructed from the TextClass the document is using. At present, this is completely trivial, but that will change when modules are added.

The pointer in question is a boost::shared_ptr. This is needed because CutAndPaste saves a copy of the layout with each cut or copied selection. We cannot assume the selection vanishes when the document is closed, so there are two options: (i) keep a list of all the layouts that have ever been used by any document; (ii) used some kind of smart pointer. The latter seems preferable, as the former would waste memory. More importantly, the use of a smart pointer allows modules to be modified on disk and then reloaded while LyX is running, and it will eventually allow the same for layout files.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19756 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-23 16:41:13 +00:00
Martin Vermeer
e38b581bcb add preamble snippets to charstyles
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19732 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-22 18:55:03 +00:00
Martin Vermeer
612af5c5f0 inset configurability: ERT
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19702 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-21 21:29:13 +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
Abdelrazak Younes
1356543c45 The BufferView/WorkArea/LyXView reorg a.k.a Multiple WorkAreas:
* Buffer:
- get rid of cursor_ and anchor_
- ~Buffer(): update the labels of its master buffer before closing
- closing(): pass the Buffer address.

* BufferView():
- BufferView(): needs a valid Buffer (should be const in the future.
- most of the change is about removing all test of buffer_ nullity.
- resize(): deleted.
- setBuffer(): deleted.

* Application:
- newLyXView(): simplification
- updated design description in Application.h

* Gui/GuiImplementation: remove all WorkAreas and BufferView creation/Deletion. Workareas are directly handled by  LyXView/GuiView and BufferView is created/delete by WorkArea.

* LyXView/GuiView: implement the new design

What is not working yet:
- the close tab button: it is implemented but does not show up.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19686 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-21 07:33:46 +00:00
Bo Peng
f982b5e051 Fix crash when a user removes a formula when its preview is being generated. (Another signal/destructor/gcc3 bug)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19667 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-20 21:30:33 +00:00
Martin Vermeer
f289399bf5 Inset configurability, LaTeX work
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19665 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-20 19:02:38 +00:00
Richard Heck
cd772c60a5 Biblio.{h,cpp} --> BiblioInfo.{h,cpp}
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19660 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-20 17:04:36 +00:00
Richard Heck
b3bff4232a Improvements to the citation dialog UI. It is now possible to search particular fields (author, title, etc) and to filter keys by entry types (article, book, etc).
The changes are essentially of three types. 

First, the std::maps previously used here for storing BibTeX data have become full-fledged classes and so what were previously just a bunch of functions have now become methods of these new  classes. This leads to a lot of minor changes in other files, to adapt to the  new signature. The changes in insets/ are mostly of this kind.

Second, there are some slightly more substantial changes in src/insets/InsetBibtex.cpp. We now store lists of the field names and entry types that have been used.

Finally, there are the changes to the citation UI. These are mostly straightforward, though adding the new functionality exposed some inadequacies in the previous code that also had to be fixed.

One other change: BibTeX keys are now docstring. This solves some Unicode issues.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19657 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-20 16:30:02 +00:00
Martin Vermeer
063a289171 small Note cleanup
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19655 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-20 04:58:29 +00:00
Martin Vermeer
5c1ffabd05 Cleanup 3: move dispatch stuff from CharStyle to Collapsable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19654 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-20 04:56:04 +00:00
Martin Vermeer
2b927e1575 Cleanup 2: moving more stuff charstyle -> collapsable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19648 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-19 15:45:35 +00:00
Martin Vermeer
d39896da58 Small cleanup
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19642 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-19 10:08:09 +00:00
Martin Vermeer
3c504502bf Further inset configurability, moving charstyle stuff to collapsable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19640 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-18 23:26:07 +00:00
Martin Vermeer
dc2a40e7e9 Partial merge of CharStyle and InsetLayout stuff, first part
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19621 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-17 15:38:58 +00:00
Abdelrazak Younes
f32757e3ef * InsetCollapsable::geometry(): shut up warning by returning a dummy value and cosmetics.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19620 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-17 12:11:32 +00:00
Bo Peng
81031b4cea Fix crash when a user removes the underlying figure of a graphic inset that has been copied and pasted (Bug 4108). Revert Andel's fix r19591
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19612 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-16 18:37:38 +00:00
Martin Vermeer
f0ece382e4 Streamlining CollapseStatus stuff
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19610 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-16 16:36:50 +00:00
Jean-Marc Lasgouttes
7fe51efeb8 remove annoying debug message
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19605 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-16 12:42:56 +00:00
Jean-Marc Lasgouttes
f756c02329 The counters labelstring patch. Part 2: Use the new code.
* src/Paragraph.cpp (expandLabel): if the labelstring is empty,
	use \thecounter instead; when processing @layout@ tokens, pass the
	process_appendix boolean.

	* src/buffer_funcs.cpp (setLabel):
	* src/insets/InsetFoot.cpp (updateLabels): 
	* src/insets/InsetCaption.cpp (updateLabels): use
	Counters::theCounter.

	* src/insets/InsetBibitem.cpp: remove the ad-hoc numbering code
	and replace it with a proper updateLabels-based solution.

	* src/insets/InsetCommands.cpp (refresh): new method.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19603 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-16 11:12:56 +00:00
Richard Heck
5bb22d9498 Re-write of the BibTeX representation. The main change is that we now have
a structure representing field->value instead of just a single string with
all the data. The data structures are defined in src/Biblio_typedefs.h, and
the main changes are to the parser code in src/insets/InsetBibtex.cpp.

-src/Biblio_typedefs.h
 Contains typedefs for new representation. Separating them out limits how much 
 gets #include'd by other files, and also resolves a circularity problem with
 Buffer.h.

-src/Biblio.{h,cpp}
 Signature changes and massive simplifications to routines that report
 BibTeX data, since we now have an articulate representation.

-src/insets/InsetBibtex.{h,cpp}
 Re-write the parser code so we store a key->value map of the BibTeX data
 rather than just one long string. This is the main work.

-src/frontends/controllers/ControlCitation.{h,cpp}
-src/insets/InsetBibitem.{h,cpp}
-src/insets/InsetCitation.cpp
 Adaptations and simplifications.

-src/insets/Inset.h
-src/Buffer.{h,cpp}
-src/insets/InsetInclude.{h,cpp}
 Signature changes.

-src/Makefile.am
-development/scons/scons_manifest.py
 Add src/Biblio_typedefs.h


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19598 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-16 01:59:20 +00:00
Abdelrazak Younes
bf33e34869 fix signal crash with gcc 3.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19591 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-15 15:13:22 +00:00
Abdelrazak Younes
5958daf51b Fix child document labeling (const missing from overloaded updateLabels()).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19589 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-15 12:15:16 +00:00
Abdelrazak Younes
eb14ee5e22 * Buffer.cpp: load all child documents in one go where it makes sense. This has the advantage to call updateLabels() only once for the master buffer. We can think of maintaining a child document list in the future.
* Biblio.cpp: fillWithBibKeys(): ditto.

* InsetInclude.cpp: loadIfNeeded(): set the parent name in any case.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19586 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-15 08:55:36 +00:00
Richard Heck
de373da67b Add LFUN_PARAGRAPH_PARAMS (= paragraph-params), used for changing a paragraph's alignment, spacing, etc. This is complementary to LFUN_PARAGRAPH_PARAMS_APPLY, which sets the parameters. The difference is that APPLY over-rides all existing parameters, setting any not given to the default, whereas this one simply changes those that are given. So
paragraph-params \align right
will align the paragraph right, leaving spacing, etc, as they were, whereas
  paragraph-params-apply \align right
will align the paragraph right but also reset all other parameters to defaults. Note, by the way, that this means that
  paragraph-params-apply
sets everything to default.

Some new arguments have also been introduced. These are:
  \indent
  \indent-toggle
  \spacing default
Of course, none of these are found in valid LyX files, but they are useful in menu bindings, etc.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19581 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-15 02:21:09 +00:00
Richard Heck
a3f613f0ca Cosmetics.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19567 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-14 17:01:22 +00:00
Richard Heck
8a221dc70c Move the lyx::biblio namespace into src/. Also make changes to how the BibTeX
information is acquired. This involves (i) moving the bulk of fillWithBibKeys() 
into Biblio.cpp, (ii) introducing a virtual method Inset::fillWithBibKeys() that,
by default, does nothing, and (iii) over-riding this method in the insets that do
need to do something.

This is all preparatory for a more substantial re-working of the BibTex code,
which should follow shortly.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19565 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-14 16:50:51 +00:00
Abdelrazak Younes
92ee23acb4 cosmetics
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19561 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-14 14:41:06 +00:00
Martin Vermeer
249e97e216 fixing the 580 fix also for trunk
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19559 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-14 14:21:46 +00:00
Abdelrazak Younes
32268e2632 cosmetics + move frontends/* to frontend namespace.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19553 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-14 09:54:59 +00:00
Jean-Marc Lasgouttes
b0d1a6b717 Fix bug 409 (Add support for numbered footnotes)
* src/insets/InsetFoot.cpp (updateLabels): number the footnote if
	(1) the footnote counter exists and (2) it is not in a title
	layout

	* lib/layouts/stdcounters.inc: add a footnote counter.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19524 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 20:29:33 +00:00
Jean-Marc Lasgouttes
eca0637e51 compilation warning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19523 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 20:12:52 +00:00
Abdelrazak Younes
4e7e580f54 I forget this in rev 19515.
* InsetInclude: loadIfNeeded()
- make it non anonymous (used in loadChildDocuments()).
- now return the loaded buffer.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19520 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 19:40:54 +00:00
Richard Heck
236badeac0 Fix update bug when leaving a wide inset with up or down arrow.
Override notifyCursorLeaves() in InsetText to force update when
inset was wide. Should be removed if and when wide is.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19511 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 17:23:42 +00:00
Jean-Marc Lasgouttes
ded1c011f2 * inset/InsetTabular.cpp (doDispatch): LFUN_MOUSE_PRESS: let Text::dispatch
do the work, unless we really have a reason not to (fixes bug 4133)

	* mathed/InsetMathNest.cpp (lfunMousePress): refactor the code to use
	BufferView::mouseSetCursor.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19506 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 15:38:32 +00:00
Alfredo Braunstein
bc0a64efc3 * DocIterator.h (forwardPosNoDescend): remove method
* DocIterator.cpp (forwardPos, backwardPos): move the 'flat' part to...
* CursorSlice.{h,cpp} (forwardPos, backwardPos, at_end, at_begin): new methods, the first two are part of their DocIterator homonym
* Text2.cpp (setFont): receive CursorSlice arguments as the function is not recursive, adapt
* Text.cpp:
* lyxfind.cpp (findNextChange):
* insets/InsetCollapsable.cpp: adapt



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19500 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 13:36:19 +00:00
Alfredo Braunstein
f1923a7b35 fix compilation
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19499 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 13:11:49 +00:00
Martin Vermeer
2bd998c29e Prepare for inset configurability
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19498 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-13 12:13:17 +00:00
Jean-Marc Lasgouttes
601a8e0192 Rewrite the label numbering code.
* buffer_funcs.cpp (updateLabels): new function taking a buffer and
	a ParIterator as arguments. This one is used to update labels
	into an InsetText. Cleanup the code to reset depth. Call setLabel
	for each paragraph, and then updateLabel on each inset it contains.
	(setCaptionLabels, setCaptions): removed.
	(setLabel): use Counters::current_float to make caption paragraphs
	labels.

	* insets/Inset.h (updateLabels): new virtual method, empty by
	default; this numbers the inset itself (if relevant) and then all
	the paragraphs it may contain.

	* insets/InsetText.cpp (updateLabels): basically calls
	lyx::updateLabels from buffer_func.cpp.

	* insets/InsetCaption.cpp (addToToc): use the label constructed by
	updateLabels.
	(computeFullLabel): removed.
	(metrics, plaintext): don't use computeFullLabel.
	(updateLabels): new method; set the label from
	Counters::current_float.

	* insets/InsetWrap.cpp (updateLabels):
	* insets/InsetFloat.cpp (updateLabel): new method; sets
	Counters::current_float to the float type.

	* insets/InsetBranch.cpp (updateLabels): new method; the numbering
	is reset afterwards if the branch is inactive. (bug 2671)

	* insets/InsetNote.cpp (updateLabels): new method; the numbering
	is reset after the underlying InsetText has been numbered.
	(bug 2671)

	* insets/InsetTabular.cpp (updateLabels): new method (also handles
	longtable)

	* insets/InsetListings.cpp (updateLabels): new method; mimics what
	is done for Floats (although Listings are not floats technically)

	* insets/InsetInclude.cpp (getScreenLabel): in the listings case,
	use the computed label.
	(updateLabels): new method; that either renumbers the child
	document or number the current listing.

	* LyXFunc.cpp (menuNew): do not updateLabels on empty documents
	(why do we do that at all?)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19482 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-12 21:43:58 +00:00
José Matox
ca81b43f03 Fix bug 518 (thanks to Jean Marc and Martin for the help)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19455 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-12 13:25:36 +00:00
André Pönitz
2caa98bee0 disable some tests for standard C++ features; add a line counting stream for lates output
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19446 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-12 08:57:17 +00:00
André Pönitz
5d80a87ceb merge {mathed,insets,graphics}/Makefile.am into src/Makefile.am
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19424 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-11 10:32:36 +00:00
André Pönitz
67e61a3956 enable building of shared libraries. reduces final linktime. also combine boost stuff into a single library
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19410 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-10 22:33:54 +00:00
Lars Gullik Bjønnes
5ae54ddafb Get rid of a few warnings.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19409 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-10 20:14:54 +00:00
Christian Ridderström
1050cc4471 Converted '#warning ...' into FIXME-comments
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19397 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-10 11:47:12 +00:00
Jean-Marc Lasgouttes
35fa399edd Syncronize with 1.5. This stuff was uncommitted in y tree actually.
* src/BufferView.cpp (workAreaDispatch): set selection status here

	* src/Text3.cpp (dispatch):
	* src/InsetTabular.cpp (doDispatch): and not here


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19396 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-10 10:21:09 +00:00
Martin Vermeer
cf96711fc9 fix bug 580: reading of some ill-formed tables
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19390 a592a061-630c-0410-9148-cb99ea01b6c8
2007-08-10 08:05:10 +00:00
Bo Peng
3ac3578e2d Fix Bug 4053: Update other controls allows invalid listings parameters to be passed in listings-related dialogs.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19224 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-27 18:17:00 +00:00
Abdelrazak Younes
1007714d2e Properly fix bug 3258.
* InsetTabular: 
  - remove the is_deleted_ boolean
  - dispatch(): remove the call to updateDialog at the end

* ControlTabular::initialiseParams(): connect to the current tabular if found.

* QTabular::update_contents(): initialiseParams() each time.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19112 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-18 09:55:33 +00:00
Jürgen Spitzmüller
3993a0498b * src/insets/Inset.h: fix encoding of author names
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19110 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-18 09:30:38 +00:00
Abdelrazak Younes
01891912bc fix std declaration.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19102 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-17 17:33:36 +00:00
Abdelrazak Younes
4863cfdf78 Fix this bug:
1) create a doc
2) insert an ert inset
3) right-click the inset
4) new window
5) delete the ert inset: BOOM! 

This commit replace the static hideDialog signal which was in effect shared by all views with a direct call to Dialog::hide().


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19094 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-17 09:20:39 +00:00
Abdelrazak Younes
4a53fa6e01 Allow unicode in Layout names.
* Layout.h:
  - name_, obsoleted_by_, depends_on_ are now docstrings.

All other changes results from the above string -> docstring changes. In particular, we now try to translate the layout names only if possible (i.e. if they are ASCII only).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19042 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-11 13:39:08 +00:00
Bo Peng
5ead210b1c add a few 'experimental parameters' to insetListingsParameters.cpp. This is pretty safe so I just commit it.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19033 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-10 18:57:32 +00:00
Abdelrazak Younes
6c15c36495 This patch revert part of the code changed in revision 18825. This is needed because there is no lyx_view_ when exporting at the command-line: LFUN_BUFFER_CHILD_OPEN uses LyXView::loadLyXFile() in GUI mode.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19029 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-10 15:07:00 +00:00
Jean-Marc Lasgouttes
ae9dad1770 remove obsolete references to saveSelection
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19024 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-10 10:54:42 +00:00
Jean-Marc Lasgouttes
625a4b7849 * insets/InsetExternal.cpp (InsetExternalParams): use the first
defined template as default instead of RasterImage (bug 3983)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19013 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-09 10:56:49 +00:00
Bo Peng
252ec84acd Remove all saveSelection calls and unify theSelection().setSelection. This is the common, housekeeping part of JMarc's and my patches. Fixes of bug 3877 will come later
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19003 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-06 17:03:45 +00:00
Bernhard Roider
b8b66e8278 Fix uninitialized var introduced in http://www.lyx.org/trac/changeset/18966
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18976 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-03 18:58:02 +00:00
Bernhard Roider
3525573f40 Fix Bug 3947: BibTeX allows parentheses in the key (even if the whole entry is delimited by parentheses)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18966 a592a061-630c-0410-9148-cb99ea01b6c8
2007-07-02 18:01:27 +00:00
Jürgen Spitzmüller
8b9972cbba Fix bug 2753: LyX doesn't support paths and filenames with parentheses
* src/frontends/qt4/QBibtex.cpp:
* src/frontends/qt4/QExternal.cpp:
* src/frontends/qt4/QGraphics.cpp:
* src/frontends/qt4/QInclude.cpp:
	- remove path validator

* src/support/filetools.{cpp,h}:
	- new validator for exporting LaTeX files

* src/insets/ExternalSupport.cpp:
* src/insets/InsetBibtex.cpp:
* src/insets/InsetGraphics.cpp:
* src/insets/InsetInclude.cpp:
	- use validator when exporting a LaTeX file

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18897 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-26 16:55:42 +00:00
Uwe Stöhr
d8993d2d6c - Fileformat change: rename "arabic" to "arabic_arabtex"
- Split the language Arabic into "arabic_arabi" that uses the arabi-package and "arabic-arabtex" that uses the arabTeX-package to typeset Arabic. This is needed because both packages have some advantages over the other people need.
(This change is a consequence of a long and fruitful discussion with Mostafa, Dov, and me.)

Patch by Dov and me.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18887 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-26 00:11:03 +00:00
Jürgen Spitzmüller
bcf64dd11c Fix bug 1749. CAUTION: lyx2lyx not fully working yet (see FIXMEs).
* development/FORMAT: 
	- document file format change

* src/Buffer.cpp: bump format to 275.

* lib/lyx2lyx/LyX.py:
* lib/lyx2lyx/lyx_1_5.py:
	- conversion and reversion of scaleBeforeRotation param (doesn't work yet!)

* src/insets/InsetGraphicsParams.{cpp,h}: 
	- new param scaleBeforeRotation
* src/insets/InsetGraphics.cpp:
	- swap order of scale and rotate (if scaleBeforeRotation is false)

* src/frontends/qt4/QGraphics.C:
* src/frontends/qt4/QGraphicsDialog.{cpp,h}:
* src/frontends/qt4/ui/GraphicsUi.ui:
	- add checkbox to toggle scaleBeforeRotation.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18885 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-25 13:49:51 +00:00
Alfredo Braunstein
c1852732b7 Fix one-by-some bug in tabular selection drawing by appropriately
calling InsetText::drawSelection instead of Text:drawSelection


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18881 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-25 08:19:15 +00:00
Jürgen Spitzmüller
91c6d03678 Fix bug 2520: Make InsetExternal translateable
* po/lyx_pot.py:
	- new function external_l10n: parse external_templates and extract the relevant parts for translation.
* development/scons/SConstruct:
* po/Makefile.in.in:
	- use external_l10n

* src/insets/InsetExternal.cpp:
* src/frontends/qt4/QExternal.cpp: 
	- make eveything translatable

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18866 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-23 07:50:13 +00:00
Alfredo Braunstein
0ebfa36965 const correctness (missed this)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18853 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-22 13:38:07 +00:00
Alfredo Braunstein
fb963c2587 const correctness
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18852 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-22 13:33:51 +00:00
Richard Heck
d3003c1022 Polish the Toc and labels updating when loading a child document.
Fix Bug 3860: Toc crash when loading a child documents.

* BufferView::loadLyXFile(): simplify, transfer last part to
  LyXView::loadLyXFile().
  Change return value to Buffer created by load (or 0 if none).
  Ultimately, this should all be moved to buffer_funcs.cpp, as it is no
  longer needed here.

* Buffer::setParentName(): small fix to avoid recursive includes.

* LyXView:
- setBuffer(): properly update the labels and the Toc if this is [LOAD Child
  Document] command. Move buffer connection and disconnection, simplifying
  earlier code.
- loadLyXFile(): get some code from BufferView::loadLyXFile() and from
  LyXFunc::LFUN_BUFFER_CHILD_OPEN, properly handle the child document case.
  There's a lot of overlap with setBuffer() here. This needs cleaning.

* LyXFunc: add optional argument to LFUN_BUFFER_CHILD_OPEN to indicate if
  the document is being opened by LyX itself rather than the user (as on 
  View>DVI, for example).

* LyX: adapt to loadLyXFile() API changes.

* insets/InsetInclude: use LFUN_BUFFER_CHILD_OPEN rather than calling
  loadLyXFile() directly. Make use of new optional argument.

With this in place, the only thing missing for proper multipart document support is to automatically update the parent Buffer when switching from the parent Buffer. This would be very useful when you work with multiple document sharing the same child documents (as I often do).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18825 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-19 14:56:52 +00:00
Abdelrazak Younes
054a35c9a1 header cleanup.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18790 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-15 14:52:15 +00:00
Abdelrazak Younes
d14da39009 header cleanup.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18789 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-15 14:17:20 +00:00
Abdelrazak Younes
8f0bf62f2c header cleanup.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18788 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-15 14:10:26 +00:00
Abdelrazak Younes
77736e8679 header cleanup.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18783 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-15 13:47:13 +00:00
Abdelrazak Younes
b025e9a249 Saves some compile time by diminishing Buffer.h header dependencies:
- delete unneeded InsetList.h
- transfer the errorList to the private implementation.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18782 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-15 13:13:49 +00:00
Stefan Schimanski
98fb638d61 * the old cursor is stored before dispatch and then used after moving
up/down to tell the insets that the cursor left them. The
  notifyCursorLeaves methods can set updateFlags to trigger a redraw.
* leave mathed with cursor up/down and get the math redrawn for the
  decorations



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18773 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-14 20:32:28 +00:00
Bo Peng
985ba3b296 Add bypass validation checkboxes to listings related dialogs
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18751 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-12 17:10:28 +00:00
Jean-Marc Lasgouttes
4ba4d701f7 Remove background_color_ in Insets: it takes a lot of unnecessary memory,
especially in math where each equation has many insets.

	* src/Insets.cpp: remove background_color_ member
	(setBackgroundColor): remove
	(backgroundColor): make virtual

	* insets/InsetBranch.cpp:
	* insets/InsetNote.cpp: move color setting code from setButtonLabel to 
	backgroundColor.

	* insets/InsetBox.cpp (setButtonLabel): remove call to setBackgroundColor.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18750 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-12 13:45:49 +00:00
Stefan Schimanski
82c2fbf81a * they are conceptionally the same and should be merged
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18743 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-11 18:29:11 +00:00
Jürgen Spitzmüller
5d8e1d7dc5 * src/insets/insetBranch.cpp (doDispatch):
- remove wrong check, fix bug 3835.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18734 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-11 05:12:10 +00:00
Bo Peng
c20baf584c Revert rev18728, which is not a good idea
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18729 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-09 18:06:11 +00:00
Bo Peng
05439b953b Allow prefixing a listings parameter with @ to bypass validation, useful when new parameters are added in a new listings version
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18728 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-09 13:34:17 +00:00
Abdelrazak Younes
f8ee89093d Fix warning.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18726 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-09 13:18:54 +00:00
Abdelrazak Younes
bb8df6cc00 following rev. 18724 boost/signal is not needed.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18725 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-09 13:12:23 +00:00
Abdelrazak Younes
8f65acf693 Following revision 18723, Inset::destroyed() signal is not needed anymore.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18724 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-09 13:08:44 +00:00
Bo Peng
3a5c55e30d Fix bug3782, crash with selection of table cells, joint work with JMarc
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18709 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-07 21:55:55 +00:00
Bo Peng
358e7136f2 Fix compiling errors caused by r18701 (moving drawMarkers and drawMarkers2 back to Inset)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18708 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-07 21:36:42 +00:00
Bo Peng
8153ea8fa7 Show corners of mathed with mouse hover, details see bug 3825
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18701 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-07 18:08:03 +00:00
Bo Peng
7350639361 Update Toc when navigation menu is trigged.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18693 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-06 21:19:15 +00:00
Bo Peng
3175ee9c0d Add listings parameter linerange, new in listings 1.4
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18688 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-06 02:03:16 +00:00
Bo Peng
276f6fcde5 ?xxx show all parameters containing xxx in InsetListingsParams, remove all_param_names_ from ParValidator
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18687 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-05 22:08:43 +00:00
Bo Peng
8aa6a50e69 remove pit from addToToc definition in Inset.h, as reminded by Andre
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18683 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-05 18:58:07 +00:00
Bo Peng
d3e30f8d9b addToToc, pass parent ParConstIterator, fix bug 3711
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18680 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-05 17:24:11 +00:00
Michael Schmitt
70dce83dee * src/insets/InsetListingsParams.cpp: fix user message
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18635 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-03 06:30:08 +00:00
Bo Peng
9506a284d1 Fix bug 3363: mark buffer dirty after middle button paste in plain text and table; set cursor at the end of pasted text
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18632 a592a061-630c-0410-9148-cb99ea01b6c8
2007-06-02 13:34:06 +00:00
Bo Peng
fc82d491ab InsetListingsParams: allow key=value,key=value1 in listings parameters
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18604 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-31 22:02:55 +00:00
José Matox
35eb5ddb22 Add support for Farsi (thanks to Mostafa Vahedi).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18599 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-31 18:53:01 +00:00
Abdelrazak Younes
d075cb25b8 This patch transfer Inset::destroyed signal to InsetText and InsetMathNest thus freeing some memory as normal math chars and symbols won't have it.
It also solve a crash with non disconnect boost::signal and gcc-3.3 or 3.4.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18592 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-31 12:30:17 +00:00
Michael Schmitt
4cdd8f3428 * src/insets/InsetListingsParams.cpp: fix/improve message
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18589 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-31 11:51:23 +00:00
Michael Schmitt
6acdda13e9 * src/insets/InsetListingsParams.cpp: fix message: "latex" => "LaTeX"
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18581 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-30 20:57:17 +00:00
Michael Schmitt
78b71f9863 replace "Listings" by "Listing" (plural => singular)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18570 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-29 21:23:23 +00:00
Stefan Schimanski
880b6c4d6e 1. switch LFUN_UP/DOWN handling to a structural approach, i.e. the
dispatchers in mathed and text only do local work, i.e. only try to
move the cursor with their local knowledge, not globally as before in
the Cursor::goUpDown function before. The old approach used one of
brutefind functions as a last way out to really move the cursor up or
down. The result was some strange behavior that the nearest inset was
selected when jumping from math to text, not one in the next line. 
2. removed LFUN_FINISHED_UP/DOWN, as there seem to be no effect and it
seems to be obsolete.
3. target_x is working again, mainly by adding a textTargetOffset_
member to the Cursor which keeps the difference between the target_x
and the actual position of the cursor on screen. As long as
pos+offset=target is fulfilled the target_x is not touched and the
cursor keep the column while going up/down.
4. moved the text cursor up/down code to the Cursor class, in analogy
to the mathed code.
5. For 1 it is necessary to know the cursor position before the
dispatch. So this data is added to the Cursor.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18569 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-29 20:53:32 +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
Abdelrazak Younes
2dca49b74a * ListingsParam::ListingsParam(): use const ref.
* add some doxygen comments and FIXME.

* white space.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18536 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-27 22:46:09 +00:00
Abdelrazak Younes
e73f79e33e * InsetListingsParams.cpp: Code reorganization. Should fix bug 3639 and open the way to more advanced gui controls.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18533 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-27 11:55:46 +00:00
Bo Peng
aa31866501 Do not use \&@#^_~$ as lstinline delimiter, as suggested by Herbert
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18529 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-26 20:45:24 +00:00
Richard Heck
df99a5c933 Change related to 18445: buffer.fileName() uses .absFilename().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18524 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-26 17:33:52 +00:00
Richard Heck
c0b5fb6a80 Make logic clearer, with help from Lars.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18523 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-26 17:26:58 +00:00
Abdelrazak Younes
b49194c645 add some const.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18522 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-26 15:03:19 +00:00
Abdelrazak Younes
5cfe249522 - white space
- replace an occurrence of from_ascii() to _() for translation


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18521 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-26 14:53:12 +00:00
Abdelrazak Younes
398c24b8f2 - Convert char * to string and docstring for the hints, thus fixing the translation.
- cleanup the header.
- encapsulate local code in local namespace.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18520 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-26 14:45:38 +00:00
Michael Schmitt
de35c25d8d * src/insets/InsetInclude.cpp: formatting (in response to r18445)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18517 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-26 11:25:41 +00:00
Abdelrazak Younes
3fdbf5b9c4 Sanitize cursor saving/restoring in a multi-view context.
* Inset: new destroyed signal (copy ctor and operator= needed because of a signal is not copiable)

* CursorSlice:
 - connect to inset destructor wherever possible
 - invalidate(), isValid(): new method.
 - inset_: now private

* DocIterator::fixIfBroken(): new method for properly fixing cursors.

* StableDocIterator::asDocIterator(): verify cursor sanity before creating it.

* Cursor::fixIfBroken(): now a simple wrapper around DocIterator::fixIfBroken()

* BufferView::setBuffer(): verify cursor sanity before restoring it.

* WorkArea::redraw(): verify cursor sanity of concurrent BufferView display.


 

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18516 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-25 23:17:24 +00:00
Bo Peng
093b9452a4 Choose a delimiter for lstinline (braces can not be used for some listings version)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18513 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-25 16:15:02 +00:00
Bo Peng
5b731aa6a5 InsetListings: use float for placements because of the handling differences between float and floatplacement
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18508 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-25 14:38:22 +00:00
Bo Peng
1d99202d88 Minor fixes, in response to Lar's email
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18504 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-25 01:02:38 +00:00
Bo Peng
e5bf150a0c Use a new internal structure for InsetListingsParams, fix bugs 3713 and 3718
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18501 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-24 22:19:58 +00:00
Richard Heck
b28458129d Forgot to restore this before committing 18494. This fixes bug 3725.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18500 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-24 22:17:04 +00:00
Richard Heck
5fed0e44ed Fix stupid use of "or".
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18496 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-24 19:19:23 +00:00
Richard Heck
d2fb80eec7 Fix for bugs 2199 and 3667. Most of the changes were to the logic. Buffers
that were opened for possible included LyX files need to be closed if those
files cannot be loaded, for example. A bit more work was needed to allow a
LyX file to include itself as a verbatim or listings without trying to load
itself and without relying upon loadIfNeeded() to report the problem.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18494 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-24 17:17:04 +00:00
Bo Peng
1561aef0b5 Increase listings counter for InsetInclude with lstinputlisting and a caption, fix bug 3708
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18486 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-24 14:10:35 +00:00
Bo Peng
f8b1ce4ada Allow listing the lyx file itself, fix bug 3707
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18477 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-23 19:24:06 +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
Abdelrazak Younes
5112e0f821 Fix crash with collapsable insets and multiple views
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18471 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-23 07:43:16 +00:00
Bo Peng
b78c1db290 Make listings dialog translatable (mostly strings from InsetListingsParams), fix bug 3645
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18468 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-23 02:09:58 +00:00
Jean-Marc Lasgouttes
a9a3b79528 revert r17737; it was designed to fix bug 2993, but it created bug 3503. Consequently I will mark bug 2993 as wontfix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18454 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-22 14:06:40 +00:00
Jürgen Spitzmüller
cddcdd08ea make InsetListings ready for dialects, part 1 (joint work with Bo Peng):
* src/insets/InsetListingsParams.cpp:
	- complete list of languages/dialects
	- fix some typos
	- (validate): check for braces

* src/frontends/qt4/QListings.cpp:
	- fix list of languages (not yet complete)
	- make it possible to enter [dialect]language in the advanced widget

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18451 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-22 04:43:30 +00:00
Richard Heck
4318b4def2 Partial fix for bug 1474 (crashes on recursive includes) and complete fix for
bug 3659 (crash when file contains only an InsetInclude). 

Added checks for self-inclusion. The reason this is not a complete fix is that
recursive input could arise from something other than self-inclusion. Checking
for that will be much more complicated, however.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18445 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-21 15:34:29 +00:00
Jürgen Spitzmüller
5cb3e19200 * src/insets/InsetListings.{cpp,h}:
- implement metrics and draw, fix font initialization
	(fix bug 3653)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18429 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-20 05:53:49 +00:00
Bo Peng
e658f71f07 Remove color dependency of framed note, fix bug 3598
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18428 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-20 02:53:19 +00:00
Stefan Schimanski
a1802a2a96 * markers2 are drawn below the inset, hence increase the descent instead of ascent by the frame size.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18426 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-19 19:45:55 +00:00
Bo Peng
f672df5dc2 BUG 3649: display float listings inline, like other float insets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18413 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-18 20:01:56 +00:00
Bo Peng
d848a5e393 BUG 3598: display framed and shaded notes in a separate paragraph, require package color also for framed note
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18412 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-18 20:00:19 +00:00
Jürgen Spitzmüller
a42d3e670b Fix for bug 3637, joint work of Bo Peng and myself:
* src/insets/InsetListingsParams.{cpp,h}
	- implement getParamValue that returns the value of a listings param

* src/insets/InsetInclude.cpp:
	- (getLabelList): pass listings label to the list, if available
	- doDispatch: implement changeRefsIfUnique for listing labels

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18405 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-18 14:40:39 +00:00
Bo Peng
73849af5df InsetListings: change the interface of diaplay function and allow AlignLeft. Applied to InsetListings. Fixes bug 3617, 3618
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18404 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-18 14:32:29 +00:00
Bo Peng
a90f967d6f InsetListings: fix bug 3626
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18373 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-16 20:34:57 +00:00
Bo Peng
7ea0cd1dd9 InsetListingsParams.h/cpp: fix compiler warning about initialization order
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18344 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-15 14:56:55 +00:00
Bo Peng
72e0b87a90 Separate caption and label from InsetListingsParams and handle them separately in listings and Include dialog, from Jurgen
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18324 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-14 20:42:14 +00:00
Michael Schmitt
8684c07664 output changes by means of xcolor and soul
- when exporting with pdflatex 
  - when exporting with latex and dvipost is not available
rename two colors (strikeout => deletedtext, newtext => addedtext)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18284 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-13 15:17:57 +00:00
Bernhard Roider
6de5d0ad58 fix bug 2453
change of behavior of rotate-tabular and rotate-cell toolbar buttons such that they toggle the rotation. Therefore a toggle feature is added to the tabular features. Moreover after the patch the state of the set-rotate-cell and toggle-rotate-cell buttons is on only if all selected cells in the table are rotated. If not all selected cells are rotated then the toggle button rotates all selected cells.

The toggle-icons are copied from the set-icons.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18280 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-12 20:59:21 +00:00
Bo Peng
59252c1f8f InsetListingsParams.h/cpp: Allow , in parameter string which is common in caption
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18279 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-12 15:07:18 +00:00
Bo Peng
4d0552dd80 add color mathcorners and implement mathbg (partially)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18277 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-12 06:24:46 +00:00
Bo Peng
e44fc571cc revert wrongly committed patch
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18263 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-11 02:34:56 +00:00
Bo Peng
a8e9fe82d0 lib/lyx2lyx/lyx_1_5.py: fix revert of listings insets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18262 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-11 02:28:14 +00:00
Bo Peng
ae9afa946a fix a listings param name
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18253 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-09 21:28:43 +00:00
Bo Peng
1038ed69e6 Fix InsetListings::init, call setButtonLabel explicitly because that function is not virtual
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18246 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-09 20:00:06 +00:00
Bo Peng
4ce743a0a7 Add support for listings package. Two listings command \lstinline, \lstinputlisting and an environment \lstlisting are supported, along with preamble \lstset. \lstinputlisting is implemented through Include dialog, and the other two are implemented with a new inset listings, along with its dialog.
* src/LyXAction.cpp: listing-insert action
	* src/insets/Inset.h,cpp: LISTINGS_CODE
	* src/insets/InsetInclude.cpp: handle \lstinputlisting
	* src/insets/InsetListings.h,cpp: new listings inset
	* src/insets/InsetListingsParams.h,cpp: parameters from listings package
	* src/insets/InsetCommandParams.h,cpp: handle lstinputlisting option
	* src/Bidi.cpp: handle LISTINGS_CODE
	* src/frontends/qt4/ui/TextLayoutUi.ui: update UI
	* src/frontends/qt4/ui/ListingsUi.ui: new dialog
	* src/frontends/qt4/ui/IncludeUi.ui: update UI
	* src/frontends/qt4/QInclude.h,cpp: add lstinputlisting
	* src/frontends/qt4/QDocument.h,cpp: add textedit for preamble listings_params
	* src/frontends/qt4/QListings.h,cpp: new listings inset
	* src/frontends/qt4/Dialogs.cpp: new listings dialog
	* src/frontends/controllers/ControlInclude.h,cpp: add lstinputlisting
	* src/frontends/controllers/ControlListings.h,cpp: new listings inset
	* src/LyXFunc.cpp: handle LISTING_CODE
	* src/Paragraph.cpp: handle LISTING_CODE
	* src/factory.cpp: new listings inset
	* src/CutAndPaste.cpp: handle LISTINGS_CODE
	* src/LaTeXFeatures.cpp: require listings
	* src/Text3.cpp: Handle LISTINGS_CODE
	* src/lfuns.h: add LFUN_LISTING_INSERT
	* src/Buffer.cpp: change lyx file format to 269
	* src/BufferParams.h,cpp: add listings_params to preamble
	* lib/lyx2lyx/LyX.py: lyx2lyx 
	* lib/lyx2lyx/lyx_1_5.py: lyx2lyx
	* lib/ui/stdmenus.inc: new menu item (no shortcut!)
	* src/insets/Makefile.am: update autotools
	* src/frontends/controllers/Makefile.am
	* src/frontends/qt4/Makefile.dialogs
	* src/frontends/qt4/Makefile.am
	* po/POTFILES.in: a few more translatable files.
	* development/scons/scons_manifest.py: scons build system
	* development/FORMAT: document format changes


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18243 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-09 19:11:42 +00:00
Jürgen Spitzmüller
410a946f1f * src/insets/InsetMarginal.h:
- revert accidental encoding change

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18189 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-03 15:54:56 +00:00
Jürgen Spitzmüller
6896eafabd * src/insets/InsetMarginal.h:
- add missing name() (fix bug 3540)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18188 a592a061-630c-0410-9148-cb99ea01b6c8
2007-05-03 15:53:14 +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
75637c0dd8 remove RowList_fwd.h. Not really needed
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18135 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-30 22:02:15 +00:00
Abdelrazak Younes
845feeabfc Fix bug 3186?
http://bugzilla.lyx.org/show_bug.cgi?id=3186

Caption outside float or long table will get the "Senseless!!" label.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18120 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-30 15:17:16 +00:00
Abdelrazak Younes
2640b21228 * Inset and derivatives: insetName() -> name()
* InsetMath::name(): deleted.

* buffer_funcs.cpp:setCaptions() fix potential bug by using docstring copy instead of reference while using Inset::name.





git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18119 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-30 14:39:09 +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
Michael Schmitt
295eea310e replace term "Glossary" by "Nomenclature"
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18102 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 22:21:00 +00:00
André Pönitz
6add1994c7 rename LyXTextClass* into TextClass*
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18097 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 19:53:54 +00:00
André Pönitz
0bf9ac02a8 rename LyXLayout into Layout
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18096 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 18:58:28 +00:00
André Pönitz
fc6ce7cd08 rename LyXFont to Font except in tex2lyx
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18095 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 18:17:15 +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
51fbea02a8 Remove InsetOld
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18087 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-29 12:32:14 +00:00
Bo Peng
e36fba33ab Last (?) batch of renames:
src/frontends/Alert.h src/frontends/alert.h
src/frontends/Alert.cpp src/frontends/alert.cpp
src/frontends/Alert_pimpl.cpp src/frontends/alert_pimpl.cpp
src/frontends/qt4/Alert_pimpl.cpp src/frontends/qt4/alert_pimpl.cpp
src/frontends/controllers/ButtonPolicies.cpp src/frontends/controllers/ButtonPolicy.cpp
src/frontends/controllers/ButtonPolicies.h src/frontends/controllers/ButtonPolicy.h
src/insets/InsetEnv.cpp src/insets/InsetEnvironment.cpp
src/insets/InsetEnv.h src/insets/InsetEnvironment.h
src/mathed/MathMacroTable.h src/mathed/MacroTable.h
src/mathed/MathMacroTable.cpp src/mathed/MacroTable.cpp
src/lyx_cb.h src/callback.h
src/lyx_cb.cpp src/callback.cpp
src/UpdateFlags.h src/update_flags.h


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18076 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-28 20:44:46 +00:00
André Pönitz
8c622e4ff0 rename/merge LyXLength related stuff
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18067 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-28 12:58:49 +00:00
Uwe Stöhr
82b70e9c64 File format change: Fix bug 1746 partly
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18052 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 21:40:51 +00:00
André Pönitz
5008ee540f rename LColor into Color
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18046 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 17:34:20 +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
ef1a53c492 merge LyXTabular.{cpp,h} and insets/InsetTabular.{cpp,h}. More reorganization necessary. Not now...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18036 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 12:54:21 +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
André Pönitz
345d7c00cd remove ParagraphList_fwd.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18030 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 08:30:11 +00:00
Bo Peng
bcc90ce1c9 Rename three remaining .C files
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18026 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 05:18:04 +00:00
Bo Peng
138b23fac8 Rename files in src/support, step one.
src/support/package.h                              src/support/Package.h    Package
src/support/package.C.in                           src/support/Package.C.in  Package
src/support/path.h                                 src/support/Path.h    Path
src/support/fs_extras.h                            src/support/fs_extras.h NOCLASSES
src/support/RandomAccessList.h                     src/support/RandomAccessList.h    RandomAccessList
src/support/lyxmanip.h                             src/support/lyxmanip.h NOCLASSES
src/support/rename.C                               src/support/rename.cpp  NOCLASSES
src/support/abort.C                                src/support/abort.cpp  NOCLASSES
src/support/lyxlib.h                               src/support/lyxlib.h NOCLASSES
src/support/ExceptionMessage.h                     src/support/ExceptionMessage.h    ExceptionMessage
src/support/copy.C                                 src/support/copy.cpp  NOCLASSES
src/support/limited_stack.h                        src/support/limited_stack.h    limited_stack
src/support/filefilterlist.C                       src/support/FileFilterList.cpp    ['FileFilterList', 'Filter']
src/support/cow_ptr.h                              src/support/cow_ptr.h    cow_ptr
src/support/os_unix.C                              src/support/os_unix.cpp  NOCLASSES
src/support/socktools.h                            src/support/socktools.h NOCLASSES
src/support/forkedcontr.h                          src/support/ForkedcallsController.h    ForkedcallsController
src/support/os.h                                   src/support/os.h NOCLASSES
src/support/FileMonitor.h                          src/support/FileMonitor.h    FileMonitor
src/support/copied_ptr.h                           src/support/copied_ptr.h    copied_ptr
src/support/translator.h                           src/support/Translator.h    Translator
src/support/filetools.C                            src/support/filetools.cpp  NOCLASSES
src/support/unlink.C                               src/support/unlink.cpp  NOCLASSES
src/support/os_win32.C                             src/support/os_win32.cpp    GetFolderPath
src/support/lstrings.C                             src/support/lstrings.cpp  NOCLASSES
src/support/qstring_helpers.C                      src/support/qstring_helpers.cpp  NOCLASSES
src/support/getcwd.C                               src/support/getcwd.cpp  NOCLASSES
src/support/systemcall.C                           src/support/Systemcall.cpp    Systemcall
src/support/lyxalgo.h                              src/support/lyxalgo.h NOCLASSES
src/support/filefilterlist.h                       src/support/FileFilterList.h    ['FileFilterList', 'Filter']
src/support/unicode.C                              src/support/unicode.cpp    IconvProcessor
src/support/userinfo.C                             src/support/userinfo.cpp  NOCLASSES
src/support/lyxtime.C                              src/support/lyxtime.cpp  NOCLASSES
src/support/kill.C                                 src/support/kill.cpp  NOCLASSES
src/support/docstring.C                            src/support/docstring.cpp    to_local8bit_failure
src/support/os_cygwin.C                            src/support/os_cygwin.cpp  NOCLASSES
src/support/lyxsum.C                               src/support/lyxsum.cpp  NOCLASSES
src/support/environment.C                          src/support/environment.cpp  NOCLASSES
src/support/filetools.h                            src/support/filetools.h NOCLASSES
src/support/textutils.C                            src/support/textutils.cpp  NOCLASSES
src/support/mkdir.C                                src/support/mkdir.cpp  NOCLASSES
src/support/forkedcall.C                           src/support/Forkedcall.cpp    ['ForkedProcess', 'Forkedcall']
src/support/tempname.C                             src/support/tempname.cpp  NOCLASSES
src/support/os_win32.h                             src/support/os_win32.h    GetFolderPath
src/support/types.h                                src/support/types.h NOCLASSES
src/support/lstrings.h                             src/support/lstrings.h NOCLASSES
src/support/forkedcallqueue.C                      src/support/ForkedCallQueue.cpp    ForkedCallQueue
src/support/qstring_helpers.h                      src/support/qstring_helpers.h NOCLASSES
src/support/convert.C                              src/support/convert.cpp  NOCLASSES
src/support/filename.C                             src/support/FileName.cpp    ['FileName', 'DocFileName']
src/support/tests/convert.C                        src/support/tests/convert.cpp  NOCLASSES
src/support/tests/filetools.C                      src/support/tests/filetools.cpp  NOCLASSES
src/support/tests/lstrings.C                       src/support/tests/lstrings.cpp  NOCLASSES
src/support/tests/boost.C                          src/support/tests/boost.cpp  NOCLASSES
src/support/docstream.C                            src/support/docstream.cpp    ['iconv_codecvt_facet_exception', 'idocfstream', 'odocfstream']
src/support/std_istream.h                          src/support/std_istream.h NOCLASSES
src/support/systemcall.h                           src/support/Systemcall.h    Systemcall
src/support/chdir.C                                src/support/chdir.cpp  NOCLASSES
src/support/std_ostream.h                          src/support/std_ostream.h NOCLASSES
src/support/unicode.h                              src/support/unicode.h    IconvProcessor
src/support/path.C                                 src/support/Path.cpp    Path
src/support/fs_extras.C                            src/support/fs_extras.cpp  NOCLASSES
src/support/userinfo.h                             src/support/userinfo.h NOCLASSES
src/support/lyxtime.h                              src/support/lyxtime.h NOCLASSES
src/support/docstring.h                            src/support/docstring.h    to_local8bit_failure
src/support/debugstream.h                          src/support/debugstream.h    basic_debugstream
src/support/environment.h                          src/support/environment.h NOCLASSES
src/support/textutils.h                            src/support/textutils.h NOCLASSES
src/support/forkedcall.h                           src/support/Forkedcall.h    ['ForkedProcess', 'Forkedcall']
src/support/socktools.C                            src/support/socktools.cpp  NOCLASSES
src/support/forkedcallqueue.h                      src/support/ForkedCallQueue.h    ForkedCallQueue
src/support/forkedcontr.C                          src/support/ForkedcallsController.cpp    ForkedcallsController
src/support/os.C                                   src/support/os.cpp  NOCLASSES
src/support/convert.h                              src/support/convert.h NOCLASSES
src/support/filename.h                             src/support/FileName.h    ['FileName', 'DocFileName']
src/support/docstream.h                            src/support/docstream.h    ['iconv_codecvt_facet_exception', 'idocfstream', 'odocfstream']
src/support/FileMonitor.C                          src/support/FileMonitor.cpp    FileMonitor



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18024 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-26 05:12:52 +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
f6ab280632 merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17998 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-25 17:53:54 +00:00
Bo Peng
65d89a8af3 merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 1
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17996 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-25 17:15:56 +00:00
Bo Peng
176715bd56 Fix a few rename inconsistencies discovered by JMarc in insets and mathed, step 2
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17992 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-25 16:12:54 +00:00
Bo Peng
6e3a75969b Fix a few rename inconsistencies discovered by JMarc in insets and mathed, step 1
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17991 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-25 16:11:45 +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
Bo Peng
b6a2a76700 Rename insets/insetxxx to insets/InsetXxx, part 1
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17964 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-25 01:24:38 +00:00
Michael Schmitt
bb98a39589 * src/insets/insetcommandparams.C: fix WS
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17928 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-23 19:34:09 +00:00
Richard Heck
05ba87fe7a Fix case of BibTeX keys and remove unused variable. By myself and Bernhard.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17919 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-23 15:18:01 +00:00
Abdelrazak Younes
bc92746781 * In the process of fixing the math background color bug, this commit transfer backgroundColor() management from InsetOld to InsetBase; because this will be needed for InsetMath based insets.
* Also transfer InsetBase ctors from .h to .C


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17913 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-22 21:40:10 +00:00
Abdelrazak Younes
24c8ca10d2 Trying to solve bug-2452, I optimized some of the most significant problems outlined in the profile report attached in there.
This commit avoids unnecessary metrics recalculations by caching the last LyXFont used. I had to cleanup the width(), ascent() and descend() redundancies by transferring that to InsetBase.

InsetMathDim should go now as it is not really needed.

* InsetBase: properly handle inset Dimension.

* InsetOld: get rid of redundant width(), ascent() and descent()

* InsetMathDim: ditto

* InsetMathChar::metrics(): avoid metrics recalculation if font is unchanged.

* InsetMathSymbol::metrics(): ditto

* InsetMathKern: use InsetBase::dim_ instead of local ones.

* InsetMathSpace:
  - use InsetBase::dim_ instead of local ones.
  - space to width transformation transferred to anonymous namespace.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17899 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-22 08:26:06 +00:00
Jürgen Spitzmüller
bba7ac2a66 Fix bug 2884 and 3437:
* src/insets/insetbase.h:
* src/insets/insetcollapsable.h:
	- make isFixedWidth (former insetcollapsable member) a member of insetbase.
src/insets/insettext.h:
	- make border_ public (needed by insetcollapsable).
src/insets/insettext.C (draw, drawSelection):
	- adjust drawing for fixed width insets
* src/insets/insetcollapsable.C (metrics):
	- adjust dimension for fixed width insets
src/insets/insetbox.C (metrics):
	- properly calculate metrics for fixed width insets.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17879 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-21 08:43:46 +00:00
Abdelrazak Younes
08380ca491 Fix bug 3454 and 3463: Don't allow ill-formed commands. With this commit an error dialog will be shown to the user if the inset parameters were wrong upon creation. This patch uses exceptions.
* factory.C::createInset(): catch eventual exception.
* InsetCommandParams::read(): throw warning exception in case of errors.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17850 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-18 12:59:07 +00:00
Bo Peng
7a854d3a91 Fix bug 2993: mark buffer dirty when the status of a collapsable inset is changed
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17837 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-17 14:35:27 +00:00
Richard Heck
840ee198e2 Captions do not accept alignment, spacing, etc.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17834 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-17 03:46:55 +00:00
Georg Baum
ed781c2afe prevent the compiler from optimiying away support::Path variables
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17751 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-06 18:03:29 +00:00