Article Preview
Buy Now
FEATURE
One, Two, Undo
Adding the Undo command to your REALbasic project
Issue: 1.2 (October/November 2002)
Author: Scott Forbes
Author Bio: Scott Forbes is an engineer-turned-project manager for Lucent Technologies in Sydney, Australia. He learned to program in 1982 on a Radio Shack TRS-80 Model III, and it's been downhill ever since.
Article Description: No description available.
Article Length (in bytes): 40,300
Starting Page Number: 16
Article Number: 1110
Resource File(s):
1110.zip Updated: 2013-03-11 19:07:56
Related Web Link(s):
http://www.ravenna.com/~forbes/~yonk/source/
Excerpt of article text...
You've almost finished your first "serious" REALbasic project, the one you might someday publish. You've learned the language, you understand the fundamentals of object-oriented programming, and you've written the core of your application. Now all you need are the finishing touches: An About box, an icon or two... and, of course, you need an Undo command.
Undo is often the last feature we think about as developers, but as users it's the first feature that we notice is missing. Undo can be difficult to implement, especially if we've already written the rest of the code, because the command needs to know about every "undoable" action that occurs throughout the program.
What we need is a flexible approach to writing an Undo command, that we can add to existing projects easily -- ideally one that we can re-use and expand as needed. By following the principles of object-oriented design, we can develop an Undo system that meets our needs.
...End of Excerpt. Please purchase the magazine to read the full article.