The state of the buttons on the Transform panel are saved in the 3D_TRANSFO_REFERENTIAL_CHANGED preference, which is a bitfield.
So, for example, to enable the Ref manipulation mode, you would do this:
SetUserPref( "3D_TRANSFO_REFERENTIAL_CHANGED", GetUserPref("3D_TRANSFO_REFERENTIAL_CHANGED") | 3 );
This would turn on the Ref mode, and leave the COG, Prop, and Sym options untouched.
If you simply did this:
SetUserPref( "3D_TRANSFO_REFERENTIAL_CHANGED", 3 );
that would reset the COG and Sym options.
Turn on COG:
SetUserPref( "3D_TRANSFO_REFERENTIAL_CHANGED", GetUserPref("3D_TRANSFO_REFERENTIAL_CHANGED") | 16 );
Turn off COG:
SetUserPref( "3D_TRANSFO_REFERENTIAL_CHANGED", GetUserPref("3D_TRANSFO_REFERENTIAL_CHANGED") & ~16 );
Another example:
// Turn off all SetUserPref( "3D_TRANSFO_REFERENTIAL_CHANGED", 0 ); // Turn on Local and COG SetUserPref( "3D_TRANSFO_REFERENTIAL_CHANGED", GetUserPref("3D_TRANSFO_REFERENTIAL_CHANGED") | (16 | 2) );
You can use Alt+NumPad numbers to see what gets logged when the different buttons are selected.
The SDK documentation also includes a page for the Manipulation Mode Values.