下划线的粗细 [英] Thickness of underline

查看:163
本文介绍了下划线的粗细的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图控制下划线的粗细,然而,它似乎只是一条不符合文本的巨大水平线。我怎样才能让文字下划线为文本的相同粗细:

I am attempting to control the thickness of an underline, however, it seems its just one huge horizontal line that does not conform to the text. How can I get the text to underline as the same thickness of the text:

<!DOCTYPE>
<html>
<head>
<style type="text/css">
.title {

border-bottom: 2px solid red;

}
</style>
</head>
<body>
<div class="title">test</div>
</body>
</html>


推荐答案

您只需插入 display:inline-block; 在你的css或 float 元素中;

you just have to insert display:inline-block; in your css or float the element;

这篇关于下划线的粗细的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