From 9034996f32e5928e21b7f4100b7c4aafb93b3aef Mon Sep 17 00:00:00 2001 From: Roman Podymov Date: Wed, 25 Oct 2023 13:31:29 +0200 Subject: [PATCH 1/2] Adelle Sans Devanagari --- Sources/BuiltInFont.swift | 10 +++++++++ Tests/UIFontCompleteTests.swift | 28 ++++++++++++++++++++++++ UIFontComplete.xcodeproj/project.pbxproj | 10 +++++---- 3 files changed, 44 insertions(+), 4 deletions(-) diff --git a/Sources/BuiltInFont.swift b/Sources/BuiltInFont.swift index 627f6cc..1656bdc 100644 --- a/Sources/BuiltInFont.swift +++ b/Sources/BuiltInFont.swift @@ -106,6 +106,16 @@ public enum BuiltInFont: String, FontRepresentable, CaseIterable { #endif + // MARK: Adelle Sans Devanagari + + case adelleSansDevanagariBold = "Adelle Sans Devanagari Bold" + case adelleSansDevanagariExtrabold = "Adelle Sans Devanagari Extrabold" + case adelleSansDevanagariHeavy = "Adelle Sans Devanagari Heavy" + case adelleSansDevanagariLight = "Adelle Sans Devanagari Light" + case adelleSansDevanagariRegular = "Adelle Sans Devanagari Regular" + case adelleSansDevanagariSemibold = "Adelle Sans Devanagari Semibold" + case adelleSansDevanagariThin = "Adelle Sans Devanagari Thin" + // MARK: American Typewriter case americanTypewriter = "AmericanTypewriter" diff --git a/Tests/UIFontCompleteTests.swift b/Tests/UIFontCompleteTests.swift index 1dcfced..0fa2954 100644 --- a/Tests/UIFontCompleteTests.swift +++ b/Tests/UIFontCompleteTests.swift @@ -758,6 +758,34 @@ class UIFontCompleteTests: XCTestCase { func testFontVerdanabold() { XCTAssert(UIFont(font: .verdanaBold, size: 12.0) != nil, "Font \"Verdana-Bold\" can not be found.") } + + func testFontAdelleSansDevanagariBold() { + XCTAssert(UIFont(font: .adelleSansDevanagariBold, size: 12.0) != nil, "Font \"Adelle Sans Devanagari Bold\" can not be found.") + } + + func testFontAdelleSansDevanagariExtrabold() { + XCTAssert(UIFont(font: .adelleSansDevanagariExtrabold, size: 12.0) != nil, "Font \"Adelle Sans Devanagari Extrabold\" can not be found.") + } + + func testForAdelleSansDevanagariHeavy() { + XCTAssert(UIFont(font: .adelleSansDevanagariHeavy, size: 12.0) != nil, "Font \"Adelle Sans Devanagari Heavy\" can not be found.") + } + + func testFontAdelleSansDevanagariLight() { + XCTAssert(UIFont(font: .adelleSansDevanagariLight, size: 12.0) != nil, "Font \"Adelle Sans Devanagari Light\" can not be found.") + } + + func testFontAdelleSansDevanagariRegular() { + XCTAssert(UIFont(font: .adelleSansDevanagariRegular, size: 12.0) != nil, "Font \"Adelle Sans Devanagari Regular\" can not be found.") + } + + func testFontAdelleSansDevanagariSemibold() { + XCTAssert(UIFont(font: .adelleSansDevanagariSemibold, size: 12.0) != nil, "Font \"Adelle Sans Devanagari Semibold\" can not be found.") + } + + func testFontAdelleSansDevanagariThin() { + XCTAssert(UIFont(font: .adelleSansDevanagariThin, size: 12.0) != nil, "Font \"Adelle Sans Devanagari Thin\" can not be found.") + } func testFontAmericantypewritercondensedlight() { XCTAssert(UIFont(font: .americanTypewriterCondensedLight, size: 12.0) != nil, "Font \"AmericanTypewriter-CondensedLight\" can not be found.") diff --git a/UIFontComplete.xcodeproj/project.pbxproj b/UIFontComplete.xcodeproj/project.pbxproj index b825cd8..689dbb3 100644 --- a/UIFontComplete.xcodeproj/project.pbxproj +++ b/UIFontComplete.xcodeproj/project.pbxproj @@ -492,7 +492,7 @@ SDKROOT = appletvos; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = 3; - TVOS_DEPLOYMENT_TARGET = 11.2; + TVOS_DEPLOYMENT_TARGET = 13.0; }; name = Debug; }; @@ -512,7 +512,7 @@ SDKROOT = appletvos; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = 3; - TVOS_DEPLOYMENT_TARGET = 11.2; + TVOS_DEPLOYMENT_TARGET = 13.0; }; name = Release; }; @@ -579,7 +579,7 @@ CODE_SIGN_STYLE = Automatic; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "UIFontComplete-iOSTests/Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 11.2; + IPHONEOS_DEPLOYMENT_TARGET = 13.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.maccharoli.UIFontComplete-iOSTests"; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -599,7 +599,7 @@ CODE_SIGN_STYLE = Automatic; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "UIFontComplete-iOSTests/Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 11.2; + IPHONEOS_DEPLOYMENT_TARGET = 13.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.maccharoli.UIFontComplete-iOSTests"; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -667,6 +667,7 @@ SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; + TVOS_DEPLOYMENT_TARGET = 13.0; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; @@ -723,6 +724,7 @@ SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; + TVOS_DEPLOYMENT_TARGET = 13.0; VALIDATE_PRODUCT = YES; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; From 73d8572f334c3fcf021cb23743e5dd17bea62055 Mon Sep 17 00:00:00 2001 From: Roman Podymov Date: Wed, 25 Oct 2023 13:55:07 +0200 Subject: [PATCH 2/2] Only for iOS and macOS --- Sources/BuiltInFont.swift | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Sources/BuiltInFont.swift b/Sources/BuiltInFont.swift index 1656bdc..6fd58ab 100644 --- a/Sources/BuiltInFont.swift +++ b/Sources/BuiltInFont.swift @@ -108,6 +108,7 @@ public enum BuiltInFont: String, FontRepresentable, CaseIterable { // MARK: Adelle Sans Devanagari + #if os(macOS) || os(iOS) case adelleSansDevanagariBold = "Adelle Sans Devanagari Bold" case adelleSansDevanagariExtrabold = "Adelle Sans Devanagari Extrabold" case adelleSansDevanagariHeavy = "Adelle Sans Devanagari Heavy" @@ -115,6 +116,7 @@ public enum BuiltInFont: String, FontRepresentable, CaseIterable { case adelleSansDevanagariRegular = "Adelle Sans Devanagari Regular" case adelleSansDevanagariSemibold = "Adelle Sans Devanagari Semibold" case adelleSansDevanagariThin = "Adelle Sans Devanagari Thin" + #endif // MARK: American Typewriter