Driving instructor hat goes on. . . .
As John says, holding your foot on the footbrake won't necessarily damage the gearbox as the clutch is activated.
However holding your foot on the brake may dazzle any drivers sat behind you in the queue, especially at night, so once the car behind has afely stopped you should consider the option of selecting N, apply the handbrake and release the footbrake. Also if you are heavy on the brakes, and then sit in stationary traffic with your foot on the footbrake, the heat generated by the braking of the car will now be held in one position on the brake discs, potentially distorting them.
Me ?? Brake gently and early, and keep my foot on the footbrake in D, unless its a long wait at night, for example at a level crossing.