What is the reason for the peculiar shape of the Austro-Hungarian border?

by greenlightison

Currently I am in the beautiful town of Gussing in Austria. Today, I had the chance to visit the Austro-Hungarian border (Iron Curtain etc.) I noted the rather unnatural(?) border lines of Austria and Hungary. Some parts look quite artificial. I guess all borders are artificial but what I mean is that rather than following any natural features like most of the borders in Europe, the Austro-Hungarian border has straight lines and incursions in random areas. It seems that this may have an interesting history so I am here posting this on AskHistorians! Can anyone help?

http://imgur.com/r7zgfsJ

lu619

In the days of the Hapsburg empire, all of the area that's now the Austrian state of Burgenland belonged to Hungary. Traditionally, the Border between Austria and Hungary was the river Leitha- Burgenland's boundary on the Austrian side almost follows this still. As the inhabitants were mostly German speakers, it was incorporated into Austria by the treaty of Trianon following world war I. However the Hungarians didn't accept this lightly, and low-level fighting went on until 1921 when it was agreed to hold a plebiscite (a referendum) in the Hungarian-majority part, with the result that Sopron retuned to Hungary. Hence the odd shape to the border around Sopron. Why the border's so ragged further south is I suppose because if follows the borders of the parishes/communes, having never been any kind of provincial border before 1920/21.

http://hungarianhistory.com/lib/tria/tria26.htm