Search code examples
iosobjective-ccocoacore-text

Reusing a CTFrameSetter which was created using CTFramesetterCreateWithAttributedString()?


I have seen multiple mentions of the framesetter being "expensive" I have a couple of different attributed strings which are laid out independently of one another, is there a way to "reuse" the framesetter?


Solution

  • The documented CTFramesetterCreateWithAttributedString and CTFramesetterCreateFrame both return an immutable object. Not going to be able to reuse them, unfortunately.