Integrate cut/copy/paste into appropriate functional areas of morpho.
Updated by Matt Jones over 21 years ago
Enable the Cut/Copy/Paste menus when their functionality is available. The
editor makes these functions available, but because the menus are greyed out
this is not at all obvious to users. Need to actively manage the
enabled/diabled state of these menus to show when users can use them and when
Updated by Dan Higgins about 21 years ago
Cut/Copy/Paste menus are now enabled/disabled properly in the new DataPackage
view. Actually, the only items that can currently be Cut/Copy/Pasted in this
view are the data cell in the data table. At least one cell should always be
selected, so Cut/Copy should always be enabled in this window.
Paste should be enabled whenever there is text data in the clipboard. Code has
been added to DataPackagePlugin so that whenever the DataPackage window is
'activated' the clipboard is checked to aee if it contains text (perhaps copied
from Excel, etc.) If it does, the Paste menu is enable; if not, disabled. Cut
and Copy commands withn the window also enable the Paste menu.
It appears that a general purpose Cut/Copy/Paste handler would require that a
CaretListener be added to all TextComponents. Thus, whenever any part of a text
string was selected, the Cut/Copy/Paste menus could be appropriately handled.
This is thought to require a substantial code change, so that it is being
postpned to Target Milestone 1.3