Commit Graph

385 Commits

Author SHA1 Message Date
Richard Heck
2bb93b6c54 Update layout format.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25881 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-25 16:33:04 +00:00
Richard Heck
56a35c2c61 Add UseModule tag for layout files. This allows the AMS files, in particular, to "require" the
theorems-ams module, which is what most users will want. A later commit will allow users also
to "exclude" this module, in case they wanted to do that.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25880 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-25 15:51:27 +00:00
Richard Heck
2aa40fe939 Don't define the proof environment if it's already defined.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25877 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-24 22:28:57 +00:00
Richard Heck
0e69b297d6 Whitespace.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25876 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-24 22:21:30 +00:00
Jürgen Spitzmüller
459c52059f * theorems-ams.inc:
* theorems.inc:
	- better definition of cases environment, as suggested by Russ Woodroofe and Paul Rubin.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25699 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-18 07:53:25 +00:00
Jürgen Spitzmüller
180121ed53 * stdinsets.inc:
- Force latex_language in listings inset (fixes bug 5051).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25676 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-16 20:40:05 +00:00
Jürgen Spitzmüller
50cef47fbb * lyxmacros.inc:
* beamer.layout:
	- let lyxcode start a new paragraph, since it changes the alignment.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25627 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-15 08:49:41 +00:00
Uwe Stöhr
61330b8291 minimalistic.module: correct string as the translators misunderstood this.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25574 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-13 11:53:42 +00:00
Pavel Sanda
6119906dc0 Add some comments to modules.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25502 a592a061-630c-0410-9148-cb99ea01b6c8
2008-07-07 22:59:40 +00:00
Jürgen Spitzmüller
d2969c7dc9 Some updates for the A&A layout (bug 4928).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25210 a592a061-630c-0410-9148-cb99ea01b6c8
2008-06-09 14:26:54 +00:00
Jürgen Spitzmüller
03e91b088d fix bug 4925.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25149 a592a061-630c-0410-9148-cb99ea01b6c8
2008-06-05 19:22:47 +00:00
Jürgen Spitzmüller
ef9d8927c7 * New layout and template files for the Journal of Statistical Software (JSS), contributed by Andreas Karlsson
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25045 a592a061-630c-0410-9148-cb99ea01b6c8
2008-06-01 08:58:25 +00:00
Richard Heck
1f8d6daee4 Revert previous commit.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25013 a592a061-630c-0410-9148-cb99ea01b6c8
2008-05-30 14:59:28 +00:00
Richard Heck
43c7e56ef2 Work around an incompatibility between paper.cls and how we handle environments. The paper class seems to expect a pair of newlines are the end of the abstract envirnoment, which we do not produce; this has the effect that the abstract runs into the first paragraph in certain cases.
Jurgen, this could also go into branch.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24965 a592a061-630c-0410-9148-cb99ea01b6c8
2008-05-27 16:22:25 +00:00
Jürgen Spitzmüller
a90b442f69 * apa.layout: revert some unintended changes.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24695 a592a061-630c-0410-9148-cb99ea01b6c8
2008-05-09 09:03:36 +00:00
Jürgen Spitzmüller
7d5fd32778 * lib/layouts/apa.layout:
- Use styleguide-conforming headings in the APA layout (bug 4827).

* src/Buffer.cpp:
	- file format change to 333.

* lib/lyx2lyx/lyx_1_6.py:
	- convert obsoleted layouts.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24694 a592a061-630c-0410-9148-cb99ea01b6c8
2008-05-09 08:57:32 +00:00
Jürgen Spitzmüller
088f6f5f9e * lib/layouts/theorems-starred-equivalents.inc:
- Fix LaTeX errors triggered by switching from ams article to ams plain
  	  article (patch by Paul Rubin and me).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24692 a592a061-630c-0410-9148-cb99ea01b6c8
