简体   繁体   English

cmd.exe的CSS字体系列

[英]CSS font-family of cmd.exe

I can't find any font-family in CSS, which is similar to the font-family used in the CMD.exe. 我在CSS中找不到任何font-family,这类似于CMD.exe中使用的font-family。 Could you please help me? 请你帮助我好吗?

控制台字体

You can use 您可以使用

font-family:monospace

to specify that you wish a monospaced font to be used. 指定您希望使用等宽字体。

The console uses a monospaced font to ensure that all characters have the same width. 控制台使用等宽字体来确保所有字符具有相同的宽度。

Note that some browsers do not correctly implement monospaced, though there are approaches to fix that, eg 请注意,有些浏览器没有正确实现等宽,尽管有一些方法可以修复它,例如

http://code.stephenmorley.org/html-and-css/fixing-browsers-broken-monospace-font-handling/ http://code.stephenmorley.org/html-and-css/fixing-browsers-broken-monospace-font-handling/

It is a bitmap-font like implementation in CMD.exe, so if you wanna try : 它是一个位图字体,就像CMD.exe中的实现一样,所以如果你想尝试:

find a correct bitmap file (exemple: https://github.com/idispatch/raster-fonts ) 找到一个正确的位图文件(例如: https//github.com/idispatch/raster-fonts

then use a HTML5 canvas and play with your bitmap like this: 然后使用HTML5画布并像这样使用你的位图:

http://html5.santo.fr/index.php?post/2011/02/03/Tutorial-8-%3A-Hello-Word-with-BitMap-Font http://html5.santo.fr/index.php?post/2011/02/03/Tutorial-8-%3A-Hello-Word-with-BitMap-Font

Good luck ;) 祝好运 ;)

By default, CSS doesn't provide a font that looks perfectly like the raster font of the command prompt. 默认情况下,CSS不提供与命令提示符的光栅字体完全相同的字体。

It is possible to find some fonts that looks similar on dafont.com but those I found wasn't really monospaced (and force a not monospaced police is really ugly ) then I found this site : 有可能在dafont.com上找到一些看起来类似的字体,但我找到的并不是真正的等宽字体(强迫一个不是等宽的警察真的很难看 )然后我找到了这个网站:

https://int10h.org/oldschool-pc-fonts/fontlist https://int10h.org/oldschool-pc-fonts/fontlist

CSS3 supports Lucida console . CSS3支持Lucida控制台 Barring that, I don't know what you're on about. 除此之外,我不知道你在谈论什么。

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

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