rect tool: handles are shown and hidden correctly