For Dahon seatpost slipping, you can get an alloy
seatpost shim which works wonders.
For Brompton seatpost slipping, I initially used one layer of packing tape around the seatpost. It can get messy because it gets worn sliding up and down the tube, but eventually the seatpost conformed to my preferred height after constant riding (albeit it took about a year) such that I have had no more slipping problems and was able to clean off the tape residue.