Commit Graph

4059 Commits

Author SHA1 Message Date
Richard Heck
2b067ed466 Constness.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35913 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 17:08:31 +00:00
Jürgen Spitzmüller
3381784318 fix #6998. Center alignment is the default, also with multirow.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35912 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 17:02:01 +00:00
Richard Heck
91b4afa3c1 This has to be delayed, since otherwise it provides the command before
the user gets to do so.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35907 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 14:31:52 +00:00
Richard Heck
16a1c042ef Fix prettyref output.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35906 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 13:07:05 +00:00
Jürgen Spitzmüller
40f06a50de * InsetTabular.cpp: simplification; no change in functionality.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35902 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 11:33:48 +00:00
Jürgen Spitzmüller
ec1fd2a860 * InsetTabular.cpp: simplification; no change in functionality.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35899 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 10:15:50 +00:00
Uwe Stöhr
fadde98eb3 InsetTabular: implement some SET/UNSET functions as prerequisite to fix #6985
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35897 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 04:09:49 +00:00
Uwe Stöhr
c378fede8b InsetTabular.cpp: fix #6585 also for wrapped floats - thanks Vincent
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35895 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 01:29:53 +00:00
Uwe Stöhr
a0b84e0ba0 GuiTabular.cpp: fix #6585
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35894 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 01:18:18 +00:00
Vincent van Ravesteijn
2bbf8e5f2d Remove InsetCommand::mailer_name_.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35893 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 00:46:21 +00:00
Vincent van Ravesteijn
c5b9664476 Remove the name parameter from string2params and params2string. We can always derive the name with insetName(params.code()).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35891 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-29 00:25:28 +00:00
Richard Heck
c4faeb75db Comments mostly.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35885 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-28 16:28:57 +00:00
Richard Heck
1fbddcb149 Change the way we output formatted references under refstyle to avoid
some problems with the previous \\lyxref macro.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35882 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-28 15:15:14 +00:00
Vincent van Ravesteijn
6d82aacf48 Remove InsetRef::isLatex. This no longer needed as we always can access the Buffer nowadays from the Inset.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35874 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-27 22:34:18 +00:00
Vincent van Ravesteijn
c75d667e78 Organize header files in src\insets.
- Functions that inherit from the same baseclass are grouped together with a command;
- Functions that inherit should not have a doxy entry;
- Other functions are also grouped together as much as possible;
- Some function don't need to be implemented if they return the same as the baseclass;
- and more.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35873 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-27 21:35:13 +00:00
Vincent van Ravesteijn
07924ac300 Remove some unnecessary static_casts and add two FIXMEs about casts that don't look safe.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35856 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-26 16:45:21 +00:00
Vincent van Ravesteijn
573500dd04 Remove unneccessary uses of dynamic_cast from the code.
A dynamic_cast is necessary when:

- the object to be casted is from an external library because we can't add Qxxx::asXxxx() to Qt e.g.:
    * QAbstractListModel to GuiIdListModel,
    * QValidator to PathValidator,
    * QWidget to TabWorkArea,
    * QWidget to GuiWorkArea;

- the object is to be casted from an interface to the implementing class, because the Interface does not know by whom it is implemented:
    * ProgressInterface to GuiProgress,
    * Application to GuiApplication.

