简体   繁体   English

我的gulp iconfont渲染像一个丑陋的实时跟踪图标

[英]My gulp iconfont renders like an ugly live traced icon

I noticed my icons look off when I zoom in to my navigation. 我注意到当我放大导航时我的图标看起来不对。 I'm using Gulp-iconfont (npm package) with just the default template and styling as in the link is described. 我使用的是Gulp-iconfont(npm软件包),仅包含默认模板和链接中所述的样式。

My HTML: 我的HTML:

<li class="pageNav_metaItem">
 <a href="#" class="pageNav_metaLink"><i id="open-apps-bar" class="icon-apps"></i></a>
</li>

Rendered font .svg file . 呈现的 .svg 字体 文件

Can anyone help me with this issue? 谁能帮我解决这个问题?

As I see , all your icons don't feel well. 我所见 ,您的所有图标都不舒服。 To fix it add the fontHeight setting to the gulp-iconfont configuration: 要修复它,请将fontHeight设置添加到fontHeight gulp-iconfont配置:

// ...
.pipe(require('gulp-iconfont')({
    fontName: 'icons',
    formats: ['eot', 'woff', 'woff2'],
    fontHeight: 1024
}))
// ...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM