When updated Charts to 3.0.4 getting this error in Xcode 9.
Other errors are:
I am also facing errors in most of the Charts classes after updating to 3.0.4
Incorrect argument label in call (have 'withAttributes:', expected 'attributes:')
I also noticed this. I fix it by setting swift version to 4.0 in the charts build settings in xcode

I also fixed it. Thank You
how to fix in an ObjectiveC project?
it should have @objc tag to use, so update your code
attributes: [NSFontAttributeName: label.font]
For Swift 3 use pod 'Charts','= 3.0.3'
I guess this should be fixed in this framework.
Btw, if using Pods:
Ran into this problem with v. 3.1.1, I'm using Swift 4.1
let att: [NSAttributedStringKey: Any] = [
NSAttributedStringKey(rawValue:
NSAttributedStringKey.font.rawValue) : UIFont.italicSystemFont(ofSize: 15.0
),
NSAttributedStringKey(rawValue:
NSAttributedStringKey.foregroundColor.rawValue) : Const.colorBlue500,
NSAttributedStringKey(rawValue:
NSAttributedStringKey.underlineStyle.rawValue) : 1]
let attributeString = NSMutableAttributedString(string:
"open_accessory_sheet".localize,
attributes: att)
For swift 4 .
you can try use it
Vào Th 7, 9 thg 6, 2018 vào lúc 02:43 Jose Manuel Vergara Florez <
[email protected]> đã viết:
Ran into this problem with v. 3.1.1, I'm using Swift 4.2
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/danielgindi/Charts/issues/2816#issuecomment-395868392,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AMLGfjdadIXdyF4cgGGTCaYMQs1sz9CDks5t6tPcgaJpZM4PgNRb
.
let att: [NSAttributedStringKey: Any] = [
NSAttributedStringKey(rawValue: NSAttributedStringKey.font.rawValue) : UIFont.italicSystemFont(ofSize: 15.0),
NSAttributedStringKey(rawValue: NSAttributedStringKey.foregroundColor.rawValue) : Const.colorBlue500,
NSAttributedStringKey(rawValue: NSAttributedStringKey.underlineStyle.rawValue) : 1]
let attributeString = NSMutableAttributedString(string: "open_accessory_sheet".localize,
attributes: att)
Most helpful comment
I also noticed this. I fix it by setting swift version to 4.0 in the charts build settings in xcode
