Deleting a node
When deleting a node with child nodes attached , not only the selected node but the whole subtree (selected node and all its child nodes, plus their subtrees) will be deleted as well!
Always think before deleting a node, and get into the habit of backing up your current file before deleting important nodes or subtrees! Although a safety popup window will appear asking you to confirm that you wish to delete the node, the Undo key (Ctrl+Z) only undoes article edits. It won't help you recover any deleted nodes! Also, never rush into saving after carrying out a deletion (see Handy hint #1 below).
First, move to the Tree pane and select the node to be deleted.
To delete a node
- Click Main menu ⁄ Tree ⁄ Delete node⁄subtree; or
- Click Tree context menu⁄ Delete node⁄subtree; or
- Press the Delete key.
In each case you will be asked to confirm your action before the node is deleted. Click Yes or press Enter.
After deleting a node or subtree, the nearest sibling of the deleted node becomes the current node; if no sibling is available the parent of the deleted node will become the current node.
1. What if you have accidentally deleted nodes you should have kept, and haven't backed up the file before deleting?
Let's call your current file mywork.tpd. As long as you didn't save it immediately after making a deletion, you should still be able to recover it by opening Windows Explorer and finding mywork.tpd. Make a copy of the file (which will be in its original state) under another name, say mywork_orig.tpd, then click Main menu ⁄File ⁄ Close in TreePad and close mywork.tpd. Don't throw it away just yet - you might have made other alterations between saving it last and carrying out the deletions! Rename it to mywork_1.tpd.
Now, rename mywork_orig.tpd to mywork.tpd, click Main menu ⁄ File ⁄ Reopen and reopen mywork.tpd. There you should see your file without any deletions! Now you can also open mywork_1.tpd in a new instance of TreePad and make sure any other alterations are copied over to mywork.tpd.