osx - Get correct NSRect in NSTextView when image insert -
i use [nstextview firstrectforcharacterrange:actualrange:] , [nslayoutmanager boundingrectforglyphrange:intextcontainer:] cursor rect, works right when pure text in nstextview.
but when insert image text view, [nstextview firstrectforcharacterrange:actualrange:] return wrong result(nsrectzero), , [nslayoutmanager boundingrectforglyphrange:intextcontainer:] return right value in textview convert superview wrong.
only when image bigger textview bounds happen.
anyone knows how resolve that?
Comments
Post a Comment