StyledTextKit icon indicating copy to clipboard operation
StyledTextKit copied to clipboard

Declarative building and fast rendering attributed string library.

Results 19 StyledTextKit issues
Sort by recently updated
recently updated
newest added

Once you create the StyledTextRenderer, you would need to create an entirely new object to change one small attribute like font size. This is an expensive process

question

h/t @SD10 for the idea! Inspired by [TTTAttributedLabel](https://github.com/TTTAttributedLabel/TTTAttributedLabel/blob/b0f1f93d5d4368a7aaf52e848013a1b40b00dc3c/TTTAttributedLabel/TTTAttributedLabel.m#L220).

Just curious as if there is a performance tradeoff for creating an attributed string, and then using the convenience initializer of the StyledTextBuilder that takes in an attributed string vs...

In previous impls we also implemented the following caching layers in addition to the current bitmap and size cache: 1. Renderer caching. Saves the layout managers, and is commonly lighter...

Since this is a tool that people should use to build upon, we should have better docblocks to describe more advanced usages of API's. Plus, I LOVE ASCII art.

Idk how best to combine these, but would improve rendering huge chunks of text. - `mmap` bitmap from disk - All layers in memory defeats the purpose - LRUCache can...

- Draw on a bg thread, come back to main to set contents - Technically `CALayer` stuff is thread safe (IIRC from ASDK) - Prevent race conditions

Most text highlighting for large blocks break down into 3 parts, first line, body, and last line. This gives the selection a really nice outline, and also avoids the N^2...