]> git.lyx.org Git - features.git/commitdiff
fix bug 2090 (remove param \quotes_times). File format is up to 245 now.
authorJürgen Spitzmüller <spitz@lyx.org>
Thu, 13 Oct 2005 10:59:39 +0000 (10:59 +0000)
committerJürgen Spitzmüller <spitz@lyx.org>
Thu, 13 Oct 2005 10:59:39 +0000 (10:59 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10549 a592a061-630c-0410-9148-cb99ea01b6c8

development/ChangeLog
development/FORMAT
lib/lyx2lyx/ChangeLog
lib/lyx2lyx/LyX.py
lib/lyx2lyx/lyx_1_4.py
src/ChangeLog
src/buffer.C
src/bufferparams.C
src/tex2lyx/ChangeLog
src/tex2lyx/preamble.C
src/text3.C

index db6937f1046940d2804510c20e42393578032b87..804b4c6d5757bf735a2f036b93e01c1b8b11b087 100644 (file)
@@ -1,3 +1,7 @@
+2005-10-13  Jürgen Spitzmüller  <j.spitzmueller@gmx.de>
+
+       * FORMAT: document format change to 245.
+
 2005-10-11  Bennet Helm  <bennet.helm@fandm.edu>
 
        * MacOSX/LyX.app/Contents/MacOS/lyxeditor: Use the new location of
index 65164a079afdb0e13cac4077e3e0d52a1ea7d0ee..e2f0c908ced9543999984c4e6a6b20d65016912b 100644 (file)
@@ -1,6 +1,11 @@
 LyX file-format changes
 -----------------------
 
+2005-10-12  Jürgen Spitzmüller  <j.spitzmueller@gmx.de>
+
+       * format incremented to 245. The \quotes_times parameter
+       has been removed.
+
 2005-09-24  Jürgen Spitzmüller  <j.spitzmueller@gmx.de>
 
        * format incremented to 244. Rename '\InsetSpace \,'
index 1783652f5cdd111af058eb2fe48d1ac73f7baafb..fb21555129bf8539a9787ff8c5359dd1dc6d1ce1 100644 (file)
@@ -1,3 +1,9 @@
+2005-10-12  Jürgen Spitzmüller  <j.spitzmueller@gmx.de>
+
+       * LyX.py: enlarge range to current format (245);
+       do not use \quotes_times anymore on NewFile.
+       * lyx_1_4.py (remove_quotestimes): remove param \quotes_times (bug 2090).
+
 2005-09-28  José Matos  <jamatos@lyx.org>
 
        * LyX.py: fix relation_format reversion
index 12f99b3b662fe04b322a90ea97744427759e7dfd..7a30eb76846f64c169474e5b40a2eb4af748158e 100644 (file)
@@ -46,7 +46,7 @@ format_relation = [("0_10",  [210], ["0.10.7","0.10"]),
                    ("1_1_6fix3", [218], ["1.1.6fix3","1.1.6fix4","1.1"]),
                    ("1_2", [220], ["1.2.0","1.2.1","1.2.3","1.2.4","1.2"]),
                    ("1_3", [221], ["1.3.0","1.3.1","1.3.2","1.3.3","1.3.4","1.3.5","1.3.6","1.3"]),
-                   ("1_4", range(222,245), ["1.4.0cvs","1.4"])]
+                   ("1_4", range(222,246), ["1.4.0cvs","1.4"])]
 
 
 def formats_list():
@@ -481,7 +481,6 @@ class NewFile(LyX_Base):
             "\\paragraph_separation indent",
             "\\defskip medskip",
             "\\quotes_language english",
-            "\\quotes_times 2",
             "\\papercolumns 1",
             "\\papersides 1",
             "\\paperpagestyle default",
index 05a0102ac7dbdc18e43a0e6555f6295f1995781e..9594c9a33e6882cf72f83ff2db7953deb0760e29 100644 (file)
@@ -2258,6 +2258,13 @@ def remove_paperpackage(file):
         file.header[i] = "\\papersize default"
 
 
+def remove_quotestimes(file):
+    i = find_token(file.header, '\\quotes_times', 0)
+    if i == -1:
+        return
+    del file.header[i]
+
+
 ##
 # Convertion hub
 #
@@ -2286,9 +2293,11 @@ convert = [[222, [insert_tracking_changes, add_end_header]],
            [241, [convert_ert_paragraphs]],
            [242, [convert_french]],
            [243, [remove_paperpackage]],
-          [244, [rename_spaces]]]
+          [244, [rename_spaces]],
+          [245, [remove_quotestimes]]]
 
