Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Programmer's Guide to MacApp / Part 2 - Working With MacApp


Chapter 22 -
Working With the Clipboard

This chapter describes MacApp's default Clipboard support and explains how your application can build on that support to handle its own private data types. It also includes recipes and sample code that demonstrate how to

For an introduction to MacApp's Clipboard support, see "Dependencies," beginning on page 44.


Chapter Contents
Overview
Basic Clipboard Operations
Using the Desk Scrap
Using the Toolbox GetScrap Routine
Using a Private Scrap
MacApp's Clipboard Support
More Sophisticated Clipboard Support
The Clipboard Manager
Clipboard Support in TCommand
Recipes--The Clipboard
Interacting With the Macintosh Clipboard--A General Outline
Recipe--Creating a Clipboard View for Your Private Data Type
Define a Scrap Type for Your Clipboard Data
Override the MakeViewForAlienClipboard Method
Include the Show Clipboard Command in Your Resource File
Override the WriteToDeskScrap Method of Your View Class
Override the ContainsClipType Method of Your View Class
Override the GivePasteData Method of Your View Class
Recipe--Supporting the Cut, Copy, and Clear Commands
Override DoSetupMenus in Your View Class
Override DoMenuCommand in Your View Class
Define a Command Class to Handle Cut, Copy, and Clear
Implement Constructor and Destructor Methods
Implement an Initialization Method
Implement a DoIt Method
Implement UndoIt and RedoIt Methods
Recipe--Implementing a Paste Command
Override the DoSetupMenus Method in Your View Class
Override the DoMenuCommand Method in Your View Class
Define a Command Class to Handle Paste
Implement Constructor and Destructor Methods
Implement an Initialization Method
Implement a DoIt Method
Implement UndoIt and RedoIt Methods

Previous Book Contents Book Index Next

© Apple Computer, Inc.
25 JUL 1996