Originally the medieval title for the military commander of the border provinces of the Holy Roman Empire or of a kingdom.