Ramsey-type theorems for sets satisfying a geometric regularity condition