That is correct for first and third base. Second base is different however. The measurement is to the middle of the bag. This is carryover from the 19th century when all measurements were to the middle of the bag. The modern method was adopted in order to facilitate fair/foul calls. For some reason, 2nd base was left using the original measurement system. This results in second base being offset 7.5 inches from the other two bases.
There is an interesting story attributed to Cal Ripkin Jr., the famous Oriole SS. The new groundskeeper mistakening positioned second base in the same manner that first and third were positioned. While warming up prior to the game, Cal turned a double play and instantly recognized that 2nd base was out of it's standard alignment. It was corrected before the game started causing a 15 minute delay.