FROM : Adam R. Maxwell
DATE : Sun Jul 23 16:51:47 2006
On Jul 23, 2006, at 07:16, Keith Blount wrote:
> Thanks for your reply - much appreciated.
>
> I tried your idea, but the trouble with using the
> string methods directly, such as in your example, is
> that all of the formatting and attributes of the
> attributed string get stripped, which is obviously
> counter-productive.
Interesting; according to the documentation for -mutableString, that
shouldn't happen, since changes to it are supposed to be tracked by
the attributed string. Poking around in the debugger with a test
project shows that [[NSMutableAttributedString mutableString] class]
returns NSMutableStringProxyForMutableAttributedString, so presumably
this is another toll-free bridging bug.
You can still operate on it with NSMutableString Obj-C methods, which
would avoid the overhead of using [newStr string] in your code.
-- Adam
DATE : Sun Jul 23 16:51:47 2006
On Jul 23, 2006, at 07:16, Keith Blount wrote:
> Thanks for your reply - much appreciated.
>
> I tried your idea, but the trouble with using the
> string methods directly, such as in your example, is
> that all of the formatting and attributes of the
> attributed string get stripped, which is obviously
> counter-productive.
Interesting; according to the documentation for -mutableString, that
shouldn't happen, since changes to it are supposed to be tracked by
the attributed string. Poking around in the debugger with a test
project shows that [[NSMutableAttributedString mutableString] class]
returns NSMutableStringProxyForMutableAttributedString, so presumably
this is another toll-free bridging bug.
You can still operate on it with NSMutableString Obj-C methods, which
would avoid the overhead of using [newStr string] in your code.
-- Adam
| Related mails | Author | Date |
|---|---|---|
| Keith Blount | Jul 23, 12:44 | |
| Adam R. Maxwell | Jul 23, 16:08 | |
| Keith Blount | Jul 23, 16:16 | |
| Justin Anderson | Jul 23, 16:44 | |
| Adam R. Maxwell | Jul 23, 16:51 |






Cocoa mail archive

