“Open Header/Body” Gedit Plugin
This plugin for gEdit will simply open the corresponding header or body file for the current file. For example, if you are looking a somecode.h, the “Open corresponding header/body” will add a new tab with the content of somecode.c or somecode.cpp (if the first one doesn’t exist). The reverse is also true, if you are looking a somecode.cpp, the “Open corresponding header/body” will add a new tab with the content of somecode.h or somecode.hpp (if the first one doesn’t exist). If the file is already open, it’ll activate that tab for you.
The code is available under LGPL 2.1+ here.
To get the code, use this command:
git clone git+ssh://git.collabora.co.uk/git/user/pierlux/open_header.git
Once you get the files, place them in your ~/.gnome2/gedit/plugins and restart gEdit. You’ll have to enable the plugin under Edit/Preferences/Plug-ins. A new menu option “Open corresponding header/body”will appear inside the Tool menu. You can also hit <control> and r to quickly switch from the header and body.