A dynamic_cast can be replaced by:
  - already existing as***Inset() functions, e.g.:
    * asHullInset(),
    * asInsetMath()->asMacro(),
    * asInsetText();

  - a static_cast when we are sure this can't go wrong, e.g.:
    * we are sure that CellData::inset->clone() is an InsetTableCell,
    * in cases where we explicitly check it->lyxCode().


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35855 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-26 15:03:51 +00:00
Uwe Stöhr
dbe3d79e15 InsetTabular.cpp: remove comment, we already discussed this and the star as default was the result
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35847 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-26 02:02:10 +00:00
Vincent van Ravesteijn
8693ae474b Proper implementatiom of isInToc()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35846 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-26 01:10:19 +00:00
Vincent van Ravesteijn
2e42a7b645 We don't want InsetCommand to have a function updateCommand while this is not a special function of an InsetCommand, but only accidentally a shared function of two children. So, in this case I think we should just (dynamically) cast these objecten and call their own insetCommand function.
This also fixes compilation again. I forgot to cherry-pick all commits in git ;)...

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35845 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 23:20:05 +00:00
Uwe Stöhr
b7764dbe42 InsetCommand.h: revert my last commit - makes it worse than it helps as quick workaround
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35843 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 22:13:52 +00:00
Uwe Stöhr
8a4933f250 InsetCommand.h: reintroduce updateCommand from r35840 to make it compilable (this void is used in CutAndPaste.cpp); Vincent, can you please have a look?
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35842 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 21:51:28 +00:00
Vincent van Ravesteijn
6e0f8f89b0 InsetCommand.h: Reorder and add comments.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35840 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 20:20:44 +00:00
Vincent van Ravesteijn
f270358904 Correct toc to floatlist
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35839 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 19:53:40 +00:00
Vincent van Ravesteijn
75773f3c22 Use Buffer::ReadStatus as a return value for Buffer::loadLyXFile.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35818 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 10:18:42 +00:00
Stephan Witt
a2c998d5d0 avoid warnings for unused parameters
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35816 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 08:12:01 +00:00
Vincent van Ravesteijn
ba19e8b5dd Fix bug #1839: Ctrl+arrows don't move to next/prev table cell.
Patch from Punyashloka Biswal.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35812 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-25 01:18:48 +00:00
Pavel Sanda
0590c77d47 gcc spits out million warnings
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35807 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-24 21:46:28 +00:00
Vincent van Ravesteijn
72a93582b0 Add virtual bool Inset::clickable(..) to be used to change the cursor.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35804 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-24 20:11:40 +00:00
Vincent van Ravesteijn
72569c42ba Implement mouse hovering for InsetExternal.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35803 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-24 19:25:36 +00:00
Vincent van Ravesteijn
a77d991e24 setMouseHover() functions can be const.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35802 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-24 19:24:36 +00:00
Richard Heck
5aba6f4fab Make this a switch.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35758 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-21 18:01:06 +00:00
Richard Heck
bfa9991f93 Fix bug #6962. I hadn't see how these were being escaped.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35757 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-21 17:56:00 +00:00
Jürgen Spitzmüller
2cf666e3cd * InsetCommandParams.cpp (prepareCommand):
- properly terminate LaTeX macros (reported in bug 6959). 

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35746 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-21 13:16:28 +00:00
Vincent van Ravesteijn
152491f916 Some cosmetics (from my local cosmetics branch).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35708 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-18 14:20:03 +00:00
Richard Heck
4ff48f1d54 Need ifthen for this, too.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35647 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-14 14:02:49 +00:00
Richard Heck
85904c550d Add ResetsFont tag to InsetLayout, toward fixing bug #5657.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35626 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-13 15:54:39 +00:00
Richard Heck
01013c0785 Refstyle support. The user can now choose between prettyref and restyle
for formatted references. Fixes #2295, in so far as it makes it possible
to translate formatted references.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35623 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-13 12:36:53 +00:00
Richard Heck
2a63b2d1cb Customize getLayout for InsetFlex and change how we report name() back
to the simple version. We need to do it this way because we should NOT
really require the "Flex" prefix and, in fact, should permit other
prefixes to be used. Next commit for that.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35613 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-12 15:37:02 +00:00
Richard Heck
226853c060 style
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35611 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-12 15:07:27 +00:00
Richard Heck
d4634167cc Get rid of "CharStyle:", "Custom:", and "Element:" prefixes, per a
suggestion of JMarc's. Docs to follow.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35608 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-12 14:46:17 +00:00
Uwe Stöhr
e8a1fed47c InsetBibtex.cpp:
- fix #1881, fileformat change
- fix #6470

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35590 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-11 01:05:20 +00:00
Uwe Stöhr
5606b7d875 InsetBibitem.cpp: fix #5786
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35582 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-09 16:02:19 +00:00
Uwe Stöhr
27423f93ba InsetTabular.cpp: fix #6907, patch by goriccardo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35561 a592a061-630c-0410-9148-cb99ea01b6c8
2010-10-05 01:14:34 +00:00
Uwe Stöhr
03a2216981 InsetGraphics.cpp and InsetInclude.cpp: whitespace fixes
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35517 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-27 03:21:59 +00:00
Uwe Stöhr
b33182bc3d filetools.cpp: introduce a new method to be able to distinguish between valid LaTeX filenames and filenames causing troubles on some DVI viewers.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35514 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-27 02:39:22 +00:00
Pavel Sanda
f2c388a519 Allow InsetPreview in no math preview mode.
Patch from Ronen Abravanel
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg161966.html

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35456 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-19 22:33:55 +00:00
Pavel Sanda
65962da47b Add support for feyn package and Diagram inset.
Patch from Ronen Abravanel.
http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg161952.html

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35455 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-19 22:12:06 +00:00
Jürgen Spitzmüller
0b17cb1135 * ExternalSupport.cpp:
- do not popup invalid path warning with View Source (bug 6904).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35449 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-19 16:30:17 +00:00
Uwe Stöhr
3a400812e1 InsetLine.h revert changes made in r35417
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35428 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-17 23:12:19 +00:00
Uwe Stöhr
92c8604313 InsetLine:
- honor Abdel as author
- reintroduce the /// spacers in the header file because it makes it better readable and we do this in all other inset header files