-revert =  [[243, [revert_space_names]],
+revert =  [[244, []],
+          [243, [revert_space_names]],
           [242, []],
            [241, []],
            [240, [revert_ert_paragraphs]],
index 4dd054fb801bcc423cfa6700f4b5ee5314674971..77cc8d1df840d23aaa92bc5cd131c3c3a7305073 100644 (file)
@@ -1,3 +1,10 @@
+2005-10-12  Jürgen Spitzmüller  <j.spitzmueller@gmx.de>
+
+       * buffer.C: version upgrade to 245.
+       * bufferparams.C: remove \quotes_times (bug 2090).
+       * text3.C (doDispatch): LFUN_QUOTE_INSERT has to output double
+       quotation marks as default.
+
 2005-10-09  Georg Baum  <Georg.Baum@post.rwth-aachen.de>
 
        * CutAndPaste.C (nrOfParagraphs): remove (unused)
index a62baf1fae9bec9a5b155b92c42045e1b85465cf..b2cf912c18a2a1d43d32c1ec43fe56c4543c9b1e 100644 (file)
@@ -144,7 +144,7 @@ extern BufferList bufferlist;
 
 namespace {
 
-int const LYX_FORMAT = 244;
+int const LYX_FORMAT = 245;
 
 } // namespace anon
 
index fbf93f12c7f1fd34959e1a698c9a071a9bd14efa..087900c5b960fe69042a25fdfbbee020913c8f87 100644 (file)
@@ -105,25 +105,6 @@ QuotesLangTranslator const & quoteslangtranslator()
 }
 
 
-// Quote times
-typedef Translator<int, InsetQuotes::quote_times> QuotesTimesTranslator;
-
-
-QuotesTimesTranslator const init_quotestimestranslator()
-{
-       QuotesTimesTranslator translator(1, InsetQuotes::SingleQ);
-       translator.addPair(2, InsetQuotes::DoubleQ);
-       return translator;
-}
-
-
-QuotesTimesTranslator const & quotestimestranslator()
-{
-       static QuotesTimesTranslator translator = init_quotestimestranslator();
-       return translator;
-}
-
-
 // Paper size
 typedef Translator<std::string, PAPER_SIZE> PaperSizeTranslator;
 
@@ -307,7 +288,6 @@ BufferParams::BufferParams()
 {
        paragraph_separation = PARSEP_INDENT;
        quotes_language = InsetQuotes::EnglishQ;
-       quotes_times = InsetQuotes::DoubleQ;
        fontsize = "default";
 
        /*  PaperLayout */
@@ -460,10 +440,6 @@ string const BufferParams::readToken(LyXLex & lex, string const & token)
                string quotes_lang;
                lex >> quotes_lang;
                quotes_language = quoteslangtranslator().find(quotes_lang);
-       } else if (token == "\\quotes_times") {
-               int qtimes;
-               lex >> qtimes;
-               quotes_times = quotestimestranslator().find(qtimes);
        } else if (token == "\\papersize") {
                string ppsize;
                lex >> ppsize;
@@ -663,9 +639,7 @@ void BufferParams::writeFile(ostream & os) const
           << string_paragraph_separation[paragraph_separation]
           << "\n\\defskip " << getDefSkip().asLyXCommand()
           << "\n\\quotes_language "
-          << string_quotes_language[quotes_language] << '\n'
-          << "\\quotes_times "
-          << quotestimestranslator().find(quotes_times)
+          << string_quotes_language[quotes_language]
           << "\n\\papercolumns " << columns
           << "\n\\papersides " << sides
           << "\n\\paperpagestyle " << pagestyle << '\n';
index 4a7a824ec8d737355f9589d65895556039c97ee1..4a4edf08b25694d23cf694d8df05f6914848bb29 100644 (file)
@@ -1,3 +1,7 @@
+2005-10-12  Jürgen Spitzmüller  <j.spitzmueller@gmx.de>
+
+       * preamble.C: update format to 245 (do not output \quotes_times).
+
 2005-08-19  Georg Baum  <Georg.Baum@post.rwth-aachen.de>
 
        * text.C (parse_text): Output \item in list environments that are
index 6a62d31aee067cbba7f16cda0d5a0f89a93d9de1..8e8fadd6ed1848b5c952a022fe1128e71dd6fc20 100644 (file)
@@ -82,7 +82,6 @@ string h_tocdepth                = "3";
 string h_paragraph_separation    = "indent";
 string h_defskip                 = "medskip";
 string h_quotes_language         = "english";
-string h_quotes_times            = "2";
 string h_papercolumns            = "1";
 string h_papersides              = string();
 string h_paperpagestyle          = "default";
@@ -233,7 +232,7 @@ void handle_package(string const & name, string const & opts)
 void end_preamble(ostream & os, LyXTextClass const & /*textclass*/)
 {
        os << "#LyX file created by  tex2lyx 0.1.2\n"
-          << "\\lyxformat 243\n"
+          << "\\lyxformat 245\n"
           << "\\begin_document\n"
           << "\\begin_header\n"
           << "\\textclass " << h_textclass << "\n"
@@ -257,7 +256,6 @@ void end_preamble(ostream & os, LyXTextClass const & /*textclass*/)
           << "\\paragraph_separation " << h_paragraph_separation << "\n"
           << "\\defskip " << h_defskip << "\n"
           << "\\quotes_language " << h_quotes_language << "\n"
-          << "\\quotes_times " << h_quotes_times << "\n"
           << "\\papercolumns " << h_papercolumns << "\n"
           << "\\papersides " << h_papersides << "\n"
           << "\\paperpagestyle " << h_paperpagestyle << "\n"
index 671f7e6cc4cbbaca2af6d090b701478b01f77533..5c75729a69c18332217517a50146e4b081a25bff 100644 (file)
@@ -960,12 +960,10 @@ void LyXText::dispatch(LCursor & cur, FuncRequest & cmd)
                                cur.insert(new InsetQuotes(c,
                                    bufparams.quotes_language,
                                    InsetQuotes::SingleQ));
-                       else if (arg == "double")
+                       else
                                cur.insert(new InsetQuotes(c,
                                    bufparams.quotes_language,
                                    InsetQuotes::DoubleQ));
-                       else
-                               cur.insert(new InsetQuotes(c, bufparams));
                        cur.posRight();
                }
                else