I have an Image, and I want to change anything that isn't transparent into black.
Select black as the foreground colour (or press D to set default colours: black foreground, and white background)
Make sure you have the correct layer select in the Layers panel, then select Lock alpha channel
- Do Edit > Fill with FG color, or use the shortcut Ctrl+,
Obviously, once you've finished, unlock the alpha channel if you want to edit the transparent areas again.