Get a rectangle. Press CTRL+E and color the object, save the new color. The rectangle is now linked to the color.
Use the contour tool. Enable "Inset Path option". Resize the rectangle. The link to the color is gone after resizing - this is very annoying.