- pandoc --extract-media ./ chapter14_text_2022_111_1.docx -o chap14.tex
- cd images/media
- rename imagexx.tmp imagexx.png
- convert imagexx.emf image40.png
- sed -i -e '/hypertarget/d' -e 's/\\label.*$//' -e 's/includegraphics\[width=.*\]/includegraphics/' -e '/includegraphics{/i \\\\begin\{figure\}\n\\begin\{centering\}' -e '/includegraphics{/a \\\\end\{centering\}\n\\caption\{\}\n\\end\{figure\}' -e 's/\\textgreater/>/' chap1.tex
- Edit chap1.tex. Add the lines at the beginning:
\documentclass[10pt,a4paper]{extarticle}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{fontspec}
\setmainfont[Mapping=tex-text]{Noto Serif CJK TC}
\setsansfont[Mapping=tex-text]{Noto Serif CJK TC}
\setmonofont{Noto Serif CJK TC}
\usepackage{float}
\usepackage{graphicx}
\usepackage[unicode=true,pdfusetitle,
bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
breaklinks=false,pdfborder={0 0 0},pdfborderstyle={},backref=false,colorlinks=false]
{hyperref}
\makeatletter
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
\pdfpageheight\paperheight
\pdfpagewidth\paperwidth
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands.
\theoremstyle{definition}
\newtheorem{example}{\protect\examplename}
\@ifundefined{date}{}{\date{}}
\makeatother
%\providecommand{\examplename}{範例}
\begin{document}
\renewcommand{\footrulewidth}{0.4pt}
\thispagestyle{empty}\tableofcontents{}
\pagebreak{}
\renewcommand{\footrulewidth}{0.4pt}
\thispagestyle{empty}\tableofcontents{}
\pagebreak{} - Add the line at the endding:
\end{document} - import into lyx
- inside lyx:
文件->設定->字型,click 「使用非-TeX字型」,底下全選「Noto Serif CJK TC」
文件->設定->語言,選「中文(正體)」
文件->設定->PDF屬性,click「使用 Hyperref 功能」
文件->設定->浮動框位置,選「肯定在此」 - 編輯 LyX 檔內容
2023年12月3日 星期日
docx to lyx
訂閱:
張貼留言 (Atom)
-
cf: https://www.tenforums.com/tutorials/101274-uninstall-printer-driver-windows-10-a.html Open cmd in administer mode Run printmanagement...
-
cf: https://forums.raspberrypi.com/viewtopic.php?t=278033 For linux: First run the command: route -n It will show the metrics of the i...
-
cf: https://askubuntu.com/questions/1276111/error-upgrading-grub-efi-amd64-signed-special-device-old-ssd-does-not-exist sudo mv /var/cache...
沒有留言:
張貼留言