//获取系统的字体
public static void getLocalFontFamily(){
GraphicsEnvironment ge=GraphicsEnvironment.getLocalGraphicsEnvironment();
String [] fontName=ge.getAvailableFontFamilyNames(); for(int i=0;i<fontName.length;i++){
System.out.println(fontName[i]);
}
}

调用得:

AcadEref
Adobe Devanagari
Agency FB
AIGDT
AjiwaiPro
Algerian
AmdtSymbols
AMGDT
Arial
Arial Black
Arial Narrow
Arial Rounded MT Bold
Arvo
Bahnschrift
BankGothic Lt BT
BankGothic Md BT
Baskerville Old Face
Bauhaus 93
Bell MT
Berlin Sans FB
Berlin Sans FB Demi
Bernard MT Condensed
Blackadder ITC
Bodoni MT
Bodoni MT Black
Bodoni MT Condensed
Bodoni MT Poster Compressed
Book Antiqua
Bookman Old Style
Bookshelf Symbol 7
Bradley Hand ITC
Britannic Bold
Broadway
Brush Script MT
Calibri
Calibri Light
Californian FB
Calisto MT
Cambria
Cambria Math
Candara
Castellar
Centaur
Century
Century Gothic
Century Schoolbook
Chiller
CityBlueprint
Colonna MT
Comic Sans MS
CommercialPi BT
CommercialScript BT
Complex
Consolas
Constantia
Cooper Black
Copperplate Gothic Bold
Copperplate Gothic Light
Corbel
CountryBlueprint
Courier New
Curlz MT
DejaVu Sans Mono
DengXian
DengXian Light
Dialog
DialogInput
Droid Serif
Dubai
Dubai Light
Dubai Medium
Dutch801 Rm BT
Dutch801 XBd BT
Ebrima
Edwardian Script ITC
Elephant
Engravers MT
Eras Bold ITC
Eras Demi ITC
Eras Light ITC
Eras Medium ITC
EuroRoman
FangSong
Felix Titling
Footlight MT Light
Forte
Franklin Gothic Book
Franklin Gothic Demi
Franklin Gothic Demi Cond
Franklin Gothic Heavy
Franklin Gothic Medium
Franklin Gothic Medium Cond
Freestyle Script
French Script MT
FZShuTi
FZXiHei I-Z08T
FZYaoTi
Gabriola
Gadugi
Garamond
GDT
GENISO
Georgia
Gigi
Gill Sans MT
Gill Sans MT Condensed
Gill Sans MT Ext Condensed Bold
Gill Sans Ultra Bold
Gill Sans Ultra Bold Condensed
Gloucester MT Extra Condensed
GothicE
GothicG
GothicI
Goudy Old Style
Goudy Stout
GreekC
GreekS
Haettenschweiler
Harlow Solid Italic
Harrington
High Tower Text
HoloLens MDL2 Assets
HYCaoLiF
HYChuKaiF
HYCuSongJ
HYHengFangBeiF
HYLiuKaiF
HYLuXingF
HYOuXingF
HYTangLiF
HYWangXingF
HYZhaoKaiF
HYZhiCaoF
HYZhiKaiF
Impact
Imprint MT Shadow
Indie Flower
Informal Roman
Ink Free
ISOCP
ISOCP2
ISOCP3
ISOCPEUR
ISOCT
ISOCT2
ISOCT3
ISOCTEUR
Italic
ItalicC
ItalicT
Javanese Text
Jokerman
Juice ITC
KaiTi
Kristen ITC
Kunstler Script
Leelawadee UI
Leelawadee UI Semilight
LiSu
Lobster
Lucida Bright
Lucida Calligraphy
Lucida Console
Lucida Fax
Lucida Handwriting
Lucida Sans
Lucida Sans Typewriter
Lucida Sans Unicode
Magneto
Maiandra GD
Malgun Gothic
Malgun Gothic Semilight
Marlett
Matura MT Script Capitals
Microsoft Himalaya
Microsoft JhengHei
Microsoft JhengHei Light
Microsoft JhengHei UI
Microsoft JhengHei UI Light
Microsoft New Tai Lue
Microsoft PhagsPa
Microsoft Sans Serif
Microsoft Tai Le
Microsoft YaHei
Microsoft YaHei Light
Microsoft YaHei UI
Microsoft YaHei UI Light
Microsoft Yi Baiti
MingLiU-ExtB
MingLiU_HKSCS-ExtB
Mistral
Modern No. 20
Mongolian Baiti
Monospac821 BT
Monospaced
Monotxt
Monotype Corsiva
MS Gothic
MS Outlook
MS PGothic
MS Reference Sans Serif
MS Reference Specialty
MS UI Gothic
MT Extra
MV Boli
Myanmar Text
Niagara Engraved
Niagara Solid
Nirmala UI
Nirmala UI Semilight
NSimSun
OCR A Extended
Old English Text MT
Onyx
Open Sans
Palace Script MT
Palatino Linotype
PanRoman
Papyrus
Parchment
Perpetua
Perpetua Titling MT
Playbill
PMingLiU-ExtB
Poiret One
Poor Richard
Pristina
Proxy 1
Proxy 2
Proxy 3
Proxy 4
Proxy 5
Proxy 6
Proxy 7
Proxy 8
Proxy 9
Rage Italic
Raleway
Ravie
Roboto
Roboto Condensed
Roboto Slab
Rockwell
Rockwell Condensed
Rockwell Extra Bold
RomanC
RomanD
RomanS
RomanT
Romantic
SansSerif
Script MT Bold
ScriptC
ScriptS
Segoe MDL2 Assets
Segoe Print
Segoe Script
Segoe UI
Segoe UI Black
Segoe UI Emoji
Segoe UI Historic
Segoe UI Light
Segoe UI Semibold
Segoe UI Semilight
Segoe UI Symbol
Serif
Showcard Gothic
SimHei
Simplex
SimSun
SimSun-ExtB
Sitka Banner
Sitka Display
Sitka Heading
Sitka Small
Sitka Subheading
Sitka Text
Snap ITC
Source Code Pro
Source Code Pro Black
Source Code Pro ExtraLight
Source Code Pro Light
Source Code Pro Semibold
STCaiyun
Stencil
STFangsong
STHupo
STKaiti
STLiti
STSong
STXihei
STXingkai
STXinwei
Stylus BT
STZhongsong
SuperFrench
Swis721 BdCnOul BT
Swis721 BdOul BT
Swis721 Blk BT
Swis721 BlkCn BT
Swis721 BlkEx BT
Swis721 BlkOul BT
Swis721 BT
Swis721 Cn BT
Swis721 Ex BT
Swis721 Lt BT
Swis721 LtCn BT
Swis721 LtEx BT
Syastro
Sylfaen
Symap
Symath
Symbol
Symeteo
Symusic
Tahoma
Technic
TechnicBold
TechnicLite
Tempus Sans ITC
Times New Roman
Trebuchet MS
Tw Cen MT
Tw Cen MT Condensed
Tw Cen MT Condensed Extra Bold
Txt
UniversalMath1 BT
Verdana
Viner Hand ITC
Vineta BT
Vivaldi
Vladimir Script
Webdings
Wide Latin
Wingdings
Wingdings 2
Wingdings 3
YouYuan
Yu Gothic
Yu Gothic Light
Yu Gothic Medium
Yu Gothic UI
Yu Gothic UI Light
Yu Gothic UI Semibold
Yu Gothic UI Semilight
ZHSRXT-GBK
ZWAdobeF
汉仪粗宋简
经典粗宋简
经典粗宋繁

