Baby Language Lab Scripts
A collection of data processing tools.
 All Classes Namespaces Files Functions Variables Pages
diff_win.py
Go to the documentation of this file.
1 from gi.repository import Gtk as gtk
2 from gi.repository import WebKit as webkit
3 
4 class DiffWin():
5  def __init__(self, html):
6  self.window = gtk.Window()
7  self.window.set_title('Transcription Verifier - File Comparison')
8  self.window.connect('destroy', lambda w: self.window.destroy())
9  self.window.set_default_size(1200, 600)
10  self.window.set_resizable(True)
11 
12  scrolled_win = gtk.ScrolledWindow()
13  view = webkit.WebView()
14  scrolled_win.add(view)
15  self.window.add(scrolled_win)
16 
17  view.load_html_string(
18  html,
19  'file:///'
20  )
21 
22  self.window.show_all()