'Saves the content to a file.'

def _save(self, widg):

    text = self.prompt.get_text()
    dlg = gtk.FileChooserDialog(title=_('Choose    output    file...'), action=gtk.FILE_CHOOSER_ACTION_SAVE, buttons=(gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL, gtk.STOCK_SAVE, gtk.RESPONSE_OK))
    resp = dlg.run()
    fname = dlg.get_filename()
    dlg.destroy()
    if ((resp == gtk.RESPONSE_OK) and (fname is not None)):
        fh = open(fname, 'w')
        fh.write(text)
        fh.close()
    return
