Text

My top 10 Gedit plugins

Gedit can be a really awesome editor if you give it a few plugins and an open mind. Here are a few of my favorites.

  1. MultiEdit - This bad boy lets you edit in multiple locations by only typing once. You would be AMAZED at how useful this is.
  2. Snippets - One of the default plugins, this one is sort of hard to explain because it does so much. It lets you create shortcuts for code that are expanded when you hit tab, but it also includes support for placeholders, wrapping text in tags, and lots of other crazy stuff.
  3. Zen Coding - This one’s my own, but the magic really comes from the Zen Coding library. Zen Coding lets you write a sort of HTML and CSS shorthand which is evaluated and expanded. Here’s a video to explain.
  4. AutoTab - A really simple plugin that tries to figure out the tab width of the current document, and sets Gedit to use that.
  5. Line Tools - Gives you some shortcuts to do stuff like delete current line (CTRL+D), duplicate current line (CTRL+SHIFT+D), move selected lines up/down (ALT+UP/DOWN), etc. Really, really useful.
  6. Save Without Trailing Space - Automatically strips any whitespace from ends of lines when you save, and can also add a blank line at the end of the file upon saving. Really useful for patches to projects like Drupal which reject patches with extra whitespace.
  7. Tab Switch - Lets you switch between tabs using the commonly used CTRL+TAB and CTRL+SHIFT+TAB.
  8. Todo - Gives you a little window that displays any TODO items in your code comments, among other keywords. Really handy for catching up on what you were working on the day before or keeping track of places to improve.
  9. External Tools - Gives you the ability to execute any command on the current document or selected text. The possibilities are endless with this one. Perhaps you want to validate your PHP syntax or run your HTML through HTMLTidy or check your JS with JSLint, etc.
  10. Pastie for Gedit - Lets you create a pastie (see http://pastie.org) out of the currently selected text. Great for sending snippets to people quickly.
Text

A Gedit plugin for Zen Coding

Zen Coding is a pretty sweet set of tools for HTML and CSS that allows you to code things in a short of code shorthand, hit a magic button, and it expand to regular old code.

If you’re interested, here’s a demo video of it.

Sadly, there’s no official Gedit plugin for it, but Stuart Langridge hacked up a quick plugin a few months ago. However, it left a bit to be desired, and he didn’t seem to interested in maintaining it.

Therefore, I’m continuing development on it myself. I’ve fixed a few bugs and refactored a couple parts, and I’m hoping to turn this into a really nice plugin.

The code is all at GitHub, so feel free to download, drop it into your Gedit plugins folder (see the README file for more info), and try it out.

Text

Flarp: a Gedit color scheme

Just thought I’d share the gEdit Color Scheme I’ve been using for awhile now. I’ve lovingly named it Flarp, in honor of this urban legend.

Installation:

  1. Download it.
  2. Put it in /home/yourname/.gnome2/gedit/styles
  3. Fire up gEdit and pick the theme in Edit -> Preferences -> Fonts & Colors

Enjoy!

Text

Fix for gEdit ignoring tab width preferences

If you’re fighting with an annoying bug that keeps changing your gEdit tab width to 4 no matter what you choose, then the fix is to disable the Smart Indent plugin.