How is the power factor part involved in wattmeter reading?
This kind of wattmeter does not directly work from the power factor.  It averages the instantaneous voltage times current.  The force on the needle is proportional to the voltage times the current, which is the instantaneous power.  A spring causes the needle to deflect linearly with applied force.  The inertia of the needle averages the instantaneous product of the current and the voltage, so shows averge real power.

If the voltage and current are out of phase with each other by 90&deg; (power factor = 0), then the power would be positive for half the cycle and negative for half the cycle.  If the meter is intended for normal power line frequencies, then the mechanical mechanism will not respond to the individual 50 or 60 Hz half-cycles but show you the low pass filtered power with a significantly longer time constant than individual power cycles.  At a power factor of 0, this average will be 0, and the meter will show 0.

If you separately measure the RMS voltage and current then multiply them, you get the VA value (magnitude of power including both real and imaginary parts).  You can take the real power shown by the meter and divide it by the VA value to get the power factor.

So again, this meter doesn't directly deal with power factor.  It measures real power going back to first principles and whether the voltage and current signals are sines or not.

By the way, the electric meter on your house works on the same basic principle.  Instead of deflecting a needle against a spring, the force between the voltage and current coils cause a small motor to spin.  The total number of rotations is the time-integral of the power, or the total energy delivered.  A series of gears rotate various labeled dials so that this integral can be accumulated and displayed so the meter guy can read the total every month.  Newer meters send the accumlated reading to the power company automatically via various communication means.