GithubHelp home page GithubHelp logo

deni2s / ibcustomfonts Goto Github PK

View Code? Open in Web Editor NEW
211.0 211.0 25.0 288 KB

IBCustomFonts category allows you to use custom fonts from Interface Builder (IB) when building your iOS apps. Apps using IBCustomFonts category are approved by Apple App Store (check readme.md on latest info). Tested on iOS6 - iOS11.

License: MIT License

Objective-C 100.00%
custom-fonts fonts interface-builder ios

ibcustomfonts's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ibcustomfonts's Issues

iOS11 No Worky

I know this probably is not maintained any longer.. but iOS11 broke it. Any chance of taking a look? It is still a great utility. Thanks!

Not working in iOS 7.0.3/Xcode 5.0.2

Hi,

I did follow all the steps that you had mentioned, yet I still see the default fonts used in IB. The sample project attached doesn't seem to work as well.

UIFont+IBCustomFonts crashing when using MKMapView

Hi,

I'm trying to add a MKMapView to my app and I can't.
My app has nothing but the AppDelegate.
I'm creating the window, rootViewController, and adding the MapView.
The app is crashing in the init method of the MapView with this error message and stack trace below.
I know it is related to IBCustomFonts because when I remove it from the project, everything works fine.

2014-01-20 19:16:59.446 ppd[50655:70b] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '* -[**NSPlaceholderDictionary initWithObjects:forKeys:count:]: attempt to insert nil object from objects[0]'
* First throw call stack:
(
0 CoreFoundation 0x026c15e4 __exceptionPreprocess + 180
1 libobjc.A.dylib 0x024448b6 objc_exception_throw + 44
2 CoreFoundation 0x026874c6 -[__NSPlaceholderDictionary initWithObjects:forKeys:count:] + 390
3 CoreFoundation 0x026b5029 +[NSDictionary dictionaryWithObjects:forKeys:count:] + 73
4 MapKit 0x01ee3fcb -[MKAttributionLabel _attributesWithStroke:] + 528
5 MapKit 0x01ee404b -[MKAttributionLabel _prepareLabel] + 108
6 MapKit 0x01ee3d7d -[MKAttributionLabel init] + 183
7 MapKit 0x01eaf265 -[MKMapView _updateAttribution] + 829
8 MapKit 0x01ead9ad -[MKMapView _commonInitAndEnableLoading:fromIB:] + 2621
9 MapKit 0x01eadb31 -[MKMapView initWithFrame:] + 149
10 ppd 0x00016cf7 -[PPDAppDelegate application:didFinishLaunchingWithOptions:] + 487
11 UIKit 0x01039355 -[UIApplication _handleDelegateCallbacksWithOptions:isSuspended:restoreState:] + 309
12 UIKit 0x01039b95 -[UIApplication _callInitializationDelegatesForURL:payload:suspended:] + 1536
13 UIKit 0x0103e3a8 -[UIApplication _runWithURL:payload:launchOrientation:statusBarStyle:statusBarHidden:] + 824
14 UIKit 0x0105287c -[UIApplication handleEvent:withNewEvent:] + 3447
15 UIKit 0x01052de9 -[UIApplication sendEvent:] + 85
16 UIKit 0x01040025 _UIApplicationHandleEvent + 736
17 GraphicsServices 0x05c832f6 _PurpleEventCallback + 776
18 GraphicsServices 0x05c82e01 PurpleEventCallback + 46
19 CoreFoundation 0x0263cd65 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION
+ 53
20 CoreFoundation 0x0263ca9b __CFRunLoopDoSource1 + 523
21 CoreFoundation 0x0266777c __CFRunLoopRun + 2156
22 CoreFoundation 0x02666ac3 CFRunLoopRunSpecific + 467
23 CoreFoundation 0x026668db CFRunLoopRunInMode + 123
24 UIKit 0x0103dadd -[UIApplication _run] + 840
25 UIKit 0x0103fd3b UIApplicationMain + 1225
26 ppd 0x0000a2f7 main + 167
27 libdyld.dylib 0x030b970d start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException

Font doesn't change

I just download the code but when I use Regular font in IB it doesn't do the work, just in Bold...
Thanks

Not working with UIAlertView on iOS 7

UIAlertView seems to use a private font, which is not available for fontDescriptorWithName:. As a result the UIAlertView titles are not displayed when using the IBCustomFonts swizzling.
Made it work by calling directly the original method :

+(UIFont_)new_fontWithDescriptor:(UIFontDescriptor_)descriptor size:(CGFloat)fontSize {
NSString* newName = [iBCustomFontsDict objectForKey:[descriptor.fontAttributes objectForKey:UIFontDescriptorNameAttribute]];

return [self new_fontWithDescriptor:
                newName ?
                [UIFontDescriptor fontDescriptorWithName:newName size:fontSize] :
                descriptor
        size:fontSize];

}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.