Implement a currently unused themed-rectangle action. Some random improvements.