Skip to content

Commit 4364bd0

Browse files
SnipxiText-CI
authored andcommitted
Allow overriding default font family easier for BasicFontProvider
DEVSIX-3353 Autoported commit. Original commit hash: [f6cdc58b7]
1 parent 3f3f28e commit 4364bd0

File tree

2 files changed

+17
-2
lines changed

2 files changed

+17
-2
lines changed

itext/itext.styledxmlparser/itext/styledxmlparser/resolver/font/BasicFontProvider.cs

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,22 @@ public BasicFontProvider()
7171
/// <param name="registerSystemFonts">use true if you want to register the system fonts (can require quite some resources)
7272
/// </param>
7373
public BasicFontProvider(bool registerStandardPdfFonts, bool registerSystemFonts)
74-
: base(DEFAULT_FONT_FAMILY) {
74+
: this(registerStandardPdfFonts, registerSystemFonts, DEFAULT_FONT_FAMILY) {
75+
}
76+
77+
/// <summary>
78+
/// Creates a new
79+
/// <see cref="BasicFontProvider"/>
80+
/// instance.
81+
/// </summary>
82+
/// <param name="registerStandardPdfFonts">use true if you want to register the standard Type 1 fonts (can't be embedded)
83+
/// </param>
84+
/// <param name="registerSystemFonts">use true if you want to register the system fonts (can require quite some resources)
85+
/// </param>
86+
/// <param name="defaultFontFamily">default font family</param>
87+
public BasicFontProvider(bool registerStandardPdfFonts, bool registerSystemFonts, String defaultFontFamily
88+
)
89+
: base(defaultFontFamily) {
7590
if (registerStandardPdfFonts) {
7691
AddStandardPdfFonts();
7792
}

port-hash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
ed6b5b94e505da5cddb462921cf68e366b6ff4f9
1+
f6cdc58b70f08792365e8c42d30db9b23dbbd0cf

0 commit comments

Comments
 (0)