GuiLine: honor Abdel as author

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35417 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-17 01:28:08 +00:00
Abdelrazak Younes
17ab5f5a38 InsetLine: Fix vertical positioning, offset is really an offset from the
text baseline, not from the middle of the line.

We are now getting much closer to LateX drawing...


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35413 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-16 10:40:19 +00:00
Abdelrazak Younes
3b512d5915 header cleanup and doxy.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35412 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-16 10:14:46 +00:00
Abdelrazak Younes
31c75d260e Remove uneeded hack.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35411 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-16 09:49:43 +00:00
Abdelrazak Younes
08453ceba4 Fix InsetLine painting for exotic offset and heigth.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35407 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-16 07:36:20 +00:00
Richard Heck
fbc092639c Part of #6893.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35389 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-15 13:51:06 +00:00
Richard Heck
b5d2e9d285 Fix output of HTML tags in bibliography info.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35388 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-15 13:50:17 +00:00
Richard Heck
7f0b1d1cbb Fix i18n for InsetBibtex.
It would be better to get the paragraph language here. How to do that?


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35386 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-15 13:28:55 +00:00
Abdelrazak Younes
c01de9fd41 * add InsetLine::dimension() to avoid calling InsetCommand::dimension()
* InsetLine::draw() bit of code shuffling.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35384 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-15 12:43:07 +00:00
Abdelrazak Younes
15679c3e82 revert r35374 and further improve the metrics and drawing code.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35377 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-15 11:19:29 +00:00
Richard Heck
14015ec434 Void functions don't return things. ;-)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35376 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-15 01:03:13 +00:00
Uwe Stöhr
573abee2b5 InsetLine.cpp: correct coding style
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35375 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-14 23:35:12 +00:00
Uwe Stöhr
e33e3dd815 InsetLine.cpp: restore the drawing routine after r35373, see http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg161800.html
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35374 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-14 23:24:57 +00:00
Abdelrazak Younes
d1f08cbc57 Fix InsetLine metrics and drawing.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35373 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-14 14:56:41 +00:00
Abdelrazak Younes
24ff65acc4 coding style and C++ fixes.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35370 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-14 13:42:09 +00:00
Stephan Witt
c4d00e85eb implement isChar() in header like all other insets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35368 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-14 12:39:33 +00:00
Abdelrazak Younes
d8981b13ae * Get rid of LFUN_TOC_INSERT: we use LFUN_INSET_INSERT "toc".
* Fix usage of "inset-insert type" without CommandInset arguments.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35345 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-12 07:56:08 +00:00
Jean-Marc Lasgouttes
e54376ebd6 There was no need to use ColorChanger after all :)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35334 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-09 13:15:25 +00:00
Jean-Marc Lasgouttes
2d278665dc When selecting, get the label color of caption inset right.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35332 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-09 13:03:26 +00:00
Pavel Sanda
2d8ee8973f Commit clash, Abdel just fixed it another way.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35318 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-07 13:43:10 +00:00
Pavel Sanda
01eb99ea4d Compilation fix for 'abs'
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35317 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-07 13:40:03 +00:00
Abdelrazak Younes
0b7886a1a8 Gcc compile fix. abs is defined for float not int.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35316 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-07 13:37:22 +00:00
Pavel Sanda
d179943b8f Squash warning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35305 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-07 11:00:01 +00:00
Uwe Stöhr
604a3341d9 InsetLine.cpp: remove unused include
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35300 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-07 00:49:00 +00:00
Uwe Stöhr
0e7ab29f49 InsetLine: support for the LaTeX command \rule; kick out the hardcoded \lyxline; fileformat change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35299 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-07 00:41:00 +00:00
Uwe Stöhr
59d550f894 InsetLine.cpp: fix #6863: use text color also for lines within LyX
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35286 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-05 23:27:55 +00:00
Uwe Stöhr
bbafadcbf3 InsetLine.cpp: compile fix for r35283
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35285 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-05 17:18:23 +00:00
Jean-Marc Lasgouttes
d71281d4ae MetricsInfo::textColor: helper function that helps taking in account the
selection and chage tracking state

