you will loose decimals here with long what you want is double for fwidthinches  fheightinches  fppix and fppiy  remember that you put the values in b dsize which uses double for storing it is values 