Dislocations in two dimensions I. Floating systems