Text this: Gravitational waves and cosmic microwave anisotropies: from theory to data analysis for Planck