1. A device for establishing a spatial position of part of an x-ray ruler imaged in at least one x-ray image, the x-ray ruler including at least a first part and a second part having x-ray markers, and the first part and the second part are connected to each other by a connection element, the x-ray ruler being attached to an alignment of an object to be x-rayed, the device comprising: a position determination module for determining a spatial configuration of the x-ray markers on a basis of images of the x-ray markers in the x-ray image or x-ray images; and angle sensors disposed in the connection element.