2008-05-09 08:01:37 +00:00
Jürgen Spitzmüller
ff0e3cd8b2 * fix translation of module descriptions that have a backslash (bug 4799).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24517 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-27 09:27:50 +00:00
Jean-Marc Lasgouttes
25b9bc9a38 fix on-screen counter for Section in article (AMS)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24484 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-24 07:32:51 +00:00
Richard Heck
a8f13b250d Endnote is multi paragraph.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24450 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-22 17:52:49 +00:00
Jürgen Spitzmüller
de04d11b9d * beamer.layout:
- custom insets for presentation/article mode.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24440 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-22 09:13:07 +00:00
Jürgen Spitzmüller
87a1bb5f58 * beamer.layout: Categorization.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24377 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-20 10:02:20 +00:00
Jürgen Spitzmüller
04a719f4a7 * lib/layouts/article-beamer.layout:
* lib/layouts/scrarticle-beamer.layout:
* lib/Makefile.am:
* development/scons/scons_manifest.py:
	- new layouts that support beamerarticle.cls

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24289 a592a061-630c-0410-9148-cb99ea01b6c8
2008-04-16 13:43:11 +00:00
Enrico Forestieri
c0d04eea68 Backslashes should be escaped, otherwise the translated string is ignored.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24003 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-27 11:06:36 +00:00
Richard Heck
d252730dff New AddToPreamble tag for layout files. This tag will ADD some information to the document premable rather than completely over-write it, as the Preamble tag does.
Increment layout format to 7.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23916 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-24 13:11:16 +00:00
Jürgen Spitzmüller
b7cf6951b6 * lib/layouts/theorems-ams.inc:
* lib/layouts/theorems-starred.inc:
* lib/layouts/theorems.inc:
	- some more amsthm fixes (and whitespace).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23577 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-09 10:13:59 +00:00
Richard Heck
999d69709f Whoops. Wrong place.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23569 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-08 16:47:47 +00:00
Richard Heck
ee56712fc8 Per J"urgen.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23568 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-08 16:46:56 +00:00
Richard Heck
d76e4b2311 Be more careful.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23545 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-07 20:57:40 +00:00
Richard Heck
3ce4518e19 Whitespace.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23544 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-07 20:57:18 +00:00
Richard Heck
c19b310d25 Starred --> Unnumbered, per Edwin
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23539 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-07 17:42:08 +00:00
Richard Heck
d2e5ef3d65 Some initial layout categories. More later, if this all works out.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23502 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-06 05:02:23 +00:00
Uwe Stöhr
7108582cbf stdinsets.inc: use foreground color also for index insets. Using the latex color would imply that you have to enter there LaTeX code, but since Lyx 1.6this is no longer the case
ColorCode.h: correct a comment

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23467 a592a061-630c-0410-9148-cb99ea01b6c8
2008-03-05 00:06:34 +00:00
Uwe Stöhr
f35ff8f60d Color.cpp, ColorCode.h: define new colors for inset labels and insets text
stdinsets: use the new colors to allow the users to customize them

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23029 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-15 23:38:16 +00:00
Richard Heck
e7c8aa0977 Define algorithm.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23026 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-15 17:03:07 +00:00
Uwe Stöhr
f647ae9e8a stdinsets.inc: use minimalistic style for listings as intended by Richard (I changed this unwanted in 22923)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23010 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-14 22:44:42 +00:00
Martin Vermeer
370afc3567 Minimalistic module
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23003 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-14 11:23:44 +00:00
Uwe Stöhr
d9669be4ec stdinsets.inc: use labels for certain inset types as we do currently in LyX 1.5 (fixes bug 4401).
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22923 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-10 17:20:59 +00:00
Uwe Stöhr
11b34c23ff method to avoid to use the end letter environment (patch by Jürgen)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22811 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-06 19:56:00 +00:00
Richard Heck
8fec5f512d Partially fix bug 4532: http://bugzilla.lyx.org/show_bug.cgi?id=4532.
See in particular comment 6.

We forcibly load stdinsets.inc unless the TextClass declares:
  Provides stdinsets 1
