Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to make NSTextFieldCell Accept Keyboard copy/paste(cmd+c / cmd+v)

I am writing an editable NSTextFieldCell in a NSTableColumn, and everything goes well.

But I found that my cell can accept the mouse right click copy/paste while does not respond to the keyboard copy/paste (cmd+c / cmd+v).

Could someone please tell me how to make my cell support the keyboard copy/paste ? Should I customize my own cell and implement some method ?

Thanks!

like image 305
Daniel Gao Avatar asked Aug 09 '13 02:08

Daniel Gao


1 Answers

the edit menu items for copy / cut / paste etc, are what map the shortcuts to the actions.

see the similar question here: Cocoa Keyboard Shortcuts in Dialog without an Edit Menu

like image 113
Grady Player Avatar answered Nov 09 '22 18:11

Grady Player