java 获取当前系统可用字体名称的更多相关文章

  1. Java获取Linux系统cpu使用率

    原文:http://www.open-open.com/code/view/1426152165201 import java.io.BufferedReader; import java.io.Fi ...

  2. Java 获取当前系统时间方法比较

    转载: http://blog.csdn.net/zzjjiandan/article/details/8372617 一. 获取当前系统时间和日期并格式化输出: import java.util.D ...

  3. Java 获取当前系统的时间

    获取当前系统的时间,每隔一秒,打印一次. import java.util.Date; public class TestDate { public static void main(String[] ...

  4. java 获取当前系统系时间

    //SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");//设置日期格式 SimpleDateFo ...

  5. java获取当前系统毫秒,纳秒

    //获取当前系统毫秒 System.out.println(System.currentTimeMillis()); //获取当前系统纳秒 System.out.println(System.nano ...

  6. JAVA获取计算机的IP、名称、操作系统等信息

    [java] view plaincopyprint? import java.io.BufferedReader; import java.io.InputStream; import java.i ...

  7. Java获取线程的对象和名称

    /*获取线程对象以及名称(很有意义的) 原来线程都有自己默认的名称Thread-编号  该编号从0开始 Thread 父类的方法static  Thread currentThread() :获取当前 ...

  8. java获取当前运行的方法名称

    // 这种方式获取的话,数组的第一个元素是当前运行方法的名称,第二个元素是调用当前方法的方法名称 StackTraceElement[] stackTrace = new Exception().ge ...

  9. java 获取当前系统时间

    Java的Date获取时间函数都是deprecated 可以使用: https://stackoverflow.com/questions/5175728/how-to-get-the-current ...

随机推荐

  1. 浅谈JavaScript 函数作用域当中的“提升”现象

    在JavaScript当中,定义变量通过var操作符+变量名.但是不加 var 操作符,直接赋值也是可以的. 例如 : message = "hello JavaScript ! " ...

  2. Docker 快速入门之 Dockerfile

    在 Docker 中我们可以从名为 Dockerfile 的文件中读取指令并且自动构建镜像.在本文中,将介绍 Dockerfile 的基本语法以及基本知识. Dockerfile 是什么 Docker ...

  3. Ubuntu 18.04.1 搭建Java环境和HelloWorld

    一.搭建Java环境 系统环境 Ubuntu 18.04.1 JDK 8 IDEA 2018.2 1.下载JDK 官网地址:http://www.oracle.com/technetwork/java ...

  4. shell编程练习(一): 笔试1-10

    笔试练习(一): 1.求2个数之和 [root@VM_0_5_centos test]# vi 1.sh [root@VM_0_5_centos test]# cat 1.sh #! /bin/sh ...

  5. 怎么将XML字符串转换为XmlDocument,并获取部分节点值

    我们的目标:解析XML字符串,并获取节点:z:row下的属性:ows_LinkFilename的值集合??? XML字符串数据结构如下: <listitems xmlns:s='uuid:BDC ...

  6. [转]BTC RPC API GetTransaction

    本文转自: GetTransaction GetTransaction gettransaction调用获取指定钱包内交易的详细信息.该调用需要节点 启用钱包功能. 参数 TXID:要查看详情的交易I ...

  7. 【转载】PhpStudy修改Apache的端口号

    phpStudy是一个PHP调试环境的程序集成包.该程序包集成最新的Apache+PHP+MySQL+phpMyAdmin+ZendOptimizer,一次性安装,无须配置即可使用,是非常方便.好用的 ...

  8. EF(EntityFramework)与mysql使用,取数据报错,linq实体映射错误

    报错信息:LINQ to Entities does not recognize the method 'System.String ToString()' method, and this meth ...

  9. Java高并发 -- J.U.C.组件扩展

    Java高并发 -- J.U.C.组件扩展 主要是学习慕课网实战视频<Java并发编程入门与高并发面试>的笔记 FutureTask Future模式,核心思想是异步调用.和同步调用的区别 ...

  10. JavaScript机器学习之线性回归

    译者按: AI时代,不会机器学习的JavaScript开发者不是好的前端工程师. 原文: Machine Learning with JavaScript : Part 1 译者: Fundebug ...