aboutsummaryrefslogtreecommitdiff
path: root/lib/filewin.py
blob: ad35ea427fb85ae438fba08ec96b1ddab5eaf989 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# Module 'filewin'
# File windows, a subclass of textwin (which is a subclass of gwin)

import textwin
from util import readfile


# FILE WINDOW

def open_readonly(fn): # Open a file window
 w = textwin.open_readonly(fn, readfile(fn))
 w.fn = fn
 return w

def open(fn): # Open a file window
 w = textwin.open(fn, readfile(fn))
 w.fn = fn
 return w