InsetTabular::drawCellLines: use the above function to draw properly tabular lines after a selection. 

This method can be used easily for other insets.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35268 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-02 12:13:54 +00:00
Jean-Marc Lasgouttes
15832da56d Header cleanup (remove uneeded declarations)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35266 a592a061-630c-0410-9148-cb99ea01b6c8
2010-09-02 10:26:34 +00:00
Pavel Sanda
433830cdc0 Corners of collapsable insets to be painted via Color_foreground,
not labelColor(). In default theme this makes no change.

http://www.mail-archive.com/lyx-devel@lists.lyx.org/msg161461.html



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35233 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-30 00:02:10 +00:00
Pavel Sanda
b1d6406ac4 Learn URL viewing for hyperlink insets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35232 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-29 23:04:36 +00:00
Jürgen Spitzmüller
435067c0f1 * InsetHyperlink.{cpp,h}:
* stdcontext.inc:
	- basic implementation of inset-edit (only for file: now) (part of bug #6864)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35230 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-29 17:23:35 +00:00
Jürgen Spitzmüller
d427010975 * InsetHyperlink.{cpp,h}:
* stdcontext.inc:
	- basic context menu and tooltip (part of bug #6864)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35229 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-29 16:40:52 +00:00
Uwe Stöhr
fab03729ab InsetLine.cpp: use text color also for lyxlines
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35191 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-25 01:59:14 +00:00
Uwe Stöhr
7d68833dc9 remove unused include of FuncRequest
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35189 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-24 03:07:09 +00:00
Uwe Stöhr
c3b341cbcb InsetCaption: we use IndianRad as frame color while the float frames use DarkRed; as discussed, providing to specify a special caption frame color in the preferences is unnecessary
-> remove caption frame color from preferences
-> use the collapsible frame color also for caption frames

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35187 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-24 01:29:22 +00:00
Uwe Stöhr
38ed6cd1a0 \lyxline is a LyX-specific macro that creates a line in the output
- this line is defined with a width of 1pt -> therefore also draw it in this size in lyx
- this line is by default black -> use black
- setting a color for this in the preferences is wrong and senseless, because the color of this line is defined by the color chosen in the text style dialog -> remove preference color

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35185 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-24 01:13:26 +00:00
Jürgen Spitzmüller
f2f3ed23f0 * InsetTabular.cpp: do not attempt to access an empty DocIterator (bug 6810).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35148 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-14 14:32:52 +00:00
Uwe Stöhr
5f62c2ed6a InsetGraphics.cpp: fix a comment
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35131 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-13 00:17:12 +00:00
Richard Heck
06b1525f7d buffer_ --> buffer()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35117 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-10 14:44:59 +00:00
Richard Heck
700c3dc0ef loadIfNeeded() returns a pointer to the loaded child, so it's silly to
throw away its return value and then go find a pointer to the loaded
child!!


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35116 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-10 14:39:12 +00:00
Richard Heck
b28eca7476 buffer_ --> buffer()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35114 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-10 14:28:24 +00:00
Richard Heck
2203d7aa0a Fix some bugs in the bibinfo caching mechanism. Comments to follow.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35112 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-10 14:12:48 +00:00
Richard Heck
0ac2636d28 Missing invalidations of bibfile cache.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35111 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-09 21:35:44 +00:00
Jean-Marc Lasgouttes
6aa26820fd Introduce new tag ParbreakIsNewline in Layout and InsetLayout (not yet used)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35110 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-09 21:20:29 +00:00
Richard Heck
350b82fd62 Revert r35106.
Help needed here. Why isn't this equivalent?


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35108 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-09 19:17:44 +00:00
Richard Heck
35f3f7cbc4 Don't need this argument, since it was only ever called thus:
it->fillWithBibKeys(d->bibinfo_, it);
This could be useful later, if we decide to try to do the work that
fillWithBibKeys did from updateLabels().


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35106 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-09 18:00:46 +00:00
Richard Heck
506716a1d2 Change error message. Reason why appears later.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35105 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-09 17:33:43 +00:00
Richard Heck
e992140685 More work toward speeding up the bibfile caching stuff.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35103 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-09 17:01:51 +00:00
Jean-Marc Lasgouttes
c77b7483ea fix oversight
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35092 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-08 14:34:59 +00:00
Jean-Marc Lasgouttes
1a18cdfb39 Clean-up the code with respect to PassThru insets and layouts.
The goal is first to remove explicit testing against ERT_CODE, 
and second to allow to define layouts with the same properties as ERT insets.

This commit does not change behaviour 
* rename OutputParams::verbatim to pass_thru
* disable encoding switch inside pass_thru layouts



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35091 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-07 22:07:49 +00:00
Uwe Stöhr
7547cf9e5f - InsetTabular.cpp: floats must not be inserted to tables, fixes #6844
- InsetCaption.cpp: margin notes and footnotes are not allowed in captions

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35073 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-07 03:16:38 +00:00
Richard Heck
87600d4d84 Remove unused variables, add questions. Anyone know?
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35058 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-05 20:25:29 +00:00
Richard Heck
23a984b258 Style and a sanity check.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35039 a592a061-630c-0410-9148-cb99ea01b6c8
2010-08-02 15:40:33 +00:00
Richard Heck
1c0514b07c Add a comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35036 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-30 15:50:42 +00:00
Richard Heck
e48fb0b661 Allow images to be export even when LyXRC says no previews.
I'll try to figure out how to get rid of the magic booleans.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35022 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-29 15:17:58 +00:00
Richard Heck
b8d43b05bc Support for exporting math as images with XHTML. The next step is to
allow this as a fallback. E.g., if we're unable to export as MathML,
then we try to export as an image.

There are several ways, I am sure, in which this implementation is not
ideal.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34993 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-21 13:19:52 +00:00
Richard Heck
7d4c560f87 Remove Nameref support. Too many issues involving translation, quotes,
etc.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34920 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-16 15:19:04 +00:00
Richard Heck
47db764ccc Nameref support.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34884 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-13 03:23:29 +00:00
Richard Heck
5577e877bb Try to move all updateBuffer() calls to a central location. We now use
DispatchResult to store a flag that tells us whether we need a buffer
update or not. 

So: If you find a missing one, go to an appropriate place in the
dispatch and call cur.forceBufferUpdate() or, if you don't have a cursor
but do have a DispatchResult, call dr.forceBufferUpdate().

There is one remaining call I could not move, in
TextMetrics::redoParagraph. But this looks like an emergency call when
the macro context has not been set. There are also a couple calls that
are connected with buffer creation that I commented out, since the same
call is done again almost immediately. But I'm not positive about those.

Now the nice thing would be to do the same for updateMacros().


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34826 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-09 14:37:00 +00:00
Richard Heck
0e14f379f3 Rename a couple routines. This will avoid confusion with a forthcoming
patch.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34816 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-08 20:04:35 +00:00
Uwe Stöhr
07e8f2e1bc InsetBox.cpp: only shaded boxes can have a non-plain layout when there is no inner box
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34809 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-08 03:01:50 +00:00
Uwe Stöhr
142caff833 InsetBox.cpp: only shaded boxes can have multiple paragraphs when there is no inner box
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34808 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-08 02:42:36 +00:00
Uwe Stöhr
ebcef496a5 - new support for makebox; fileformat change
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34748 a592a061-630c-0410-9148-cb99ea01b6c8
2010-07-03 13:14:15 +00:00
Peter Kümmel
615d42d357 TR1: use std::tr1 regex with msvc10
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34725 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-29 17:09:40 +00:00
Vincent van Ravesteijn
7f593196fc Add an update parameter to BufferView::scrollToCursor and BufferView::scrollDocView. This parameter indicates whether a repaint is requested
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34658 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-14 21:48:23 +00:00
Jürgen Spitzmüller
aab87ddb8f * InsetIndex.cpp (validate):
- fall through to InsetCollapsable (bug #6715)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34654 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-14 14:10:07 +00:00
Jürgen Spitzmüller
143ea9b490 * InsetListings.cpp:
- do not switch the encoding with XeTeX (bug #6766)
	- some minor formatting

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34649 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-14 12:13:36 +00:00
Edwin Leuven
c2e4c79f6e bit of cleanup to avoid ambiguities (in the sense of cell vs column)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34648 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-14 10:42:42 +00:00
Edwin Leuven
7b51fb74a7 columnWidth returns the col width of a cell, which is not what we want here (should fix tables flying of the screen)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34647 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-13 20:27:28 +00:00
Edwin Leuven
b031ac1e66 do not use cells without decimals when calculating column widths and cell text offsets
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34645 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-12 16:44:50 +00:00
Jean-Marc Lasgouttes
df62af4323 fix warnings
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34630 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-08 13:38:12 +00:00
Richard Heck
0345bef67b Renaming: \\begin_inset OptArg to \\begin_inset Argument.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34619 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-07 21:58:27 +00:00
Vincent van Ravesteijn
abbfb45998 Fix bug #6751: Assert when changing number of columns in 'simple' math-inset.
In r33495, "LFUN_TABULAR_FEATURE" was replaced by "LFUN_INSET_MODIFY tabular". However, the status of LFUN_INSET_MODIFY is always enabled while a lot of insets are not allowed to change the number of columns etc.

There we need to disable the "LFUN_INSET_MODIFY tabular" status.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34613 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-07 20:54:10 +00:00
Edwin Leuven
fea446303d simplify some conditions
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34611 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-07 09:39:04 +00:00
Edwin Leuven
0ebe0ff37e add support for decimal alignment in tables
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34598 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-05 07:44:44 +00:00
Richard Heck
319ca06167 Rename LFUN_OPTIONAL_INSERT as LFUN_ARGUMENT_INSERT.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34597 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-04 22:53:44 +00:00
Richard Heck
8480d1dd9a Rename InsetOptArg as InsetArgument.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34596 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-04 22:44:58 +00:00
Richard Heck
b0097bcddb Introduce a new "RequiredArgs" tag for layouts. This functions much as
the OptionalArgs tag does and is implemented by the now misnamed
InsetOptArgs, except that its content gets wrapped in "{}" rather than
"[]". Required arguments do not actually have to be provided, but they
are always output. 

This will allow e.g. beamer's Block environment to be implemented
without ERT.

Documentation to follow.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34591 a592a061-630c-0410-9148-cb99ea01b6c8
2010-06-04 21:50:08 +00:00
Uwe Stöhr
0176f8e04c InsetBox.cpp: fix #4776; the additional \makebox is superfluous because \makebox and \framebox are equivalent, except that the latter draws a frame
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34472 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-23 18:13:23 +00:00
Enrico Forestieri
604ed2571f Fix bug #6712: LyX 2 does not restore encoding after a text inset
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34456 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-22 22:42:32 +00:00
Uwe Stöhr
edd8a321bf InsetRef.h: fix #6711
Also OK for branch?

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34450 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-22 02:01:47 +00:00
Uwe Stöhr
634a00c9db Inset***.h: fix typo in comment
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34449 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-22 02:00:41 +00:00
Jean-Marc Lasgouttes
edc0ec3fab fix bugs #6696 and #6697
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34434 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-18 13:59:59 +00:00
Jean-Marc Lasgouttes
033c2a9468 fix warning
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34392 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-10 12:34:34 +00:00
Vincent van Ravesteijn
5e978cf02c Disallow InsetMarginals in InsetTabulars.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34373 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-05 21:15:15 +00:00
Vincent van Ravesteijn
351808718d Fix another crash due to BufferView::last_inset_ being an invalid pointer.
Do not clear the mouse_hover state from anywhere else then BufferView, such that the last_inset_ pointer gets nulled. Besides, there is no reason to clear the mouse_hover state on collapsing the Inset.

See also r33908, r34117, r34348, r34353, r34354 and bug #3900.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34364 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-03 23:01:47 +00:00
Vincent van Ravesteijn
49920e31d6 Another non-base class with a virtual destructor. Sorry for the spam (trying to learn git, but I seem to forget files :).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34363 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-03 22:57:28 +00:00
Vincent van Ravesteijn
c9e4d6657d These should not raise the impression that children should reimplement these functions.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34361 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-03 22:18:00 +00:00
Vincent van Ravesteijn
cea7948698 Make destructors virtual in base classes and only there.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34360 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-03 21:43:46 +00:00
Vincent van Ravesteijn
8c0194ae78 Add comment just as in GuiView.cpp.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34359 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-03 20:08:31 +00:00
Vincent van Ravesteijn
eb78affda7 We want to check for the new value name instead for the old value cmdName_.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34358 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-03 17:55:44 +00:00
Vincent van Ravesteijn
9c8e7429fa Fix the assertion assert introduced in r34348 which got fired when eg. deselecting an InsetCommand:
- we have to have a copy constructor in InsetCommand to clear the mouse_hover_ map and not to copy it,
- there is no need to have mouse_hover_() in the initialisation list,
- there is no need to copy the auto_open_ map.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34353 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-01 23:04:08 +00:00
Enrico Forestieri
60466235fe Avoid compiler warning about unused parameter.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34352 a592a061-630c-0410-9148-cb99ea01b6c8
2010-05-01 11:38:05 +00:00
Vincent van Ravesteijn
d7b4aacb2e Compile fix for r34348.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34349 a592a061-630c-0410-9148-cb99ea01b6c8
2010-04-30 15:37:19 +00:00
Vincent van Ravesteijn
708b73cab7 Fix bug #3900: Mathed corners displayed without mouse hover.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34348 a592a061-630c-0410-9148-cb99ea01b6c8
2010-04-30 14:55:37 +00:00
Vincent van Ravesteijn
4c611e5745 Mouse hover property should be dependent on the specific bufferview. If there are 2 views showing the same buffer, an Inset can be shown as hovered in only one view.
This is also in preparation of a decent fix for bug #3900.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34347 a592a061-630c-0410-9148-cb99ea01b6c8
2010-04-30 14:47:46 +00:00
Vincent van Ravesteijn
0833a4a94c Fix bug #6677: GUI button disappears in external template inset.
Initialize the preview_mode variable.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34346 a592a061-630c-0410-9148-cb99ea01b6c8
2010-04-30 14:11:46 +00:00
Pavel Sanda
b3870eac50 typo
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34338 a592a061-630c-0410-9148-cb99ea01b6c8
2010-04-28 21:50:06 +00:00
Pavel Sanda
11e7cc2344 Unify QQaud strings.
Inside math toolbars we use "Quadratin". Dunno if this difference is intention.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34336 a592a061-630c-0410-9148-cb99ea01b6c8
2010-04-28 21:48:08 +00:00