Olsztyn (; German: Allenstein (listen); Old Polish: Holstin; Old Prussian: Alnāsteini or Alnestabs; Lithuanian: Alnaštynas, Alnštynas, Alštynas (historical) and Olštynas (modern)) is a city on the Łyna River in northeastern Poland. Olsztyn is the capital of the Warmian-Masurian Voivodeship, and is a city with county rights. Founded as Allenstein in the 14th century, Olsztyn was under the control and influence of the Teutonic Order until 1466, when it was incorporated into the Polish Crown. For centuries the city was an important centre of trade, crafts, science and administration in the Warmia region linking Warsaw with Königsberg. Following the First Partition of Poland in 1772 Warmia was annexed by Prussia and ceased to be the property of the clergy. In the 19th century the city changed its status completely, becoming the most prominent economic hub of the southern part of Eastern Prussia. The construction of a railway and early industrialization greatly contributed to Olsztyn's significance. The city remained part of Germany under the name Allenstein until 1945 when it was captured by the Red Army and handed over to the Polish authorities. As a result of the deliberate devastation caused by the Soviets during the final stages of World War II, 40% of the buildings were completely destroyed. After the war Olsztyn rapidly recovered and grew to be one of the most important centres of commerce in the country. Since 1999 Olsztyn has been the capital city of the Warmia-Masuria. In the same year, the University of Warmia and Masuria was founded from the fusion of three other local universities. Today, the Castle of Warmian Bishops houses a museum and is a venue for concerts, art exhibitions, film shows and other cultural events, which make Olsztyn a popular tourist destination. The most important sights of the city include the medieval Old Town and the Olsztyn Cathedral, which dates back more than 600 years. The picturesque market square is part of the European Route of Brick Gothic and the cathedral is regarded as one of the greatest monuments of Gothic architecture in Poland. Olsztyn, for a number of years, has been ranked very highly in quality of life, income, employment and safety. It currently is one of the best places in Poland to live and work. It is also one of the happiest cities in the country.