BonMot icon indicating copy to clipboard operation
BonMot copied to clipboard

Beautiful, easy attributed strings in Swift

Results 58 BonMot issues
Sort by recently updated
recently updated
newest added

It’s come up once or twice in projects, since some protocols that we use with model or state types require that things be `Equatable` for collection diffing reasons. It would...

Hi, I'm trying to convert an HTML snippet with styles and links to an attributed string. What parsing approach would you recommend? Here is the HTML I am trying to...

Before: ```swift var style = StringStyle( .font(someFont), .color(someColor), .minimumLineHeight(28) ) style.adaptations = [.fontMetrics(textStyle: .title1, maxPointSize:nil)] return style ``` After: ```swift return StringStyle( .font(someFont), .color(someColor), .minimumLineHeight(28), .adaptations([.fontMetrics(textStyle: .title1, maxPointSize:nil)]) ) ```

.lineSpacing + .tracking or .adapt .lineSpacing only .lineSpacing + .tracking or .adapt --- This bug appears only with single line strings, this is not a BonMot bug, its probably NSAttributedString...

We can use this `XMLParserDelegate` function: ```swift func parser(_ parser: XMLParser, resolveExternalEntityName name: String, systemID: String?) -> Data? ``` We should be able to handle named entities like `’` (right...

Looks like this is actually a problem with how iOS handles `setAttributedTitle()` on UIButton. We could support the work around, by setting the button's label's `attributedText` first and then using...

Develope Enviroment: XCode 10.1 Mac: 10.14.1 // fail situation ```swift let quote = "『In this situation app will crash, the console report: p_kern_val is null pointer』" let baseStyle = StringStyle(.font(UIFont.systemFont(ofSize:...

We should add something to the readme describing the new feature added in https://github.com/Rightpoint/BonMot/pull/361. @ndonald2 if you have a use case in mind, I’d love to see it documented in...

It's a common request, and shouldn't be that hard to write. I like doing it as a gesture recognizer, because then we can just add it to any existing `UILabel`...

enhancement

# Issue I'm unable to use the `TextAlignmentConstraint` within Interface Builder. Changing the custom constraint class to `TextAlignmentConstraint` has no effect and the attribute extra attributes do not appear in...