osx - NSTextView: Get text changes (insertions and deletions) -
i've got nstextview , -textdidchange: notification. that, can current string value of whole textview, can't figure out how tell what's been deleted , added.
for example, if string in text view this string , user deleted g, how can made aware of change?
is there way achieve this, preferably without subclassing?
there several delegate methods should looking for:
– textview:shouldchangetextinrange:replacementstring: – textview:shouldchangetextinranges:replacementstrings: – textview:shouldchangetypingattributes:toattributes: – textviewdidchangetypingattributes:
Comments
Post a Comment