My task is to turn white background into transparency. I fumbled out the following approach to this task (if I were the designer of Color Picker, I would definitely add a transparency color button in the dialog):
1) Unlock the background layer of the image
2) Add a new layer beneath it
3) Use Paint Bucket Tool to fill the new layer with a distinguishable color
4) Use Background Eraser Tool to erase the background of the image
5) delete the added layer
It works but I feel that the Background Eraser Tool is hard to use because I have to manually erase the background with a mouse. As a C++ programmer, I can't help expect that the Background Eraser Tool can detect the background pixel automatically and proceed using a BFS flood filling algorithm, just like what Paint Bucket Tool (it used to be called fill tool, but now it changes its name to something strange, which cost me quite a while to find) does. It can save me (and other non-artistic users who do not possess a tablet) a lot of work and possible missing of background pixels I did not erase by hand. So does Photoshop has the functionality to apply Background Eraser Tool in a flood filling way like Paint Bucket Tool fills a region? Thank you.
For pretty much every version of Photoshop, you can use the Paint Bucket tool as an eraser.
1) Unlock the layer your working on.
2) Choose the Paint Bucket Tool and set the mode to Clear (instead of Normal) to erase any color you click.
You may need to play with the Contiguous and All Layers settings on the Paint Bucket tool to really get what you're after. Don't forget to set the Paint Bucket mode back to normal once your done or you might have some confusion later.