W3School TIY Editor
W3School 在线教程
改变方向
暗黑模式
运行代码
<!DOCTYPE html> <html> <head> <style> .p1 { font-family: "Times New Roman", Times, serif; } .p2 { font-family: Arial, Helvetica, sans-serif; } .p3 { font-family: "Lucida Console", "Courier New", monospace; } </style> </head> <body> <h1>CSS font-family</h1> <p>这是一个段落,以 Times New Roman 字体显示:</p> <p class="p1">This is a paragraph, shown in the Times New Roman font.</p> <p>这是一个段落,以 Arial 字体显示:</p> <p class="p2">This is a paragraph, shown in the Arial font.</p> <p>这是一个段落,以 Lucida Console 字体显示:</p> <p class="p3">This is a paragraph, shown in the Lucida Console font.</p> </body> </html>