'getFamilies' method return all the font families installed on the user's system, including any application fonts or SDK fonts.
Example
List<String> fontNames = Font.getFamilies();
FontFamilies.java
package com.sample.app;
import java.util.List;
import javafx.scene.text.Font;
public class FontFamilies {
public static void main(String args[]) {
List<String> fontNames = Font.getFamilies();
for(String fontName: fontNames) {
System.out.println(fontName);
}
}
}
Sample Output
.AppleSystemUIFont
Al Bayan
Al Nile
Al Tarikh
American Typewriter
Andale Mono
Apple Braille
Apple Chancery
Apple Color Emoji
Apple SD Gothic Neo
Apple Symbols
AppleGothic
AppleMyungjo
Arial
Arial Black
Arial Hebrew
Arial Hebrew Scholar
Arial Narrow
Arial Rounded MT Bold
Arial Unicode MS
Avenir
Avenir Next
Avenir Next Condensed
Ayuthaya
Baghdad
Bangla MN
Bangla Sangam MN
Baskerville
Beirut
Big Caslon
Bodoni 72
Bodoni 72 Oldstyle
Bodoni 72 Smallcaps
Bodoni Ornaments
Bogle
Bradley Hand
Brush Script MT
Chalkboard
Chalkboard SE
Chalkduster
Charter
Cochin
Comic Sans MS
Copperplate
Corsiva Hebrew
Courier
Courier New
DIN Alternate
DIN Condensed
Damascus
DecoType Naskh
Devanagari MT
Devanagari Sangam MN
Didot
Diwan Kufi
Diwan Thuluth
Euphemia UCAS
Farah
Farisi
Futura
GB18030 Bitmap
Galvji
Geeza Pro
Geneva
Georgia
Gill Sans
Gujarati MT
Gujarati Sangam MN
Gurmukhi MN
Gurmukhi MT
Gurmukhi Sangam MN
Heiti SC
Heiti TC
Helvetica
Helvetica Neue
Herculanum
Hiragino Maru Gothic ProN
Hiragino Mincho ProN
Hiragino Sans
Hiragino Sans GB
Hoefler Text
ITF Devanagari
ITF Devanagari Marathi
Impact
InaiMathi
Kailasa
Kannada MN
Kannada Sangam MN
Kefa
Khmer MN
Khmer Sangam MN
Kohinoor Bangla
Kohinoor Devanagari
Kohinoor Gujarati
Kohinoor Telugu
Kokonor
Krungthep
KufiStandardGK
Lao MN
Lao Sangam MN
Lucida Bright
Lucida Grande
Lucida Sans
Lucida Sans Typewriter
Luminari
Malayalam MN
Malayalam Sangam MN
Marker Felt
Menlo
Microsoft Sans Serif
Mishafi
Mishafi Gold
Monaco
Monospaced
Mshtakan
Mukta Mahee
Muna
Myanmar MN
Myanmar Sangam MN
Nadeem
New Peninim MT
Noteworthy
Noto Nastaliq Urdu
Noto Sans Javanese
Noto Sans Kannada
Noto Sans Myanmar
Noto Sans Oriya
Noto Serif Myanmar
Optima
Oriya MN
Oriya Sangam MN
PT Mono
PT Sans
PT Sans Caption
PT Sans Narrow
PT Serif
PT Serif Caption
Palatino
Papyrus
Phosphate
PingFang HK
PingFang SC
PingFang TC
Plantagenet Cherokee
Raanana
Rockwell
STIXGeneral
STIXIntegralsD
STIXIntegralsSm
STIXIntegralsUp
STIXIntegralsUpD
STIXIntegralsUpSm
STIXNonUnicode
STIXSizeFiveSym
STIXSizeFourSym
STIXSizeOneSym
STIXSizeThreeSym
STIXSizeTwoSym
STIXVariants
STSong
Sana
SansSerif
Sathu
Savoye LET
Serif
Shree Devanagari 714
SignPainter
Silom
Sinhala MN
Sinhala Sangam MN
Skia
Snell Roundhand
Songti SC
Songti TC
Sukhumvit Set
Symbol
System
Tahoma
Tamil MN
Tamil Sangam MN
Telugu MN
Telugu Sangam MN
Thonburi
Times
Times New Roman
Trattatello
Trebuchet MS
Verdana
Waseem
Webdings
Wingdings
Wingdings 2
Wingdings 3
Zapf Dingbats
Zapfino
Previous Next Home
No comments:
Post a Comment