This will be needed for layout forward compatibility, and could also be used
for a layout editor. Writing was only implemented for styles, not for complete
layout files (text class). I rarely made use of default values for missing
variables which exist in read(), so the output it a bit verbose (but more safe
against future changes). Also, some things like CopyStyle are never written for
obvious reasons.
This default argument is inserted iff no inset argument is present. This is useful particularly for mandatory arguments that need to have a sensible default value.
The listings inset and include inset of type listings use two english terms
that are not localized yet: "Listing" for the caption and "Listings" for the
list of listings (not supported natively by LyX yet). The existing layout
translation mechanism has been extended to translate these terms as well:
1) Support [[stuff]] context in lib/layouttranslations
2) Support BabelPreamble and LangPreamble in InsetLayout
3) Use a InsetLayout for InsetInclude of type listings
4) Define BabelPreamble and LangPreamble in the layouts for InsetInclude
and InsetListings
We might want to rename the babelpreamble tokens to something more general.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36773 a592a061-630c-0410-9148-cb99ea01b6c8
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
indicates what prefix to use when constructing formatted references.
Documentation to follow.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33784 a592a061-630c-0410-9148-cb99ea01b6c8
First, it introduces some sensible defaults for the html
output; these are described in layout.h and implemented in
the openTag, etc, routines.
Second, it modifies the way standard environments are handled.
The previous version was outputing the label for each paragraph
of e.g. a theorem.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31744 a592a061-630c-0410-9148-cb99ea01b6c8
Fix the rest of the code, whih implies fixing a few potential bugs where the appendix status was not taken in account.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30524 a592a061-630c-0410-9148-cb99ea01b6c8
Don't go into an endless loop if layout2layout cannot produce the desired file format.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28529 a592a061-630c-0410-9148-cb99ea01b6c8
Implement infrastructure to add translations to layout files and translate one .inc file.
Some others are missing.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28356 a592a061-630c-0410-9148-cb99ea01b6c8
* src/TextClass.h[.cpp]: add addLayoutIfNeeded() and createDefaultLayout()
* src/Layout.h[.cpp]: add unknown_ to mark if a layout is a default layout for an unknown one.
* src/LayoutFile.cpp: add addDefaultClass and change addLayoutFile to addLocalLayout.
* src/Text.cpp: add unknown layouts that are not recognizable by a new textclass.
* src/frontends/qt4/GuiToolbar.cpp: display (unknown) for unknown layouts.
* src/frontends/qt4/GuiDocument.cpp: restore 'browse layout' button.
* src/frontends/qt4/ui/LaTeXUi.ui: restore 'browse layout' button.
* src/CutAndPaste.cpp: do not convert unknown layouts from pasted text
* src/BufferParams.cpp: add a default textclass when a document with unknown textclass is loaded.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25555 a592a061-630c-0410-9148-cb99ea01b6c8