Merge branch '2.0.x' of git.lyx.org:lyx into 2.0.x

This commit is contained in:
Uwe Stöhr 2012-03-28 22:51:50 +02:00
commit 3c2c0c182f
27 changed files with 394 additions and 266 deletions

14
.gitignore vendored Normal file
View File

@ -0,0 +1,14 @@
*.o
*~
.deps/
Makefile
Makefile.in
aclocal.m4
configure
autom4te.cache/
config.h.in
config.h
config.log
config.status
lyx.1
stamp-h1

1
boost/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
liblyxboost.a

6
config/.gitignore vendored Normal file
View File

@ -0,0 +1,6 @@
config.guess
config.sub
depcomp
install-sh
missing
py-compile

1
development/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
lyx.spec

2
development/MacOSX/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
Info.plist
lyxrc.dist

1
development/cygwin/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
lyxrc.dist

6
lib/.gitignore vendored Normal file
View File

@ -0,0 +1,6 @@
lyx.desktop
lyx.desktop-temp
lyx.png
lyx.svg
*.pyc

View File

@ -62,7 +62,7 @@ def cmdOutput(cmd):
'''
if os.name == 'nt':
b = False
cmd = 'cmd /d /c ' + cmd
cmd = 'cmd /d /c pushd ' + os.getcwd() + '&' + cmd
else:
b = True
pipe = subprocess.Popen(cmd, shell=b, close_fds=b, stdin=subprocess.PIPE, \

View File

@ -222,6 +222,50 @@ Style Subsection*
OptionalArgs 0
End
# Subsubsection style definition
Style Subsubsection
Category Section
Margin First_Dynamic
LatexType Command
LatexName lyxframeend{}\subsubsection
NeedProtect 1
NextNoIndent 1
LabelSep xx
ParSkip 0.4
TopSep 2
BottomSep 0.25
ParSep 0.5
Align Left
LabelType Counter
LabelCounter subsubsection
LabelString "Subsubsection \arabic{section}.\arabic{subsection}.\arabic{subsubsection}"
RefPrefix sub
OptionalArgs 1
# standard font definition
Font
Family Roman
Series Bold
Size large
EndFont
LabelFont
Color latex
EndFont
LabelStringAppendix "\arabic{section}.\arabic{subsection}.\arabic{subsubsection}"
TocLevel 2
End
# Subsubsection* style definition
Style Subsubsection*
CopyStyle Subsubsection
Category Unnumbered
Margin Static
LatexName lyxframeend{}\subsubsection*
LabelType No_Label
OptionalArgs 0
End
# Frame control definition
Style BeginFrame
Category Frames

1
lib/lyx2lyx/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
lyx2lyx_version.py

View File

@ -41,8 +41,6 @@ def InsertBib(fil, out):
elif "\\begin{btSect}" in line:
raise BibError("Cannot export sectioned bibliographies")
filenew = fil[:-4] + "-bibinc.tex" #The new .tex file
if len(biblist) > 1:
raise BibError("Cannot export multiple bibliographies.")
if not biblist:
@ -58,9 +56,35 @@ def InsertBib(fil, out):
outfile = open(out, 'w')
outfile.write("".join(newlist))
outfile.close()
return filenew
return out
def usage():
print r'''
Usage: python include_bib.py file.tex [outfile.tex]
Includes the contents of file.bbl, which must exist in the
same directory as file.tex, in place of the \bibliography
command, and creates the new file outfile.tex. If no name
for that file is given, we create: file-bbl.tex.
'''
if __name__ == "__main__":
newfile = InsertBib(sys.argv[1], sys.argv[2])
print "Wrote " + newfile
args = len(sys.argv)
if args <= 1 or args > 3:
usage()
sys.exit(0)
# we might should make sure this is a tex file....
infile = sys.argv[1]
if infile[-4:] != ".tex":
print "Error: " + infile + " is not a TeX file"
usage()
sys.exit(1)
if args == 3:
outfile = sys.argv[2]
else:
outfile = infile[:-4] + "-bbl.tex"
newfile = InsertBib(infile, outfile)
print "Wrote " + outfile

7
po/.gitignore vendored Normal file
View File

@ -0,0 +1,7 @@
POTFILES
POTFILES.in
lyx.pot
*.gmo
stamp-po
remove-potcdate.sed

411
po/de.po

File diff suppressed because it is too large Load Diff

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: LyX-2.1\n"
"Report-Msgid-Bugs-To: lyx-devel@lists.lyx.org\n"
"POT-Creation-Date: 2012-03-13 17:52-0400\n"
"POT-Creation-Date: 2012-03-27 15:36+0200\n"
"PO-Revision-Date: 2012-03-07 10:29+0100\n"
"Last-Translator: Kornel Benko <kornel@lyx.org>\n"
"Language-Team: Slovak <lyx-docs@lists.lyx.org>\n"
@ -17,7 +17,9 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Lokalize 1.2\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
"Plural-Forms: nplurals=3; plural=((n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2);\n"
"X-Language: sk_SK\n"
"X-Source-Language: en_US\n"
#: src/frontends/qt4/ui/AboutUi.ui:32
msgid "Version"
@ -6640,9 +6642,20 @@ msgstr "Podsekcia \\arabic{section}.\\arabic{subsection}"
msgid "\\arabic{section}.\\arabic{subsection}"
msgstr "\\arabic{section}.\\arabic{subsection}"
#: lib/layouts/beamer.layout:227 lib/layouts/beamer.layout:269
#: lib/layouts/beamer.layout:307 lib/layouts/beamer.layout:346
#: lib/layouts/beamer.layout:375
#: lib/layouts/beamer.layout:241
msgid ""
"Subsubsection \\arabic{section}.\\arabic{subsection}.\\arabic{subsubsection}"
msgstr ""
"Podpodsekcia \\arabic{section}.\\arabic{subsection}.\\arabic{subsubsection}"
# \arabic{section}.\arabic{subsection}.\arabic{subsubsection}
#: lib/layouts/beamer.layout:255
msgid "\\arabic{section}.\\arabic{subsection}.\\arabic{subsubsection}"
msgstr "Podsekcia \\arabic{section}.\\arabic{subsection}"
#: lib/layouts/beamer.layout:271 lib/layouts/beamer.layout:313
#: lib/layouts/beamer.layout:351 lib/layouts/beamer.layout:390
#: lib/layouts/beamer.layout:419
msgid "Frames"
msgstr "Rámy"
@ -26314,93 +26327,72 @@ msgstr "Neznámy používateľ"
#~ msgid "Printer &name:"
#~ msgstr "&Názov tlačiarne:"
#, fuzzy
#~ msgid "Columns "
#~ msgstr "Stĺpce"
#, fuzzy
#~ msgid "Overprint "
#~ msgstr "Separát"
#, fuzzy
#~ msgid "Conjecture "
#~ msgstr "Dohad"
#, fuzzy
#~ msgid "Font st&yle:"
#~ msgstr "Veľkosť písma"
#, fuzzy
#~ msgid "Part "
#~ msgstr "Časť"
#, fuzzy
#~ msgid "columns "
#~ msgstr "Stĺpce"
#, fuzzy
#~ msgid "overprint "
#~ msgstr "Predtlač"
#, fuzzy
#~ msgid "overlayarea"
#~ msgstr "Prekrytie"
#, fuzzy
#~ msgid "Corollary_"
#~ msgstr "Ľutujem."
#, fuzzy
#~ msgid "Definition. "
#~ msgstr "Definícia"
#, fuzzy
#~ msgid "Example. "
#~ msgstr "Príklad"
#, fuzzy
#~ msgid "Fact. "
#~ msgstr "Fakt"
#, fuzzy
#~ msgid "Proof. "
#~ msgstr "Dôkaz"
#, fuzzy
#~ msgid "note: "
#~ msgstr "poznámka"
#, fuzzy
#~ msgid "&Extended Chars"
#~ msgstr "Rozšírené vlastnosti|R"
#~ msgid "default"
#~ msgstr "štandardné"
#, fuzzy
#~ msgid "common"
#~ msgstr "Komentár"
#, fuzzy
#~ msgid "Toggle Table of Contents"
#~ msgstr "Obsah"
#, fuzzy
#~ msgid "Toc"
#~ msgstr "Námet"
#~ msgid "Table of Contents|T"
#~ msgstr "Obsah|O"
#, fuzzy
#~ msgid "OK"
#~ msgstr "&OK"
#, fuzzy
#~ msgid "Chinese"
#~ msgstr "Kópie"
#, fuzzy
#~ msgid "Upper"
#~ msgstr "Aktualizovať|A"
@ -26410,47 +26402,36 @@ msgstr "Neznámy používateľ"
#~ msgid "Opened Theorem Inset"
#~ msgstr "Otvorená teoréma prílohy"
#, fuzzy
#~ msgid "Error closing file"
#~ msgstr "Chyba pri čítaní "
#, fuzzy
#~ msgid "block "
#~ msgstr "Do bloku"
#, fuzzy
#~ msgid "Corollary. "
#~ msgstr "Ľutujem."
#, fuzzy
#~ msgid "&Caption"
#~ msgstr "Názov"
#, fuzzy
#~ msgid "A caption for the List of Listings"
#~ msgstr "Titulok pre podobrázok"
#, fuzzy
#~ msgid "&Label"
#~ msgstr "&Označenie:"
#, fuzzy
#~ msgid "A Label for the caption"
#~ msgstr "Tabuľka_popis"
#, fuzzy
#~ msgid "<- P&romote"
#~ msgstr "Ch&rániť:"
#, fuzzy
#~ msgid "D&own"
#~ msgstr "Hotovo"
#, fuzzy
#~ msgid "Upd&ate"
#~ msgstr "&Aktualizovať"
#, fuzzy
#~ msgid "SubSection"
#~ msgstr "Pododdiel"
@ -26464,11 +26445,9 @@ msgstr "Neznámy používateľ"
#~ msgid "Unknown toc list"
#~ msgstr "Neznámy zoznam obsahu"
#, fuzzy
#~ msgid "Insert glossary entry"
#~ msgstr "Vložiť položku indexu"
#, fuzzy
#~ msgid "Glo"
#~ msgstr "&Globálne"
@ -26493,31 +26472,25 @@ msgstr "Neznámy používateľ"
#~ msgid "Math Panel|l"
#~ msgstr "Matematický panel|M"
#, fuzzy
#~ msgid "Math Panel|P"
#~ msgstr "Matematický panel|M"
#, fuzzy
#~ msgid "Show math panel"
#~ msgstr "Zobraziť &cestu"
#, fuzzy
#~ msgid "LyX: Math Roots"
#~ msgstr "LyX: Matematický panel"
#, fuzzy
#~ msgid "LyX: Math Styles"
#~ msgstr "LyX: Nastaviť matematický štýl"
#, fuzzy
#~ msgid "LyX: Math Fonts"
#~ msgstr "LyX: Matematický panel"
#, fuzzy
#, qt-format
#~ msgid "The document uses a missing TeX class \"%1$s\".\n"
#~ msgstr "Dokument používa neznámu textovú triedu \"%1$s\"."
#, fuzzy
#~ msgid "Insert math delimiters"
#~ msgstr "Vložiť oddeľovač"
@ -26539,7 +26512,6 @@ msgstr "Neznámy používateľ"
#~ msgid "The encoding for the menu/popups fonts."
#~ msgstr "Kódovanie pre písmo ponuky a popup dialógy"
#, fuzzy
#~ msgid "#*"
#~ msgstr "*"
@ -26549,10 +26521,8 @@ msgstr "Neznámy používateľ"
#~ msgid "Opening child document "
#~ msgstr "Otváram podriadený dokument "
#, fuzzy
#~ msgid "Special Insets|S"
#~ msgstr "Otvorený objekt prílohy"
#, fuzzy
#~ msgid "Insets|n"
#~ msgstr "Vložiť|I"

1
sourcedoc/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
Doxyfile

6
src/.gitignore vendored Normal file
View File

@ -0,0 +1,6 @@
lyx
liblyxcore.a
liblyxgraphics.a
liblyxinsets.a
liblyxmathed.a
moc_Compare.cpp

View File

@ -255,13 +255,13 @@ pasteSelectionHelper(Cursor const & cur, ParagraphList const & parlist,
if (ref->getParam("reference") == oldname)
ref->setParam("reference", newname);
} else if (itt->lyxCode() == MATH_REF_CODE) {
InsetMathHull * mi = itt->asInsetMath()->asHullInset();
InsetMathRef * mi = itt->asInsetMath()->asRefInset();
// this is necessary to prevent an uninitialized
// buffer when the RefInset is in a MathBox.
// FIXME audit setBuffer calls
mi->setBuffer(const_cast<Buffer &>(buffer));
if (mi->asRefInset()->getTarget() == oldname)
mi->asRefInset()->changeTarget(newname);
if (mi->getTarget() == oldname)
mi->changeTarget(newname);
}
}
}
@ -285,14 +285,13 @@ pasteSelectionHelper(Cursor const & cur, ParagraphList const & parlist,
if (ref.getParam("reference") == oldname)
ref.setParam("reference", newname);
} else if (itt->lyxCode() == MATH_REF_CODE) {
InsetMathHull & mi =
static_cast<InsetMathHull &>(*itt);
InsetMathRef * mi = itt->asInsetMath()->asRefInset();
// this is necessary to prevent an uninitialized
// buffer when the RefInset is in a MathBox.
// FIXME audit setBuffer calls
mi.setBuffer(const_cast<Buffer &>(buffer));
if (mi.asRefInset()->getTarget() == oldname)
mi.asRefInset()->changeTarget(newname);
mi->setBuffer(const_cast<Buffer &>(buffer));
if (mi->getTarget() == oldname)
mi->changeTarget(newname);
}
}
break;

2
src/client/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
lyxclient
lyxclient.1

1
src/frontends/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
liblyxfrontends.a

5
src/frontends/qt4/.gitignore vendored Normal file
View File

@ -0,0 +1,5 @@
Resources.cpp
Resources.qrc
liblyxqt4.a
ui_*.h
moc_*.cpp

View File

@ -37,6 +37,9 @@
#include <QColor>
#include <QColorDialog>
#ifdef KeyPress
#undef KeyPress
#endif
namespace lyx {
namespace frontend {

View File

@ -113,8 +113,8 @@ void InsetLabel::updateReferences(docstring const & old_label,
for (; it != end; ++it) {
buffer().undo().recordUndo(it->second);
if (it->first->lyxCode() == MATH_REF_CODE) {
InsetMathHull * mi = it->first->asInsetMath()->asHullInset();
mi->asRefInset()->changeTarget(new_label);
InsetMathRef * mi = it->first->asInsetMath()->asRefInset();
mi->changeTarget(new_label);
} else {
InsetCommand * ref = it->first->asInsetCommand();
ref->setParam("reference", new_label);

2
src/support/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
liblyxsupport.a
moc_SystemcallPrivate.cpp

2
src/tex2lyx/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
tex2lyx
tex2lyx.1

View File

@ -401,6 +401,7 @@ Preamble::Preamble() : one_language(true)
h_font_sans = "default";
h_font_typewriter = "default";
h_font_default_family = "default";
h_use_non_tex_fonts = "false";
h_font_sc = "false";
h_font_osf = "false";
h_font_sf_scale = "100";
@ -581,8 +582,12 @@ void Preamble::handle_package(Parser &p, string const & name,
add_package(name, options);
string scale;
if (is_known(name, known_xetex_packages))
if (is_known(name, known_xetex_packages)) {
xetex = true;
h_use_non_tex_fonts = "true";
if (h_inputencoding == "auto")
p.setEncoding("utf8");
}
// roman fonts
if (is_known(name, known_roman_fonts)) {
@ -903,6 +908,7 @@ bool Preamble::writeLyXHeader(ostream & os, bool subdoc)
<< "\\font_sans " << h_font_sans << "\n"
<< "\\font_typewriter " << h_font_typewriter << "\n"
<< "\\font_default_family " << h_font_default_family << "\n"
<< "\\use_non_tex_fonts " << h_use_non_tex_fonts << "\n"
<< "\\font_sc " << h_font_sc << "\n"
<< "\\font_osf " << h_font_osf << "\n"
<< "\\font_sf_scale " << h_font_sf_scale << "\n"

View File

@ -90,6 +90,7 @@ private:
std::string h_font_sans;
std::string h_font_typewriter;
std::string h_font_default_family;
std::string h_use_non_tex_fonts;
std::string h_font_sc;
std::string h_font_osf;
std::string h_font_sf_scale;

View File

@ -24,12 +24,16 @@ What's new
* DOCUMENT INPUT/OUTPUT
-
- Add support for \subsubsection and \subsubsection* in beamer layout.
- Made some minor improvements to the include_bib.py script.
* TEX2LYX IMPROVEMENTS
- Support for the LaTeX-command \sindex (for split indexes).
- Better support for XeTeX and LuaTeX documents: automatically set default
encoding to utf-8 and select support for non-TeX fonts.
* USER INTERFACE
@ -71,9 +75,15 @@ What's new
- Fix reconfiguration on Windows when the temporary directory used by
python contains non-ascii characters.
- Fix reconfiguration on Windows when the user directory is a UNC path
(bug 8098).
* USER INTERFACE
- Fixed crash when modifying or pasting an equation label and there
are references to that label in math (bug 8095).
- Do not disable View/Update Other Formats button when "Use non-TeX fonts"
is active (bug 8069).