The problem now is that the print heads are blocked. Several months later I have put back some new cartridges and the carriage now returns properly and consistently to the proper position when the top is closed.
I took all the cartridges out and turned off the printer power, nearly giving up on it. After an attempt to print the problem immediately returned. Finally the ink carriage would return properly to the right hand rest position when the printer top was closed. It did not solve the problem the first time. I replaced the PGBK cartridge with a compatible cartridge. The white flexible band that connects to the ink cartridges carriage, had quite a lot of ink on it and there was a lot of ink on the carriage itself. I took the leaky cartridge out and cleaned up with isopropyl alcohol and a clean rag. It was not me that accepted this, it was someone else that took the printer to the shop. The women at the shop said that she would not take any responsibility if this cartridge voided the warranty. What might have been to blame for this was a leaky PGBK black cartridge, that had been replaced from a shop that has recycled cartridges. The ink cartridges would not return completely to the right rest position and it was making a loud click when it tried to do this after closing the printer top.
I had a problem with a Canon Pixma TS6360.