How to change the color of foreground and background
Photoshop has many tools. They all gathered on vertical panels "Tools" — Tools, which is located in the left part of the main window. At the bottom of the panel you can see two colored squares. This button controls work (basic) and background color. Foreground color of the square corresponds to the working color, and the back — background. By default, as the primary is set to black and white.
To swap the foreground and background colors, click the curved arrow on the Tools panel to the right of the described squares. Or press a hot key x. If you need to quickly return to the default colors, use the hot key d. Or click the foreground and background color default Default Foreground and Background Colors.
How to "flip" the gradient
To create a smooth transition from one shade of color to another, photoshop applies the Gradient tool — Gradient. The default is to create a gradient uses foreground and background. To change the color and other settings of this tool in the gradient Editor" — Edit Gradient. To do this, simply click the icon on the icon presets.
In the editor you can not only change the two original colors, but also add new shades. And, in addition, to adjust the gradation of the transition and transparency. To swap colors of the gradient, check Reverse. This feature is convenient because of available from the settings pane, there is no need to re-open the editor and move the sliders color.
Adjustment layer Hue/Saturation
Swap colors in the image you can use the adjustment layer "Hue/Saturation" — Tion/Saturation. Substitution is made by replacing one color with another. If the Edit menu is set to Master, the slider Hue — the Hue affects the color of the image. Moving the green color will change to red, blue to green, etc.
To replace only the specific color of the image, select range, putting it in the drop-down list Edit. For example, to replace the red pixels to green, select Reds (red) and set the Hue slider to position +50. To ensure a smooth transition of color, photoshop automatically smooths out the edges of red areas. The amount of blur default value is 30 pixels.
The Saturation slider changes the saturation of the color. The value of this setting may vary from -100 (which means complete discoloration) to +100 (the colors become unnaturally bright). Therefore, in order to replace any color image to gray, simply select the range in the list Edit and set the value Saturation - 100.