I'm using NSMutableAttributedString to setup text style. When I set .minimumLineHeight, it centre text in line to the bottom of line. I would like to ...
I'm using NSMutableAttributedString to setup text style. When I set .minimumLineHeight, it centre text in line to the bottom of line. I would like to ...
I am trying to make a WYSIWYG editor by interfacing between SwiftUI and UIKit via a UIViewRepresentable. I am primarily using SwiftUI but am using UIK ...
I have created a var with default text attributes for an NSMutableAttributedString: static var textFieldDefaultTextAttributes: [NSAttributedString.Ke ...
So in order to use NSMutableAttributedString with SwiftUI i wrapped a view with UIViewRepresentable, the problem is that the layout breaks after as so ...
The default behavior for UILabel is that it prevents orphan words to appear solely on a separate line. ie: if word wrapping happen to keep 1 word alon ...
I have an NSAttributedString which may have multiple subranges with different font styles and other attributes. How do I modify the size of font for t ...
I have introduced a styled NSViewRepresentable text field on to my layout in order to use an attributed Text Editor field. I want to influence the con ...
In macOS using the same NSMutableAttributedString for a CATextLayer and a NSTextView seems to give different rendering results. The NSTextView has a s ...
I'm allocating an NSMutableAttributedString, then assigning it to the attributedString property of an SKLabelNode. That property is an (NSAttributedSt ...
I have several large PDF docs (70-200, pages each). The PDFs themselves are generated from HTML pages (I can't get the source code of the HTML pages w ...
I want to apply a specific font to an NSMutableAttributedString where no .font attribute is applied. How could I achieve that? I tried enumerating the ...
I need to get anyway to make code style in the UITableView. Simple to make Blue Background Then create NSMutableAttributedString in the UITableVie ...
I need to work with attributed strings (NSMutableAttributedString) in SwiftUI to make a simple rich-text editor, and as you might already know, attrib ...
I am trying to have a NSMutableAttributedString return multiple lines when the text reaches the width. I thought I could use numberOfLines but that ...
I try to make an if block by checking if an NSMutableAttributedString font size is smaller/greater than some value. I couldn't find an explanation abo ...
I have one UILabel which shows strikethrough text (e.g. text ). It was working fine till iOS 13. In iOS 14, that strikethrough line is not showi ...
I need to reduce the text size in order to fit a specific area width. The text contains some different format settings (mainly text color) so I am usi ...
I am looking for align Text in NSAttributedString. It should be on same indent(List of string on same Column). Output: I have used below code ...
I have a UITextField on which I set a current value as attributed text as follows: This was previously just a String but I now need to add formatti ...
I have a string Ex: Arya said "We must find a solution" yesterday. Here I want to restrict the width of the text in bold ("We must find a solution") t ...