We investigate the band-gap modification by collapsing deformation in C, BN, and BC3 nanotubes through first-principles pseudopotential calculations. Semiconductor-metal transitions occur when zigzag C and armchair BC3 nanotubes undergo collapsing deformation, while in zigzag BN tubes, a variation of band gaps from 5 to 2 eV is found. On the other hand, the band gaps of armchair BN and zigzag BC3 nanotubes are insensitive to collapsing deformation. Our findings can be used to design new nanotube-based functional devices.