From f353e890447603a6f2573829a71e0c11b7033fe9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Uwe=20St=C3=B6hr?= Date: Thu, 24 Nov 2011 22:04:11 +0000 Subject: [PATCH] ctex template files: reduce to one file, fix broken language package settings (file still contains outdated info and unnecessary preamble code and creates several LaTeX errors about wrong lengths but can be fixed later) git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_2_0_X@40260 a592a061-630c-0410-9148-cb99ea01b6c8 --- lib/Makefile.am | 4 +- lib/templates/ctex-book.lyx | 93 -------------------- lib/templates/ctex-report.lyx | 93 -------------------- lib/templates/{ctex-article.lyx => ctex.lyx} | 39 +++++++- 4 files changed, 39 insertions(+), 190 deletions(-) delete mode 100644 lib/templates/ctex-book.lyx delete mode 100644 lib/templates/ctex-report.lyx rename lib/templates/{ctex-article.lyx => ctex.lyx} (86%) diff --git a/lib/Makefile.am b/lib/Makefile.am index f624e38e14..e77a1e708a 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -1534,9 +1534,7 @@ dist_templates_DATA = \ templates/agu_article.lyx \ templates/apa.lyx \ templates/beamer-conference-ornate-20min.lyx \ - templates/ctex-article.lyx \ - templates/ctex-book.lyx \ - templates/ctex-report.lyx \ + templates/ctex.lyx \ templates/de_beamer-conference-ornate-20min.lyx \ templates/dinbrief.lyx \ templates/docbook_article.lyx \ diff --git a/lib/templates/ctex-book.lyx b/lib/templates/ctex-book.lyx deleted file mode 100644 index aa195b5bc9..0000000000 --- a/lib/templates/ctex-book.lyx +++ /dev/null @@ -1,93 +0,0 @@ -#LyX 2.0 created this file. For more info see http://www.lyx.org/ -\lyxformat 413 -\begin_document -\begin_header -\textclass ctex-book -\begin_preamble -\DeclareRobustCommand\nobreakspace{\leavevmode\nobreak\ } -\end_preamble -\options UTF8,adobefonts -\use_default_options true -\maintain_unincluded_children false -\language chinese-simplified -\language_package % -\inputencoding utf8-plain -\fontencoding global -\font_roman default -\font_sans default -\font_typewriter default -\font_default_family default -\use_non_tex_fonts false -\font_sc false -\font_osf false -\font_sf_scale 100 -\font_tt_scale 100 - -\graphics default -\default_output_format pdf4 -\output_sync 0 -\bibtex_command default -\index_command default -\paperfontsize default -\spacing single -\use_hyperref false -\papersize default -\use_geometry false -\use_amsmath 1 -\use_esint 1 -\use_mhchem 1 -\use_mathdots 1 -\cite_engine basic -\use_bibtopic false -\use_indices false -\paperorientation portrait -\suppress_date false -\use_refstyle 1 -\index Index -\shortcut idx -\color #008000 -\end_index -\secnumdepth 3 -\tocdepth 3 -\paragraph_separation indent -\paragraph_indentation default -\quotes_language english -\papercolumns 1 -\papersides 1 -\paperpagestyle default -\tracking_changes false -\output_changes false -\html_math_output 0 -\html_css_as_file 0 -\html_be_strict false -\end_header - -\begin_body - -\begin_layout Title -基于CTeX的LyX书籍模板 -\end_layout - -\begin_layout Author -作者 -\end_layout - -\begin_layout Standard -\begin_inset CommandInset toc -LatexCommand tableofcontents - -\end_inset - - -\end_layout - -\begin_layout Chapter -简介 -\end_layout - -\begin_layout Standard -本文档基于ctex宏包,详细介绍参见ctex-article.lyx模板。 -\end_layout - -\end_body -\end_document diff --git a/lib/templates/ctex-report.lyx b/lib/templates/ctex-report.lyx deleted file mode 100644 index d671db1e06..0000000000 --- a/lib/templates/ctex-report.lyx +++ /dev/null @@ -1,93 +0,0 @@ -#LyX 2.0 created this file. For more info see http://www.lyx.org/ -\lyxformat 413 -\begin_document -\begin_header -\textclass ctex-report -\begin_preamble -\DeclareRobustCommand\nobreakspace{\leavevmode\nobreak\ } -\end_preamble -\options UTF8,adobefonts -\use_default_options true -\maintain_unincluded_children false -\language chinese-simplified -\language_package % -\inputencoding utf8-plain -\fontencoding global -\font_roman default -\font_sans default -\font_typewriter default -\font_default_family default -\use_non_tex_fonts false -\font_sc false -\font_osf false -\font_sf_scale 100 -\font_tt_scale 100 - -\graphics default -\default_output_format pdf4 -\output_sync 0 -\bibtex_command default -\index_command default -\paperfontsize default -\spacing single -\use_hyperref false -\papersize default -\use_geometry false -\use_amsmath 1 -\use_esint 1 -\use_mhchem 1 -\use_mathdots 1 -\cite_engine basic -\use_bibtopic false -\use_indices false -\paperorientation portrait -\suppress_date false -\use_refstyle 1 -\index Index -\shortcut idx -\color #008000 -\end_index -\secnumdepth 3 -\tocdepth 3 -\paragraph_separation indent -\paragraph_indentation default -\quotes_language english -\papercolumns 1 -\papersides 1 -\paperpagestyle default -\tracking_changes false -\output_changes false -\html_math_output 0 -\html_css_as_file 0 -\html_be_strict false -\end_header - -\begin_body - -\begin_layout Title -基于CTeX的LyX报告模板 -\end_layout - -\begin_layout Author -作者 -\end_layout - -\begin_layout Standard -\begin_inset CommandInset toc -LatexCommand tableofcontents - -\end_inset - - -\end_layout - -\begin_layout Chapter -简介 -\end_layout - -\begin_layout Standard -本文档基于ctex宏包,详细介绍参见ctex-article.lyx模板。 -\end_layout - -\end_body -\end_document diff --git a/lib/templates/ctex-article.lyx b/lib/templates/ctex.lyx similarity index 86% rename from lib/templates/ctex-article.lyx rename to lib/templates/ctex.lyx index 9c407cb1c9..edb0ca64c6 100644 --- a/lib/templates/ctex-article.lyx +++ b/lib/templates/ctex.lyx @@ -4,13 +4,14 @@ \begin_header \textclass ctex-article \begin_preamble +%Fixme: is this really necessary? \DeclareRobustCommand\nobreakspace{\leavevmode\nobreak\ } \end_preamble \options UTF8,adobefonts \use_default_options true \maintain_unincluded_children false \language chinese-simplified -\language_package % +\language_package none \inputencoding utf8-plain \fontencoding global \font_roman default @@ -64,6 +65,29 @@ \begin_body +\begin_layout Standard +\begin_inset Note Note +status open + +\begin_layout Plain Layout +This templates creates an article. + To create a book or a report, change the document class to +\family sans +book (ctex) +\family default + or +\family sans +report (ctex) +\family default +. + +\end_layout + +\end_inset + + +\end_layout + \begin_layout Title 基于CTeX的LyX文档模板 \end_layout @@ -121,6 +145,19 @@ http://yihui.name 小结 \end_layout +\begin_layout Standard +\begin_inset Note Note +status open + +\begin_layout Plain Layout +Fixme: the layout files are already part of LyX since version 2.0.2. +\end_layout + +\end_inset + + +\end_layout + \begin_layout Standard 本文档使用ctex-article.layout(类似的还有两种:书籍ctex-book和报告ctex-report.layout,如果你熟悉ctex宏包,这里就不 需要解释了),语言设置为简体中文,编码使用UTF8,字体用Adobe中文字体,输出类型设置为XeTeX。编译的时候中文与英文之间会自动加上空格,方便阅读。