![comicsans 软件包可以在原版 Windows 10 上运行吗?](https://linux22.com/image/389885/comicsans%20%E8%BD%AF%E4%BB%B6%E5%8C%85%E5%8F%AF%E4%BB%A5%E5%9C%A8%E5%8E%9F%E7%89%88%20Windows%2010%20%E4%B8%8A%E8%BF%90%E8%A1%8C%E5%90%97%EF%BC%9F.png)
我最近注意到,\usepackage{comicsans}
在 Windows 10 中使用该软件包时,默认情况下,所有字符都变成方块。经过一番研究,这是因为COMIC.ttf
Windows 系统不再支持(包含)该软件包???
有点震惊的消息。但后来我手动下载并安装了字体。然而,当我使用时\textbf{text}
,里面包裹的字符仍然无法正确显示,如下所示。
有没有办法可以一劳永逸的解决呢?
谢谢。
\documentclass[a4paper,12pt]{article}
\usepackage{amsmath,amsfonts}
\usepackage{comicsans}
%\usepackage[T1]{fontenc}
%\usepackage[math]{iwona} %nice font
\usepackage[top=1cm,bottom=2cm,left=1cm,right=1cm]{geometry}
\usepackage{enumerate}
\usepackage{lastpage}
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhf{} % clears the header and footer
%\fancyhead[C]{\textbf{FE5116}}
\fancyfoot[L]{Page \thepage\ of \pageref{LastPage}}
\renewcommand{\headrulewidth}{0pt}
\begin{document}
\begin{center}
\textbf{Equation of a straight line}
\end{center}
\begin{minipage}[t]{0.55\textwidth}
In mathematics we are almost obsessed with finding the equations of straight lines. There are different ways of doing this, but the best way is to use the equation:
\[
y-y_1 = m(x-x_1),
\]
where $m$ is the gradient of the line and $(x_1,y_1)$ is the coordinates of a point on the line. \\
So, using this equation, find the equation of the following lines, giving your answer in the form
\[
ax+by+c = 0,
\]
where $a,b,c$ are integers (whole numbers -- no fractions).
\end{minipage}
%
\begin{minipage}[t]{0.4\textwidth}
%
\end{minipage}
%% new command %%
\newcommand*{\myQues}[1]{%
\item #1 \\
\vfill
\hfill $\rule{6cm}{0.3mm}$ \quad (3)
}%
\begin{enumerate}[1)]
\myQues{The line with gradient $4$ that passes through $(1,3)$.}
\myQues{The line with gradient $2$ that passes through $(6,2)$.}
\cleardoublepage
\myQues{The line with gradient $1$ that passes through $(2,-3)$.}
\myQues{The line with gradient $10$ that passes through $(-4,-6)$.}
\cleardoublepage
\myQues{The line with gradient $-2$ that passes through $(4,1)$.}
\myQues{The line with gradient $-3$ that passes through $(-2,-5)$.}
\end{enumerate}
%\end{document}
\cleardoublepage
Now, what happens if the gradient is a fraction? We still want our final answer to consist of integers -- so no fractions \ldots
\begin{enumerate}[1)]
\setcounter{enumi}{6}
\myQues{The line with gradient $\frac{1}{2}$ that passes through $(5,2)$.}
\myQues{The line with gradient $\frac{2}{3}$ that passes through $(6,1)$.}
\cleardoublepage
\myQues{The line with gradient $\frac{3}{4}$ that passes through $(2,-2)$.}
\myQues{The line with gradient $-\frac{1}{5}$ that passes through $(-2,4)$.}
\cleardoublepage
\myQues{The line with gradient $3$ that passes through $(\frac{1}{3},4)$.}
\myQues{The line with gradient $-2$ that passes through $(-\frac{1}{4},-\frac{2}{9})$.}
\end{enumerate}
\end{document}
答案1
感谢 UlrikeFischer,我删除了此处不准确的段落。该软件包已过期,并且与最新版本的 Comic Sans MS 不兼容。
您可以尝试comicsans
用以下方法替换包fontspec
:
\usepackage{fontspec}
\defaultfontfeatures{Scale = MatchUppercase}
\setmainfont{Comic Sans MS}[Scale = 1.0]
如果你还想替换数学字母,你可以mathastext
稍后加载,或者
\usepackage{unicode-math}
\setmathfont{XITS Math}
\setmathfont[range = up]{Comic Sans MS}
\setmathfont[range = it]{Comic Sans MS Italic}
\setmathfont[range = bfup]{Comic Sans MS Bold}
\setmathfont[range = bfit]{Comic Sans MS Bold Italic}
根据微软的说法,Comic Sans MS实际上包含在 Windows 10 中。
您可以合法获取与以下版本兼容的旧版本comicsans
免费作为可重新分发的 Web Microsoft Core Fonts 的一部分。