To make the pastry, process the flours, paprika, butter, and salt until the mixture resembles breadcrumbs. Add the egg and process until a dough forms, adding a splash of cold water if needed. Roll out and line a 20 cm loose-bottomed metal tin. Chill.
Cook the potatoes in boiling salted water until just tender, then drain very well.
Cook the leeks with a knob of butter until soft. Add garlic and cook 1 minute. Stir in spinach and cook until completely wilted, then stir in soft cheese.
Heat oven to 190°C / 170°C fan / gas 5. Combine leeks, spinach, and potatoes. Add three-quarters of the cheddar and season well. Transfer to the chilled pastry case and top with remaining cheddar.
Bake 40 to 45 minutes until golden. Cool 10 minutes in the tin before turning out and serving.