Sławno 'sławno (Kashubian/Pomeranian: Słôwno, Schlawe) is a town on the Wieprza river in Middle Pomerania region, north-western Poland, with 12,511 inhabitants (2019). It is the administrative seat of Gmina Sławno, though not part of it. The town is also the capital of Sławno County in West Pomeranian Voivodeship since 1999, previously in Słupsk Voivodeship (1975–1998). Sławno is a railway junction on the major Gdańsk–Szczecin line, with access to secondary importance connections to Darłowo and Korzybie. It is also a stop on the European route E28 running parallel to the south coast of the Baltic Sea between the cities of Koszalin and Słupsk. Since the mid-12th century the Land of Słupsk-Sławno was under the rule of Duke Ratibor I of Pomerania and his descendants, a cadet branch of the Griffin dynasty. From 1190 to 1238 it was the capital of the Duchy of Pomerania-Schlawe. When the line became extinct about 1227, their estates were the matter of an inheritance conflict between the Griffin Duke Barnim I the Good and Swietopelk II from the Samborid dynasty, who ruled over the adjacent territories of Pomerelia (Gdańsk Pomerania) in the east. Both duchies had previously separated from Poland as a result of the 12th-century fragmentation of Poland (Pomerania in the 12th century, and Pomerelia in the 13th century). Swietopelk II prevailed, his son Mestwin II, duke in Pomerelia from 1266, however again had to deal with claims raised by the Pomeranian Griffins and also by his brother Wratislaw II. To secure his rule, Mestwin accepted the suzerainty of the Ascanian margraves of Brandenburg by the 1269 Treaty of Arnswalde, but later on, in 1282, Mestwin and Polish Duke Przemysł II signed the Treaty of Kępno, which transferred the suzerainty over Gdańsk Pomerania including Sławno to Przemysł II. Upon Mestwin's death in 1294, the Samborides became extinct and Sławno was reintegrated with Poland. In 1308 Brandenburg invaded the region and Waldemar of Ascania finally separated Sławno from Pomerelia, which he sold to the Teutonic Order by the 1309 Treaty of Soldin.