Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to solve the problem that ie9 fonts are not vertically centered

2025-04-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/01 Report--

Today, I would like to share with you how to solve the problem that ie9 fonts are not vertically centered. The content is detailed and the logic is clear. I believe most people still know too much about this knowledge, so share this article for your reference. I hope you can get something after reading this article.

1. Convert Chinese fonts into Unicode codes.

The corresponding Unicode of "boldface" is "\ 9ED1\ 4F53".

The corresponding Unicode of "Song style" is "\ 5B8B\ 4F53".

The corresponding Unicode code of "imitating Song" is "\ 4EFF\ 5B8B".

The corresponding Unicode code of "Microsoft Acer" is "\ 5FAE\ 8F6F\ 96C5\ 9ED1".

Convert Chinese characters to Unicode-encoded characters, which is not only successful in setting the response font, but also compatible with the IE9 hunter to support vertical centered line-height techniques.

Realistic use of exp:

Div {font-family: "Microsoft Yahi"}

After conversion to Unicode coding

.div {font-family: "\ 5FAE\ 8F6F\ 96C5\ 9ED1"}

After the Chinese character font is converted to Unicode coding, the font result is similar, unaffected, and compatible with all major hunting devices.

What if I can't remember the Unicode coding table? Among the commonly used css fonts in CSS+DIV structure, the Chinese fonts are boldface, Song style, imitation Song and Microsoft Yahei. If you can't remember about entering the css Unicode coding table to search and copy the use. (/ / www.css5.com.cn/jiqiao/325.shtml)

2. Use the English name to convert the Chinese characters in the CSS configuration of the CSS+DIV into the corresponding English name fonts. After the conversion, the Chinese characters are persistent and compatible with all major browsers.

"boldface" corresponds to the English name "SimHei" and "Song style" corresponds to the English name "SimSun" and "imitating Song" corresponds to "FangSong" and "Microsoft Yahi" corresponding to the English name "Microsoft YaHei".

Theoretical application of exp:

.div {font-family: "Microsoft Yahi"}

After converting to an English name

Div {font-family: "Microsoft YaHei"}

The css font in div css construction is converted from Chinese character font to English name font, its font setting attainments are stubborn and compatible with all kinds of hunting devices, so everyone may be determined to use it.

These are all the contents of the article "how to solve the problem of ie9 font not being centered vertically". Thank you for reading! I believe you will gain a lot after reading this article. The editor will update different knowledge for you every day. If you want to learn more knowledge, please pay attention to the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report