Leela had known from the start that it would end. It was obvious, really, when you thought about it. He'd been slipping out of her fingers the second she met him.
She's learnt so much from him, though. She's learnt about technicians, and science, and that there is no magic. She has learnt to not always rely on weapons. She's learnt that other people are more advanced than her, in some ways. But she has her mind, her senses. She's learnt to develop them. But she's kissed him and fucked him and argued with him, and that's too much, she can't, she just can't, even if she wants to. She feels like a trapped bird with him, but she's destined to find nobody as wonderful as him. Not even Andred. The Doctor is a surreal glow, full of too much wisdom and madness, and it scares her away as it entrances her.
So Leela knows she's doing the right thing when she decides to stay behind. Even if it doesn't feel that way yet. She wants to cry out for him, to kiss him until her mouth tastes like a bruise. But she knows, dull as he shines, Andred's glow may develop with a little polishing. He will never rival the Doctor, Leela knows, but that's the curse of loving someone you can't have. It's the price you pay; nobody will compare to the diamond just out of your reach.
She tells him quite honestly that she will miss him. The Doctor simply smiles that madcap grin of his, but she knows he's thinking, don't leave me, Leela, I shall go mad, don't leave me please. And, I shall miss you too, but you're quite right, really - and that's why he doesn't say anything, because his sanity has to fight for dominance.
And Leela also knows, on the other side of the door, he's telling her he loves her in the only way he can.