Typeface 생성자

정의

Typeface 클래스의 새 인스턴스를 초기화합니다.

오버로드

Typeface(String)

지정된 글꼴 패밀리 서체 이름에 대한 Typeface 클래스의 새 인스턴스를 초기화합니다.

Typeface(FontFamily, FontStyle, FontWeight, FontStretch)

지정된 글꼴 패밀리 이름, Typeface, StyleWeight 값에 대한 Stretch 클래스의 새 인스턴스를 초기화합니다.

Typeface(FontFamily, FontStyle, FontWeight, FontStretch, FontFamily)

지정된 글꼴 패밀리 이름, Typeface, StyleWeight 값에 대한 Stretch 클래스의 새 인스턴스를 초기화합니다. 대체 글꼴 패밀리도 지정됩니다.

Typeface(String)

지정된 글꼴 패밀리 서체 이름에 대한 Typeface 클래스의 새 인스턴스를 초기화합니다.

public:
 Typeface(System::String ^ typefaceName);
public Typeface (string typefaceName);
new System.Windows.Media.Typeface : string -> System.Windows.Media.Typeface
Public Sub New (typefaceName As String)

매개 변수

typefaceName
String

지정된 글꼴 패밀리에 대한 서체 이름입니다.

예제

// Return the typeface for the selected font family name.
Typeface typeface1 = new Typeface("Verdana");

// Return the typeface for the selected font family name and font values.
Typeface typeface2 = new Typeface(new FontFamily("file:///C:\\MyFonts\\#Pericles Light"),
                                                 FontStyles.Italic,
                                                 FontWeights.ExtraBold,
                                                 FontStretches.Condensed);

// Return the typeface for the selected font family name, font values, and fallback font family name.
Typeface typeface3 = new Typeface(new FontFamily("file:///C:\\MyFonts\\#Pericles"),
                                                 FontStyles.Italic,
                                                 FontWeights.ExtraBold,
                                                 FontStretches.Condensed,
                                                 new FontFamily("Arial"));
' Return the typeface for the selected font family name.
Dim typeface1 As New Typeface("Verdana")

' Return the typeface for the selected font family name and font values.
Dim typeface2 As New Typeface(New FontFamily("file:///C:\MyFonts\#Pericles Light"), FontStyles.Italic, FontWeights.ExtraBold, FontStretches.Condensed)

' Return the typeface for the selected font family name, font values, and fallback font family name.
Dim typeface3 As New Typeface(New FontFamily("file:///C:\MyFonts\#Pericles"), FontStyles.Italic, FontWeights.ExtraBold, FontStretches.Condensed, New FontFamily("Arial"))

적용 대상

Typeface(FontFamily, FontStyle, FontWeight, FontStretch)

지정된 글꼴 패밀리 이름, Typeface, StyleWeight 값에 대한 Stretch 클래스의 새 인스턴스를 초기화합니다.

public:
 Typeface(System::Windows::Media::FontFamily ^ fontFamily, System::Windows::FontStyle style, System::Windows::FontWeight weight, System::Windows::FontStretch stretch);
public Typeface (System.Windows.Media.FontFamily fontFamily, System.Windows.FontStyle style, System.Windows.FontWeight weight, System.Windows.FontStretch stretch);
new System.Windows.Media.Typeface : System.Windows.Media.FontFamily * System.Windows.FontStyle * System.Windows.FontWeight * System.Windows.FontStretch -> System.Windows.Media.Typeface
Public Sub New (fontFamily As FontFamily, style As FontStyle, weight As FontWeight, stretch As FontStretch)

매개 변수

fontFamily
FontFamily

서체의 글꼴 패밀리입니다.

style
FontStyle

서체의 스타일입니다.

weight
FontWeight

서체의 상대적 두께입니다.

stretch
FontStretch

서체가 늘어나는 정도입니다.

예제

// Return the typeface for the selected font family name.
Typeface typeface1 = new Typeface("Verdana");

// Return the typeface for the selected font family name and font values.
Typeface typeface2 = new Typeface(new FontFamily("file:///C:\\MyFonts\\#Pericles Light"),
                                                 FontStyles.Italic,
                                                 FontWeights.ExtraBold,
                                                 FontStretches.Condensed);

