Formation of spatial gene expression patterns in development depends on transcriptional responses mediated by gene control regions, enhancers. Here, we explore possible responses of enhancers to overlapping gradients of antagonistic transcriptional regulators in the Drosophila embryo. Using quantitative models based on enhancer structure, we demonstrate how a pair of antagonistic transcription factor gradients with similar or even identical spatial distributions can lead to the formation of distinct gene expression domains along the embryo axes. The described mechanisms are sufficient to explain the formation of the anterior and the posterior knirps expression, the posterior hunchback expression domain, and the lateral stripes of rhomboid expression and of other ventral neurogenic ectodermal genes. The considered principles of interaction between antagonistic gradients at the enhancer level can also be applied to diverse developmental processes, such as domain specification in imaginal discs, or even eyespot pattern formation in the butterfly wing.