I am curious, when and by whom it was proved that straight line is the shortest of measurable curves connecting two given points.
Essentially Euclid. Exact statement depends on the exact notion of a curve and length. Euclid considers first broken lines, and proves the statement for them. Then he defines the length of other curves (for example a circle) essentially as the limit of lengths of inscribed broken lines. By the way, the modern definition of length is the same. The statement easily follows, because the broken lines can be inscribed in such a way that their length increases.
Remark. Of course, we do not know exactly what Euclid discovered himself, and what was known before him, because his Elements is the only primary source for mathematics before him, and he does not give references.