// Return the typeface for the selected font family name, font values, and fallback font family name.
Typeface typeface3 = new Typeface(new FontFamily("file:///C:\\MyFonts\\#Pericles"),
                                                 FontStyles.Italic,
                                                 FontWeights.ExtraBold,
                                                 FontStretches.Condensed,
                                                 new FontFamily("Arial"));
' Return the typeface for the selected font family name.
Dim typeface1 As New Typeface("Verdana")

' Return the typeface for the selected font family name and font values.
Dim typeface2 As New Typeface(New FontFamily("file:///C:\MyFonts\#Pericles Light"), FontStyles.Italic, FontWeights.ExtraBold, FontStretches.Condensed)

' Return the typeface for the selected font family name, font values, and fallback font family name.
Dim typeface3 As New Typeface(New FontFamily("file:///C:\MyFonts\#Pericles"), FontStyles.Italic, FontWeights.ExtraBold, FontStretches.Condensed, New FontFamily("Arial"))

적용 대상

Typeface(FontFamily, FontStyle, FontWeight, FontStretch, FontFamily)

지정된 글꼴 패밀리 이름, Typeface, StyleWeight 값에 대한 Stretch 클래스의 새 인스턴스를 초기화합니다. 대체 글꼴 패밀리도 지정됩니다.

public:
 Typeface(System::Windows::Media::FontFamily ^ fontFamily, System::Windows::FontStyle style, System::Windows::FontWeight weight, System::Windows::FontStretch stretch, System::Windows::Media::FontFamily ^ fallbackFontFamily);
public Typeface (System.Windows.Media.FontFamily fontFamily, System.Windows.FontStyle style, System.Windows.FontWeight weight, System.Windows.FontStretch stretch, System.Windows.Media.FontFamily fallbackFontFamily);
new System.Windows.Media.Typeface : System.Windows.Media.FontFamily * System.Windows.FontStyle * System.Windows.FontWeight * System.Windows.FontStretch * System.Windows.Media.FontFamily -> System.Windows.Media.Typeface
Public Sub New (fontFamily As FontFamily, style As FontStyle, weight As FontWeight, stretch As FontStretch, fallbackFontFamily As FontFamily)

매개 변수

fontFamily
FontFamily

서체의 글꼴 패밀리입니다.

style
FontStyle

서체의 스타일입니다.

weight
FontWeight

서체의 상대적 두께입니다.

stretch
FontStretch

서체가 늘어나는 정도입니다.

fallbackFontFamily
FontFamily

fontFamily 매개 변수에 지정된 기본 글꼴 패밀리로 표시할 수 없는 문자가 있는 경우 사용되는 글꼴 패밀리입니다.

예제

// Return the typeface for the selected font family name.
Typeface typeface1 = new Typeface("Verdana");

// Return the typeface for the selected font family name and font values.
Typeface typeface2 = new Typeface(new FontFamily("file:///C:\\MyFonts\\#Pericles Light"),
                                                 FontStyles.Italic,
                                                 FontWeights.ExtraBold,
                                                 FontStretches.Condensed);

// Return the typeface for the selected font family name, font values, and fallback font family name.
Typeface typeface3 = new Typeface(new FontFamily("file:///C:\\MyFonts\\#Pericles"),
                                                 FontStyles.Italic,
                                                 FontWeights.ExtraBold,
                                                 FontStretches.Condensed,
                                                 new FontFamily("Arial"));
' Return the typeface for the selected font family name.
Dim typeface1 As New Typeface("Verdana")

' Return the typeface for the selected font family name and font values.
Dim typeface2 As New Typeface(New FontFamily("file:///C:\MyFonts\#Pericles Light"), FontStyles.Italic, FontWeights.ExtraBold, FontStretches.Condensed)

' Return the typeface for the selected font family name, font values, and fallback font family name.
Dim typeface3 As New Typeface(New FontFamily("file:///C:\MyFonts\#Pericles"), FontStyles.Italic, FontWeights.ExtraBold, FontStretches.Condensed, New FontFamily("Arial"))

설명

전달 null 에 대 한는 fallbackFontFamily 매개 변수 상자 문자는 기본 글꼴 패밀리에 포함 되지 않은 문자에 대 한 표시를 사용 하면 됩니다.

적용 대상