Macintosh 系统的 HTML5 字体


由于浏览器无需下载任何字体文件,因为它已经在使用一种字体,因此默认情况下使用特定操作系统的系统字体可以提高效率。但这对于任何网络安全字体都是正确的。系统字体具有与当前操作系统使用的字体匹配的优势,使其在视觉上更具吸引力。

Microsoft 列表中的一些字体也与 Macintosh 系统兼容。它们是

Andale Mono, Arial, Arial Black, Comic Sans MS, Courier New, Impact, Trebuchet, Verdana, Symbol, Webdings and Times New Roman

Microsoft 操作系统不可用但在 Macintosh 系统中支持的字体是

American Typewriter, Apple Chancery, Baskerville, Big Caslon, Brush Script, Capitals, Charcoal, Hoefler Text Ornaments

让我们展望一下对 Macintosh 系统字体的理解。以下是 Macintosh 系统 HTML5 字体的示例。

使用“Verdana”字体

Verdana 字体非常受欢迎。即使在很小的字体尺寸下,Verdana 也易于阅读。

示例

在以下示例中,我们使用“verdana”字体。

<!DOCTYPE html>
<html>
<style>
body {
   font-family: Verdana;
}
</style>
<body>
   <h1>WELCOME TO TUTORIALSPOINT</h1>
   <p>The Best E-Way Learning</p>
</body>
</html>

输出

当脚本执行时,它将生成一个输出,在网页上以 verdana 样式显示上述脚本中使用的文本。

使用“Courier New”字体

最流行的等宽衬线字体是 Courier New。许多电子邮件服务将 Courier New 设置为其默认字体,并且它经常与代码显示一起使用。Courier New 是电影剧本的首选字体。

示例

在以下示例中,我们使用“courier new”字体。

<!DOCTYPE html>
<html>
<style>
body {
   font-family: 'Courier New';
}
</style>
<body>
   <h1>MSD</h1>
   <p>Mahendra Singh Dhoni is an Indian former professional cricketer
   who was captain of the Indian national cricket team in limited-overs
   formats from 2007 to 2017 and in Test cricket from 2008 to 2014.</p>
</body>
</html>

输出

运行上述脚本后,它将生成一个输出,其中包含在网页上以 courier new 样式显示的脚本中使用的文本。

使用“Brush Script MT”字体

Brush Script MT 字体的目的是模仿手写体。尽管它经过改进且具有吸引力,但可能难以阅读。谨慎使用它。

示例

在以下示例中,我们使用“Brush Script MT”字体。

<!DOCTYPE html>
<html>
<style>
body {
   font-family: 'Brush Script MT';
}
</style>
<body>
   <h1>JP DUMINY</h1>
   <p>Jean-Paul Duminy, more commonly known as JP Duminy,
   is a South African cricket commentator, and former international cricketer. 
   He was vice-captain of the South Africa Twenty20 team.</p>
</body>
</html>

输出

当用户尝试执行脚本时,它将显示一个输出,其中包含网页上以 Brush Script MT 显示的文本。

使用“Trebuchet Ms”字体

Trebuchet MS 是另一种网络安全无衬线字体。它可以很好地替代您网站的无衬线字体,因为它经常用于许多网站的正文内容。它甚至可能没有 Arial 的“基本”外观。

示例

在以下示例中,我们使用“Trebuchet Ms”字体。

<!DOCTYPE html>
<html>
<style>
body {
   font-family: 'trebuchet ms';
}
</style>
<body>
   <h1>AB DEVILLERS</h1>
   <p>
Abraham Benjamin de Villiers is a former South African international cricketer.
AB de Villiers was named as the ICC ODI Player of the Year three times during 
his 15-year international career</p>
</body>
</html>

输出

当脚本执行时,它将生成一个输出,在网页上以 Trebuchet Ms 样式显示上述脚本中使用的文本。

更新于: 2023年10月11日

119 次浏览

开启你的 职业生涯

通过完成课程获得认证

开始学习
广告

© . All rights reserved.