if you have not this ppa, please add it:
sudo apt-add-repository ppa:ubuntu-on-rails/ppa
then, you should install this dependency below:
sudo apt-get install gir1.2-zeitgeist-2.0
now, as most tutorial on web, execute following command line:
sudo apt-get update
sudo apt-get install gedit-gmate
sudo apt-get install gedit-plugins
normally, Ubuntu have built-in gedit ,otherwise:
sudo apt-get install gedit
“preference” is located at top-left corner of you desktop, not embedded with editor UI. you will find it !