def tell(self):
        """Returns the file offset. If this is a compressed file, then the 
        offset in the compressed file is returned.
        """
        if isinstance(self.fileobj, gzip2.GzipFile):
            return self.fileobj.fileobj.tell()
        else:
            return self.fileobj.tell()