The conventional float +rheostat method, is a wire wound resistor that sits inside the tank with a sliding contact on it. There is a float on an arm that always floats on top of the petrol level. The arm has some sort of sliding contact on the wire wound resistor, that normally shorts part of it out. So if a voltage (~5V) is applied via the petrol gauge and is earthed by the sliding contact, then the amount of current through the petrol gauge is varied and hence its deflection. If you are lucky the variable resistor has been made to a special law that suites the tank/float arm radius, so the current actually varies linearly with the volume of petrol.
Frank