There isn't really any such package, of course. We're just using this
(per a suggestion by JMarc) to say we've loaded relevant info about the
standard insets.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22802 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-05 22:57:33 +00:00
Uwe Stöhr
ad9a92d9f5 layouts: add to all layouts "Input stdinsets.inc" if they not already have this
This fixes the obvious part of bug http://bugzilla.lyx.org/show_bug.cgi?id=4532

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22800 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-05 20:55:32 +00:00
Richard Heck
271d8d86b4 Include stdinsets.inc.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22777 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-04 19:34:18 +00:00
Richard Heck
cf8d9d29b1 Partially fix bug 4532.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22776 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-04 19:15:39 +00:00
Uwe Stöhr
886db92f82 enable the scrlttr 2 class for serial letters:
- file format change
- new example files and an example address database
- remove ugly hack from scrlttr2.layout and fix bug 4529

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22764 a592a061-630c-0410-9148-cb99ea01b6c8
2008-02-03 11:56:44 +00:00
Jürgen Spitzmüller
385ae43b39 * lib/layouts/beamer.layout:
* lib/layouts/moderncv.layout:
* lib/layouts/powerdot.layout:
	- These classes (at least) provide hyperref.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22642 a592a061-630c-0410-9148-cb99ea01b6c8
2008-01-21 13:40:34 +00:00
Jean-Marc Lasgouttes
3d8828fa14 * src/Spacing.cpp (writeBeginEnv, writeEndEnv): add a bool parameter
directing to use memoir's capitalized latex macros.
	* src/LaTeXFeatures.cpp (getPackages): act on feature "SetSpace".
	* src/output_latex.cpp (TeXOnePar): ditto

	* lib/layouts/memoir.layout: provide feature SetSpace, indicating that
	memoir provides the setspace functionality, but with a different syntax.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22551 a592a061-630c-0410-9148-cb99ea01b6c8
2008-01-14 14:53:29 +00:00
Richard Heck
e3bc7b9aed Tweaks.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22503 a592a061-630c-0410-9148-cb99ea01b6c8
2008-01-12 06:05:27 +00:00
Richard Heck
46611ba1cc Fixes to the theorem modules.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22502 a592a061-630c-0410-9148-cb99ea01b6c8
2008-01-12 05:17:52 +00:00
Richard Heck
d5d665482e This commit changes the way individual LyXModule's are represented, both internally and in the .lyx files. The earlier version represented them by their `descriptive name', e.g., "Endnote" or "Theorems (AMS)", these being the same names used in the UI. This was a mistake, as becomes readily apparent when one starts to think about translating these strings. The modules ought to be represented by their filename, without the extension, just as TextClass's are.
The changes that accomplish this part are in ModuleList.{h,cpp}, configure.py, and the *.module files themselves. This is a format change, and the lyx2lyx is in those files.

By itself, that change would not be major, except for the fact that we do not want the module to be represented in the UI by its filename---e.g., theorems-std---but rather by a descriptive name, such as "Theorems". But that change turns out to be wholly non-trivial. The mechanism for choosing modules was the same as---indeed, was borrowed from---that in GuiCitation: You get a list of modules, and choosing them involves moving strings from one QListView to another. The models underlying these views are just QStringListModels, which means that, when you want to know what modules have been selected, you see what strings are in the "selected" QListView. But these are just the descriptive names, and we can't look up a module by its descriptive name if it's been translated. That, indeed, was the whole point of the change to the new representation.

So, we need a more complicated model underlying the QListView, one that will pair an identifying string---the filename minus the extension, in this case---with each item. This turns out not to be terribly difficult, though it took rather a while for me to understand why it's not difficult. There are two parts:
(i)  GuiSelectionManger gets re-written to use any QAbstractListModel, not just a QStringListModel. This actually seems to improve the code, independently.
(ii) We then subclass QAbstractListModel to get the associated ID string, using the Qt::UserRole slot associated with each item to store its ID. This would be almost completely trivial if QAbstractListItem::itemData() included the QVariant associated with this role, but it doesn't, so there are some additional hoops through which to jump.

The new model, a GuiIdListModel, is defined in the files by that name. The changes in GuiSelectionManger.{h,cpp} make it more abstract; the changes in GuiDocument.{h,cpp} adapt it to the new framework. 

I've also updated the module documenation to accord with this change.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22501 a592a061-630c-0410-9148-cb99ea01b6c8
2008-01-12 04:28:12 +00:00
Richard Heck
098dc1f93b Remove comment.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22472 a592a061-630c-0410-9148-cb99ea01b6c8
2008-01-10 07:30:22 +00:00