I would disagree with the first reply. The part quoted there doesn't "sound good" to me, because using a mouse to "click on an object in a canvas" is notoriously error-prone. The chances are too likely that users will "click an object" while in "delete" mode and then discover that they clicked the wrong object.
Even if you are planning on providing an "Undo Delete" button too, users with less-than-ideal coordination skills will become frustrated and fearful, and this should be avoided.
To avoid the problem, use a mouse click to select an object; highlight and/or identify the object in some way so the user knows exactly what was selected; the user can click again, as many times as necessary, until their intended object is the one being highlighted. Whenever an object has been selected, offer a button or menu item of some sort to delete the currently selected object (but allow the user to "deselect" the currently selected object by clicking somewhere else - possibly where there is no object, so that nothing is selected).
If you have any relevant code - maybe a simple "dummy" script that puts up a canvas with a few objects, and tries to support the action you want - post it here. As a rule, monks would prefer help you with the code that you are writing.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.