if we take the inside dimensions on a standard 125g (72x18x23 tall) and assume half inch glass for ease (even though its not 1/2" but 3/8ths, we have:71x17x23 =27761
dividing by 231 (since there are 231 cubic inches per gallon) gives 120.17 gallons.
now, your inside dimensions may vary slightly depending on the manufacturer, as the height is sometimes different. Aqueon's 125 for example is 1.5" taller than Perfecto's..
and I assumed its full to the top which is never really is.
but yes, the gallon size is more like a model number.
hell, Aqueons "150g" is 2.5 inches taller ( about 15 gallons more) than everyone elses 150g.. so you get 15 gallons for free if you get one
in terms of dosing for water conditioner and meds, I just go by the what the tank size is called.
eg. for a 125 I dose for 125. even though the actual water volume is a little less, and of course you have displacement from gravel and decor making it even less, it doesn't seem to make a difference.
ie you won't overdose by not taking into account the true volume rather than the stated volume. its close enough that it doesn't really matter.