and use that function in GimpToolPalette and GimpToolbox.
and move all of GimpToolbox' tool button code there.