【问题标题】:bootstrap twitter glyphicon shadow cssbootstrap twitter glyphicon 阴影 css
【发布时间】:2014-10-21 16:42:54
【问题描述】:

谁能帮我弄一些引导字形图标的按钮看起来正确吗? 我试图在 CSS 中为它们添加一些阴影,但阴影围绕按钮,而不是图标本身。有没有办法在图标周围制作阴影(或至少是图标的形式)? 谢谢, 亚历克斯

【问题讨论】:

  • link。它很乱,但是如果您查看按钮 (i)(信息)(右上角),您应该能够看到问题所在。 <button class="btn btn-link" title="Help" style="background:none; color:yellow; position: absolute; right: 12px; top: 3px; left: auto; " onclick="myFunction()"><span class="glyphicon glyphicon-info-sign" style="background:none !important; box-shadow: -4px -4px 5px white;"></span></button>

标签: jquery html css twitter-bootstrap glyphicons


【解决方案1】:

由于图标是使用自定义字体呈现的,因此您必须使用 text-shadow:

.glyphicon{
    text-shadow: 0 0 5px red;
}

Demo fiddle

【讨论】:

  • 太棒了!就是这样!现在对我来说可能吗。谢谢!是否也可以反转文本阴影?喜欢反转 i 吗?
猜你喜欢
  • 1970-01-01
  • 2012-02-26
  • 1970-01-01
  • 2014-05-10
  • 1970-01-01
  • 1970-01-01
  • 2016-08-17
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多