Colonized by the Spanish in 1682, the first permanent Anglo-American settlement was established by Stephen F. Austin in 1821. In 1836 the Texans set up a provisional government in opposition to the Mexican dictatorship of Antonio López de Santa Anna and following the heroic defense of the Alamo, the revolutionary army under Sam Houston finally defeated Mexican forces in April of the same year. A republic was established and Texas remained independent for almost a decade until annexation by the USA was agreed upon and Texas became a state. It was a supporter of the Confederate cause during the US Civil War. Changes in the course of the Rio Grande, which forms part of the Texas-Mexico border, has led to several border disputes between the USA and Mexico and in 1970 the two countries agreed on plans to prevent any further substantial changes in the river's course. Area: 692 402 sq km (267 338 sq mi). Population (1996 est): 19 128 261. Capital: Austin.