Didn't expect so many replies, thanks everyone. It's good to know many approaches as I struggled finding interesting solutions when doing my research.
I don't think I can achieve an adjustable output level using your method fourfathom, but maybe I'll borrow your schematic if I can't reach this goal. I sometimes wonder if it's actually worth the hassle to have an adjustable output anyway. Well, TTL high level is 5V so 3.3V may be a bit too low. On the other hand I don't want to fry low voltage CMOS circuits (even if I'm more of an analog/RF guy so I don't encounter that kind of stuff very often). So I'll keep trying to have a somewhat working adjustable level, even if the level range is narrow nor accurate.
Right now I'm still on the analog switch method (schematic attached) using SN74LVC1G3157 but I may look at the references suggested by PCB.Wiz. By the way, will the switch mess up the op-amps output or something like that?
Tektronix used it on most of their pulse generators. They used the diode version for vertical channel switching in oscilloscopes which gives some idea of the potential performance.
Have you got any schematic? I don't know Tektronix products very well apart from their oscilloscopes so I don't know where to search.
Edit: nevermind, I found everything I needed on TekWiki.