Revision: 345 http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=345&view=rev Author: frlan Date: 2008-12-14 23:19:04 +0000 (Sun, 14 Dec 2008)
Log Message: ----------- GeanyLaTeX: Little code refactoring to remove some unneeded replacements in case of no KOMA script is apply able to make code easier to maintain.
Modified Paths: -------------- trunk/geanylatex/src/geanylatex.c
Modified: trunk/geanylatex/src/geanylatex.c =================================================================== --- trunk/geanylatex/src/geanylatex.c 2008-12-14 23:11:09 UTC (rev 344) +++ trunk/geanylatex/src/geanylatex.c 2008-12-14 23:19:04 UTC (rev 345) @@ -626,6 +626,35 @@ classoptions = g_strconcat(scriptsize, NULL); }
+ + switch (documentclass_int) + { + case 0: + { + documentclass_str = g_utf8_casefold("book", -1); + break; + } + case 1: + { + documentclass_str = g_utf8_casefold("article", -1); + break; + } + case 2: + { + documentclass_str = g_utf8_casefold("report", -1); + break; + } + case 3: + { + documentclass_str = g_utf8_casefold("letter", -1); + break; + } + case 4: + { + documentclass_str = g_utf8_casefold("beamer", -1); + } + } + if (KOMA_active) { switch (documentclass_int) @@ -645,46 +674,9 @@ documentclass_str = g_utf8_casefold("scrreprt", -1); break; } - case 3: - { - documentclass_str = g_utf8_casefold("letter", -1); - } - case 4: - { - documentclass_str = g_utf8_casefold("beamer", -1); - } } + } - else - { - switch (documentclass_int) - { - case 0: - { - documentclass_str = g_utf8_casefold("book", -1); - break; - } - case 1: - { - documentclass_str = g_utf8_casefold("article", -1); - break; - } - case 2: - { - documentclass_str = g_utf8_casefold("report", -1); - break; - } - case 3: - { - documentclass_str = g_utf8_casefold("letter", -1); - break; - } - case 4: - { - documentclass_str = g_utf8_casefold("beamer", -1); - } - } - }
if (documentclass_int == 3) code = g_string_new(TEMPLATE_LATEX_LETTER);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.