How does CSS meet the weight customization of different fonts in different systems?

Wenquanyi fonts under Mac and Linux have the following thickness:

Normal: 400
Medium: 500
Semibold: 600
Bold: 700

but under Windows, Microsoft Acer has only 400 and 700 . Take SegmentFault as an example, the text thickness of the title is set to 500 , which looks fine under Mac, but under Windows, the Chinese of 500 is no different from that of 400 (see figure below).

clipboard.png

clipboard.png

is there any way to automatically overlay it up, such as 700, when there is no 500 thick font in the system, or is there any other way to set the corresponding thickness for different fonts?

Mar.24,2021

there is no way, css cannot know in advance whether the font supports weight adjustment. Only two platforms can be set up uniformly. If you have to make a difference, write two sets of rules and apply them to different platforms.

Menu