Dirac boundary states on opposite boundaries can overlap and interact owing to finite size effect. We propose that in a thin film system with symmetry-unrelated valleys, valley-contrasting couplings between Dirac boundary states can be exploited to design various two-dimensional topological quantum phases. Our first-principles calculations demonstrate the mechanism in tin telluride slab and nanoribbon array, respectively, by top-down and bottom-up material designs. Both two-dimensional topological crystalline insulator and quantum spin Hall insulator emerge in the same material system, which offers highly tunable quantum transport of edge channels with a set of quantized conductances. © 2017 American Physical Society.