2.11.4 Manipulating the Front End from the Kernel
Manipulating global options in the front end.
Just like cells and notebooks, the complete Mathematica front end has various options, which you can look at and manipulate from the kernel.
This gives the object corresponding to the front end currently in use.
This gives the current directory used by the front end for notebook files.
In:= Options[$FrontEnd, NotebookDirectory]
A few global options for the Mathematica front end.
By using NotebookWrite you can effectively input to the front end any ordinary text that you can enter on the keyboard. FrontEndTokenExecute allows you to send from the kernel any command that the front end can execute. These commands include both menu items and control sequences.
Executing a named command in the front end.
A few named commands that can be given to the front end. These commands usually correspond to menu items.