For P-OLED display fabrication, it is important to control the final film shape, arising from drying of volatile droplets containing polymer. Due to peripheral pinning and subsequent outward capillary flow, a coffee-ring typically develops. This is inconvenient since a spatially uniform height, above the substrate, is required to ensure uniform current across the device. Typically the droplets are deposited inside a trough-like structure on the substrate. We present a thin-film lubrication model that tracks the drying dynamics through to the final film shape. The governing equations are derived and solved numerically. We investigate the effect of the trough’s depth and the slope of the walls. Increasing the depth or the wall’s gradient increases coffee-ring formation. This is due to an increase in horizontal velocity, caused by the substrate’s shape as well as delayed gelation of the polymer. The latter allows the outward capillary flow to act for a longer time, before the height becomes fixed.