├── .github └── FUNDING.yml ├── LICENSE ├── README.md ├── Regular.css ├── Regular ├── CoreFont-Regular.otf ├── CoreFont-Regular.ttf ├── CoreFont-Regular.woff └── CoreFont-Regular.woff2 └── iOS ├── Core Font.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ ├── xcshareddata │ │ └── IDEWorkspaceChecks.plist │ └── xcuserdata │ │ └── ming.xcuserdatad │ │ └── UserInterfaceState.xcuserstate └── xcuserdata │ └── ming.xcuserdatad │ └── xcschemes │ └── xcschememanagement.plist ├── Core Font ├── Assets.xcassets │ ├── AccentColor.colorset │ │ └── Contents.json │ ├── AppIcon.appiconset │ │ └── Contents.json │ ├── Contents.json │ └── bgHero.imageset │ │ ├── Black background blue purple.jpg │ │ └── Contents.json ├── ContentView.swift ├── Core Font.entitlements ├── Core_FontApp.swift ├── Preview Content │ └── Preview Assets.xcassets │ │ └── Contents.json └── Regular.otf └── Core-Font-Info.plist /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: 1998code 4 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 Ming 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Core Font 2 | ## Open Source Font Project. 3 | 4 | Core Font - Open Source Font for Web & Mac/PC | Product Hunt 5 | 6 | ![Lattin](https://fonts.1998.media/Core/Preview/Lattin.png) 7 | ![Number](https://fonts.1998.media/Core/Preview/Number.png) 8 | ![Special](https://fonts.1998.media/Core/Preview/Special.png) 9 | 10 | ## Download 11 | 12 | ### iOS / iPadOS 13 | Download Sample Code: [```/iOS```](https://github.com/1998code/Core-Font/tree/main/iOS) 14 | 15 | Screenshot 2024-06-03 at 10 59 22 PM 16 | 17 | ### Mac / PC 18 | Install the latest release: 19 | - Zip 20 | https://github.com/1998code/Core-Font/releases 21 | 22 | - OTF Only 23 | https://fonts.1998.media/Core/Regular/CoreFont-Regular.otf 24 | 25 | - TTF Only 26 | https://fonts.1998.media/Core/Regular/CoreFont-Regular.ttf 27 | 28 | ## Web CDN 29 | ### Regular 30 | #### CSS 31 | https://fonts.1998.media/Core/Regular.css 32 | #### WOFF 33 | https://fonts.1998.media/Core/Regular/CoreFont-Regular.woff 34 | #### WOFF2 35 | https://fonts.1998.media/Core/Regular/CoreFont-Regular.woff2 36 | 37 | # Sponsorship 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /Regular.css: -------------------------------------------------------------------------------- 1 | *{font-family:CoreFont}@font-face{font-family:CoreFont;src:url(https://fonts.1998.media/Core/Regular/CoreFont-Regular.woff)} -------------------------------------------------------------------------------- /Regular/CoreFont-Regular.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/1998code/Core-Font/5f0f84e8f5a17bca1e8ceb56235e6bc86fa117db/Regular/CoreFont-Regular.otf -------------------------------------------------------------------------------- /Regular/CoreFont-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/1998code/Core-Font/5f0f84e8f5a17bca1e8ceb56235e6bc86fa117db/Regular/CoreFont-Regular.ttf -------------------------------------------------------------------------------- /Regular/CoreFont-Regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/1998code/Core-Font/5f0f84e8f5a17bca1e8ceb56235e6bc86fa117db/Regular/CoreFont-Regular.woff -------------------------------------------------------------------------------- /Regular/CoreFont-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/1998code/Core-Font/5f0f84e8f5a17bca1e8ceb56235e6bc86fa117db/Regular/CoreFont-Regular.woff2 -------------------------------------------------------------------------------- /iOS/Core Font.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 56; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 3ACB84142C0CE35B006A7B83 /* Core_FontApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3ACB84132C0CE35B006A7B83 /* Core_FontApp.swift */; }; 11 | 3ACB84162C0CE35B006A7B83 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3ACB84152C0CE35B006A7B83 /* ContentView.swift */; }; 12 | 3ACB84182C0CE35C006A7B83 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 3ACB84172C0CE35C006A7B83 /* Assets.xcassets */; }; 13 | 3ACB841B2C0CE35C006A7B83 /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 3ACB841A2C0CE35C006A7B83 /* Preview Assets.xcassets */; }; 14 | 3ACB84232C0CE3F4006A7B83 /* Regular.otf in Resources */ = {isa = PBXBuildFile; fileRef = 3ACB84222C0CE3F4006A7B83 /* Regular.otf */; }; 15 | /* End PBXBuildFile section */ 16 | 17 | /* Begin PBXFileReference section */ 18 | 3ACB84102C0CE35B006A7B83 /* Core Font.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Core Font.app"; sourceTree = BUILT_PRODUCTS_DIR; }; 19 | 3ACB84132C0CE35B006A7B83 /* Core_FontApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Core_FontApp.swift; sourceTree = ""; }; 20 | 3ACB84152C0CE35B006A7B83 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; 21 | 3ACB84172C0CE35C006A7B83 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 22 | 3ACB841A2C0CE35C006A7B83 /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; 23 | 3ACB84212C0CE37C006A7B83 /* Core Font.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = "Core Font.entitlements"; sourceTree = ""; }; 24 | 3ACB84222C0CE3F4006A7B83 /* Regular.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = Regular.otf; sourceTree = ""; }; 25 | 3ACB84242C0CF24C006A7B83 /* Core-Font-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; path = "Core-Font-Info.plist"; sourceTree = SOURCE_ROOT; }; 26 | /* End PBXFileReference section */ 27 | 28 | /* Begin PBXFrameworksBuildPhase section */ 29 | 3ACB840D2C0CE35B006A7B83 /* Frameworks */ = { 30 | isa = PBXFrameworksBuildPhase; 31 | buildActionMask = 2147483647; 32 | files = ( 33 | ); 34 | runOnlyForDeploymentPostprocessing = 0; 35 | }; 36 | /* End PBXFrameworksBuildPhase section */ 37 | 38 | /* Begin PBXGroup section */ 39 | 3ACB84072C0CE35B006A7B83 = { 40 | isa = PBXGroup; 41 | children = ( 42 | 3ACB84122C0CE35B006A7B83 /* Core Font */, 43 | 3ACB84112C0CE35B006A7B83 /* Products */, 44 | ); 45 | sourceTree = ""; 46 | }; 47 | 3ACB84112C0CE35B006A7B83 /* Products */ = { 48 | isa = PBXGroup; 49 | children = ( 50 | 3ACB84102C0CE35B006A7B83 /* Core Font.app */, 51 | ); 52 | name = Products; 53 | sourceTree = ""; 54 | }; 55 | 3ACB84122C0CE35B006A7B83 /* Core Font */ = { 56 | isa = PBXGroup; 57 | children = ( 58 | 3ACB84242C0CF24C006A7B83 /* Core-Font-Info.plist */, 59 | 3ACB84212C0CE37C006A7B83 /* Core Font.entitlements */, 60 | 3ACB84132C0CE35B006A7B83 /* Core_FontApp.swift */, 61 | 3ACB84152C0CE35B006A7B83 /* ContentView.swift */, 62 | 3ACB84222C0CE3F4006A7B83 /* Regular.otf */, 63 | 3ACB84172C0CE35C006A7B83 /* Assets.xcassets */, 64 | 3ACB84192C0CE35C006A7B83 /* Preview Content */, 65 | ); 66 | path = "Core Font"; 67 | sourceTree = ""; 68 | }; 69 | 3ACB84192C0CE35C006A7B83 /* Preview Content */ = { 70 | isa = PBXGroup; 71 | children = ( 72 | 3ACB841A2C0CE35C006A7B83 /* Preview Assets.xcassets */, 73 | ); 74 | path = "Preview Content"; 75 | sourceTree = ""; 76 | }; 77 | /* End PBXGroup section */ 78 | 79 | /* Begin PBXNativeTarget section */ 80 | 3ACB840F2C0CE35B006A7B83 /* Core Font */ = { 81 | isa = PBXNativeTarget; 82 | buildConfigurationList = 3ACB841E2C0CE35C006A7B83 /* Build configuration list for PBXNativeTarget "Core Font" */; 83 | buildPhases = ( 84 | 3ACB840C2C0CE35B006A7B83 /* Sources */, 85 | 3ACB840D2C0CE35B006A7B83 /* Frameworks */, 86 | 3ACB840E2C0CE35B006A7B83 /* Resources */, 87 | ); 88 | buildRules = ( 89 | ); 90 | dependencies = ( 91 | ); 92 | name = "Core Font"; 93 | productName = "Core Font"; 94 | productReference = 3ACB84102C0CE35B006A7B83 /* Core Font.app */; 95 | productType = "com.apple.product-type.application"; 96 | }; 97 | /* End PBXNativeTarget section */ 98 | 99 | /* Begin PBXProject section */ 100 | 3ACB84082C0CE35B006A7B83 /* Project object */ = { 101 | isa = PBXProject; 102 | attributes = { 103 | BuildIndependentTargetsInParallel = 1; 104 | LastSwiftUpdateCheck = 1530; 105 | LastUpgradeCheck = 1530; 106 | TargetAttributes = { 107 | 3ACB840F2C0CE35B006A7B83 = { 108 | CreatedOnToolsVersion = 15.3; 109 | }; 110 | }; 111 | }; 112 | buildConfigurationList = 3ACB840B2C0CE35B006A7B83 /* Build configuration list for PBXProject "Core Font" */; 113 | compatibilityVersion = "Xcode 14.0"; 114 | developmentRegion = en; 115 | hasScannedForEncodings = 0; 116 | knownRegions = ( 117 | en, 118 | Base, 119 | ); 120 | mainGroup = 3ACB84072C0CE35B006A7B83; 121 | productRefGroup = 3ACB84112C0CE35B006A7B83 /* Products */; 122 | projectDirPath = ""; 123 | projectRoot = ""; 124 | targets = ( 125 | 3ACB840F2C0CE35B006A7B83 /* Core Font */, 126 | ); 127 | }; 128 | /* End PBXProject section */ 129 | 130 | /* Begin PBXResourcesBuildPhase section */ 131 | 3ACB840E2C0CE35B006A7B83 /* Resources */ = { 132 | isa = PBXResourcesBuildPhase; 133 | buildActionMask = 2147483647; 134 | files = ( 135 | 3ACB841B2C0CE35C006A7B83 /* Preview Assets.xcassets in Resources */, 136 | 3ACB84182C0CE35C006A7B83 /* Assets.xcassets in Resources */, 137 | 3ACB84232C0CE3F4006A7B83 /* Regular.otf in Resources */, 138 | ); 139 | runOnlyForDeploymentPostprocessing = 0; 140 | }; 141 | /* End PBXResourcesBuildPhase section */ 142 | 143 | /* Begin PBXSourcesBuildPhase section */ 144 | 3ACB840C2C0CE35B006A7B83 /* Sources */ = { 145 | isa = PBXSourcesBuildPhase; 146 | buildActionMask = 2147483647; 147 | files = ( 148 | 3ACB84162C0CE35B006A7B83 /* ContentView.swift in Sources */, 149 | 3ACB84142C0CE35B006A7B83 /* Core_FontApp.swift in Sources */, 150 | ); 151 | runOnlyForDeploymentPostprocessing = 0; 152 | }; 153 | /* End PBXSourcesBuildPhase section */ 154 | 155 | /* Begin XCBuildConfiguration section */ 156 | 3ACB841C2C0CE35C006A7B83 /* Debug */ = { 157 | isa = XCBuildConfiguration; 158 | buildSettings = { 159 | ALWAYS_SEARCH_USER_PATHS = NO; 160 | ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; 161 | CLANG_ANALYZER_NONNULL = YES; 162 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 163 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; 164 | CLANG_ENABLE_MODULES = YES; 165 | CLANG_ENABLE_OBJC_ARC = YES; 166 | CLANG_ENABLE_OBJC_WEAK = YES; 167 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 168 | CLANG_WARN_BOOL_CONVERSION = YES; 169 | CLANG_WARN_COMMA = YES; 170 | CLANG_WARN_CONSTANT_CONVERSION = YES; 171 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 172 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 173 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 174 | CLANG_WARN_EMPTY_BODY = YES; 175 | CLANG_WARN_ENUM_CONVERSION = YES; 176 | CLANG_WARN_INFINITE_RECURSION = YES; 177 | CLANG_WARN_INT_CONVERSION = YES; 178 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 179 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 180 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 181 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 182 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 183 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 184 | CLANG_WARN_STRICT_PROTOTYPES = YES; 185 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 186 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 187 | CLANG_WARN_UNREACHABLE_CODE = YES; 188 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 189 | COPY_PHASE_STRIP = NO; 190 | DEBUG_INFORMATION_FORMAT = dwarf; 191 | ENABLE_STRICT_OBJC_MSGSEND = YES; 192 | ENABLE_TESTABILITY = YES; 193 | ENABLE_USER_SCRIPT_SANDBOXING = YES; 194 | GCC_C_LANGUAGE_STANDARD = gnu17; 195 | GCC_DYNAMIC_NO_PIC = NO; 196 | GCC_NO_COMMON_BLOCKS = YES; 197 | GCC_OPTIMIZATION_LEVEL = 0; 198 | GCC_PREPROCESSOR_DEFINITIONS = ( 199 | "DEBUG=1", 200 | "$(inherited)", 201 | ); 202 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 203 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 204 | GCC_WARN_UNDECLARED_SELECTOR = YES; 205 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 206 | GCC_WARN_UNUSED_FUNCTION = YES; 207 | GCC_WARN_UNUSED_VARIABLE = YES; 208 | IPHONEOS_DEPLOYMENT_TARGET = 17.0; 209 | LOCALIZATION_PREFERS_STRING_CATALOGS = YES; 210 | MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; 211 | MTL_FAST_MATH = YES; 212 | ONLY_ACTIVE_ARCH = YES; 213 | SDKROOT = iphoneos; 214 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)"; 215 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 216 | }; 217 | name = Debug; 218 | }; 219 | 3ACB841D2C0CE35C006A7B83 /* Release */ = { 220 | isa = XCBuildConfiguration; 221 | buildSettings = { 222 | ALWAYS_SEARCH_USER_PATHS = NO; 223 | ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; 224 | CLANG_ANALYZER_NONNULL = YES; 225 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 226 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; 227 | CLANG_ENABLE_MODULES = YES; 228 | CLANG_ENABLE_OBJC_ARC = YES; 229 | CLANG_ENABLE_OBJC_WEAK = YES; 230 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 231 | CLANG_WARN_BOOL_CONVERSION = YES; 232 | CLANG_WARN_COMMA = YES; 233 | CLANG_WARN_CONSTANT_CONVERSION = YES; 234 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 235 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 236 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 237 | CLANG_WARN_EMPTY_BODY = YES; 238 | CLANG_WARN_ENUM_CONVERSION = YES; 239 | CLANG_WARN_INFINITE_RECURSION = YES; 240 | CLANG_WARN_INT_CONVERSION = YES; 241 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 242 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 243 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 244 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 245 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 246 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 247 | CLANG_WARN_STRICT_PROTOTYPES = YES; 248 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 249 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 250 | CLANG_WARN_UNREACHABLE_CODE = YES; 251 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 252 | COPY_PHASE_STRIP = NO; 253 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 254 | ENABLE_NS_ASSERTIONS = NO; 255 | ENABLE_STRICT_OBJC_MSGSEND = YES; 256 | ENABLE_USER_SCRIPT_SANDBOXING = YES; 257 | GCC_C_LANGUAGE_STANDARD = gnu17; 258 | GCC_NO_COMMON_BLOCKS = YES; 259 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 260 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 261 | GCC_WARN_UNDECLARED_SELECTOR = YES; 262 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 263 | GCC_WARN_UNUSED_FUNCTION = YES; 264 | GCC_WARN_UNUSED_VARIABLE = YES; 265 | IPHONEOS_DEPLOYMENT_TARGET = 17.0; 266 | LOCALIZATION_PREFERS_STRING_CATALOGS = YES; 267 | MTL_ENABLE_DEBUG_INFO = NO; 268 | MTL_FAST_MATH = YES; 269 | SDKROOT = iphoneos; 270 | SWIFT_COMPILATION_MODE = wholemodule; 271 | VALIDATE_PRODUCT = YES; 272 | }; 273 | name = Release; 274 | }; 275 | 3ACB841F2C0CE35C006A7B83 /* Debug */ = { 276 | isa = XCBuildConfiguration; 277 | buildSettings = { 278 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 279 | ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; 280 | CODE_SIGN_ENTITLEMENTS = "Core Font/Core Font.entitlements"; 281 | CODE_SIGN_STYLE = Automatic; 282 | CURRENT_PROJECT_VERSION = 1; 283 | DEVELOPMENT_ASSET_PATHS = "\"Core Font/Preview Content\""; 284 | DEVELOPMENT_TEAM = ""; 285 | ENABLE_PREVIEWS = YES; 286 | GENERATE_INFOPLIST_FILE = YES; 287 | INFOPLIST_FILE = "Core-Font-Info.plist"; 288 | INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; 289 | INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; 290 | INFOPLIST_KEY_UILaunchScreen_Generation = YES; 291 | INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait"; 292 | INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown"; 293 | LD_RUNPATH_SEARCH_PATHS = ( 294 | "$(inherited)", 295 | "@executable_path/Frameworks", 296 | ); 297 | MARKETING_VERSION = 1.0; 298 | PRODUCT_BUNDLE_IDENTIFIER = "media.1998.Core-Font"; 299 | PRODUCT_NAME = "$(TARGET_NAME)"; 300 | SWIFT_EMIT_LOC_STRINGS = YES; 301 | SWIFT_VERSION = 5.0; 302 | TARGETED_DEVICE_FAMILY = "1,2"; 303 | }; 304 | name = Debug; 305 | }; 306 | 3ACB84202C0CE35C006A7B83 /* Release */ = { 307 | isa = XCBuildConfiguration; 308 | buildSettings = { 309 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 310 | ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; 311 | CODE_SIGN_ENTITLEMENTS = "Core Font/Core Font.entitlements"; 312 | CODE_SIGN_STYLE = Automatic; 313 | CURRENT_PROJECT_VERSION = 1; 314 | DEVELOPMENT_ASSET_PATHS = "\"Core Font/Preview Content\""; 315 | DEVELOPMENT_TEAM = ""; 316 | ENABLE_PREVIEWS = YES; 317 | GENERATE_INFOPLIST_FILE = YES; 318 | INFOPLIST_FILE = "Core-Font-Info.plist"; 319 | INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; 320 | INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; 321 | INFOPLIST_KEY_UILaunchScreen_Generation = YES; 322 | INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait"; 323 | INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown"; 324 | LD_RUNPATH_SEARCH_PATHS = ( 325 | "$(inherited)", 326 | "@executable_path/Frameworks", 327 | ); 328 | MARKETING_VERSION = 1.0; 329 | PRODUCT_BUNDLE_IDENTIFIER = "media.1998.Core-Font"; 330 | PRODUCT_NAME = "$(TARGET_NAME)"; 331 | SWIFT_EMIT_LOC_STRINGS = YES; 332 | SWIFT_VERSION = 5.0; 333 | TARGETED_DEVICE_FAMILY = "1,2"; 334 | }; 335 | name = Release; 336 | }; 337 | /* End XCBuildConfiguration section */ 338 | 339 | /* Begin XCConfigurationList section */ 340 | 3ACB840B2C0CE35B006A7B83 /* Build configuration list for PBXProject "Core Font" */ = { 341 | isa = XCConfigurationList; 342 | buildConfigurations = ( 343 | 3ACB841C2C0CE35C006A7B83 /* Debug */, 344 | 3ACB841D2C0CE35C006A7B83 /* Release */, 345 | ); 346 | defaultConfigurationIsVisible = 0; 347 | defaultConfigurationName = Release; 348 | }; 349 | 3ACB841E2C0CE35C006A7B83 /* Build configuration list for PBXNativeTarget "Core Font" */ = { 350 | isa = XCConfigurationList; 351 | buildConfigurations = ( 352 | 3ACB841F2C0CE35C006A7B83 /* Debug */, 353 | 3ACB84202C0CE35C006A7B83 /* Release */, 354 | ); 355 | defaultConfigurationIsVisible = 0; 356 | defaultConfigurationName = Release; 357 | }; 358 | /* End XCConfigurationList section */ 359 | }; 360 | rootObject = 3ACB84082C0CE35B006A7B83 /* Project object */; 361 | } 362 | -------------------------------------------------------------------------------- /iOS/Core Font.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /iOS/Core Font.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /iOS/Core Font.xcodeproj/project.xcworkspace/xcuserdata/ming.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/1998code/Core-Font/5f0f84e8f5a17bca1e8ceb56235e6bc86fa117db/iOS/Core Font.xcodeproj/project.xcworkspace/xcuserdata/ming.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /iOS/Core Font.xcodeproj/xcuserdata/ming.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | Core Font.xcscheme_^#shared#^_ 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /iOS/Core Font/Assets.xcassets/AccentColor.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "colors" : [ 3 | { 4 | "idiom" : "universal" 5 | } 6 | ], 7 | "info" : { 8 | "author" : "xcode", 9 | "version" : 1 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /iOS/Core Font/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "platform" : "ios", 6 | "size" : "1024x1024" 7 | } 8 | ], 9 | "info" : { 10 | "author" : "xcode", 11 | "version" : 1 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /iOS/Core Font/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /iOS/Core Font/Assets.xcassets/bgHero.imageset/Black background blue purple.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/1998code/Core-Font/5f0f84e8f5a17bca1e8ceb56235e6bc86fa117db/iOS/Core Font/Assets.xcassets/bgHero.imageset/Black background blue purple.jpg -------------------------------------------------------------------------------- /iOS/Core Font/Assets.xcassets/bgHero.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "Black background blue purple.jpg", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /iOS/Core Font/ContentView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ContentView.swift 3 | // Core Font 4 | // 5 | // Created by Ming on 3/6/2024. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct ContentView: View { 11 | @AppStorage("isFontInstalled") private var isFontInstalled = false 12 | var body: some View { 13 | NavigationStack { 14 | ZStack { 15 | Image("bgHero") 16 | .resizable() 17 | .scaledToFill() 18 | .blur(radius: 15) 19 | .ignoresSafeArea(.all) 20 | VStack { 21 | Spacer() 22 | VStack(alignment: .leading) { 23 | Text("ABCDEFGHIJKLMNOPQRSTUVWXYZ") 24 | Text("abcdefghijklmnopqrstuvwxyz") 25 | Text("1234567890") 26 | } 27 | .font(.custom("CoreFont-Regular", size: 40)) 28 | .padding() 29 | Spacer() 30 | Button(action: { 31 | isFontInstalled ? uninstallFont() : installFont() 32 | }) { 33 | Text(isFontInstalled ? "Installed" : "INSTALL NOW") 34 | .font(.custom("CoreFont-Regular", size: 25)) 35 | }.buttonStyle(.borderedProminent) 36 | .disabled(isFontInstalled) 37 | }.frame(width: 350, height: 550) 38 | } 39 | .navigationTitle("Preview") 40 | .toolbar { 41 | Text("Regular") 42 | .font(.custom("CoreFont-Regular", size: 20)) 43 | } 44 | } 45 | } 46 | 47 | func installFont() { 48 | let fontURLs = [Bundle.main.url(forResource: "Regular", withExtension: "otf")!] as CFArray 49 | 50 | CTFontManagerRegisterFontURLs(fontURLs, .none, true) { errors, done in 51 | if done { 52 | print("Fonts registered successfully") 53 | isFontInstalled = true 54 | } else { 55 | print("Font registration failed: \(errors)") 56 | } 57 | return true 58 | } 59 | 60 | // for familyName in UIFont.familyNames { 61 | // for fontName in UIFont.fontNames(forFamilyName: familyName) { 62 | // print(fontName) 63 | // } 64 | // } 65 | } 66 | 67 | func uninstallFont() { 68 | let fontName = "CoreFont-Regular" 69 | var error: Unmanaged? 70 | CTFontManagerUnregisterFontsForURL(Bundle.main.url(forResource: "Regular", withExtension: "otf")! as CFURL, .none, &error) 71 | if let error = error { 72 | print("Failed to unregister font: \(error.takeUnretainedValue())") 73 | } else { 74 | print("Font unregistered successfully") 75 | isFontInstalled = false 76 | } 77 | } 78 | } 79 | 80 | #Preview { 81 | ContentView() 82 | } 83 | -------------------------------------------------------------------------------- /iOS/Core Font/Core Font.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.developer.user-fonts 6 | 7 | app-usage 8 | system-installation 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /iOS/Core Font/Core_FontApp.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Core_FontApp.swift 3 | // Core Font 4 | // 5 | // Created by Ming on 3/6/2024. 6 | // 7 | 8 | import SwiftUI 9 | 10 | @main 11 | struct Core_FontApp: App { 12 | var body: some Scene { 13 | WindowGroup { 14 | ContentView() 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /iOS/Core Font/Preview Content/Preview Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /iOS/Core Font/Regular.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/1998code/Core-Font/5f0f84e8f5a17bca1e8ceb56235e6bc86fa117db/iOS/Core Font/Regular.otf -------------------------------------------------------------------------------- /iOS/Core-Font-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | UIAppFonts 6 | 7 | Regular.otf 8 | 9 | 10 | 11 | --------------------------------------------------------------------------------