mirror of
https://gh-proxy.org/https://github.com/klinsmaya/dashjim.github.com.git
synced 2026-11-08 17:36:53 +08:00
加入core text例子的图片
This commit is contained in:
@@ -150,6 +150,9 @@ CFMutableAttributedStringRef和NSMutableAttributedString就是其中的一对,
|
||||
callbacks的结构体为CTRunDelegateCallbacks,主要是包含一些回调函数,比如有返回当前run的ascent,descent,width这些值的回调函数,至于函数中如何鉴别当前是哪个run,可以在CTRunDelegateCreate的第二个参数来达到目的,因为CTRunDelegateCreate的第二个参数会作为每一个回调调用时的入参。
|
||||
|
||||
###三.Core Text实战
|
||||
这里使用Core Text实现一个和之前NSTextView显示类似的图文混排的例子。
|
||||
|
||||

|
||||
|
||||
直接贴上代码大家体会下:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user