1550s, "one who trims," agent noun from trim (v.). Meaning "one who changes opinions, actions, etc. to suit circumstances" is from 1680s, from the verb in the nautical sense of "adjust the balance of sails or yards with reference to the wind's direction" (1620s).