我是 HTML 设计的新手,很难理解为什么我的网页设计无法显示正确的字体。如果我使用这段代码:
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/dojo/1.5/dijit/themes/claro/claro.css">
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/dojo/1.5/dojox/grid/resources/Grid.css">
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/dojo/1.5/dojox/grid/resources/claroGrid.css">
<link rel="stylesheet" href="css/style.css">
右边显示的字体。但是,如果我使用我的 Dojo 1.6.1 本地副本,则使用以下代码:
<link rel="stylesheet" href="../dojo161/dijit/themes/claro/claro.css">
<link rel="stylesheet" href="../dojo161/dojox/grid/resources/Grid.css">
<link rel="stylesheet" href="../dojo161/dojox/grid/resources/claroGrid.css">
<link rel="stylesheet" href="css/style.css">
它不会为 html 正文显示相同的字体。 我做错了什么?
谢谢, PS:我已经检查过使用 Google Chrome webkit,可以访问资源(*.css)
最佳答案
1.5 在 claro.css
中的定义与 1.6.1 不同。
.claro {
font-family:Verdana,Arial,Helvetica,sans-serif; // <-- !!!
font-size: .688em;
color: #131313;
}
.claro .dijitCalendarDateTemplate {
font-family: Arial;
// ...
}
/* h1 to h6, p, ol, ul etc. diffes in for example:
- font-size
- font-weight
- line-height
*/
关于html - 为什么当我使用本地 Dojo CSS 时我的网站不显示正确的字体?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8111904/