Logo Search packages:      
Sourcecode: lfm version File versions  Download package

def lfm::pyview::FileView::__get_file_info (   self,
) [private]

get size and number of lines of the file

Definition at line 263 of file pyview.py.

00263                                    :
        """get size and number of lines of the file"""
        self.nbytes = os.path.getsize(file)
        nlines = 0L
        self.lines_pos = [0L]
        if self.nbytes != 0:
            pos = 0L
            f = open(file)
            for l in f.readlines():
                pos += len(l)
                nlines += 1
        self.nlines = nlines

    def init_curses(self):

Generated by  Doxygen 1.6.0   Back to index