Merge pull request #506 from andrewcsmith/patch-2
[supercollider.git] / editors / sced / scedwin / py / LogPanel.py
bloba2c9dc98b24ea0e8035703a5459ddb8c980acba7
1 # sced (SuperCollider mode for gedit)
3 # Copyright 2012 Jakob Leben
4 # Copyright 2009 Artem Popov and other contributors (see AUTHORS)
6 # sced is free software:
7 # you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation, either version 3 of the License, or
10 # (at your option) any later version.
12 # This program is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
17 # You should have received a copy of the GNU General Public License
18 # along with this program. If not, see <http://www.gnu.org/licenses/>.
20 import gtk
22 # in order to get oblivion etc. colors, we may use:
23 # client.get_string("/apps/gedit-2/preferences/editor/colors/scheme")
24 # client = gconf.client_get_default()
26 class LogPanel(gtk.ScrolledWindow):
27 def __init__(self):
28 gtk.ScrolledWindow.__init__(self)
30 self.props.shadow_type = gtk.SHADOW_IN
31 self.props.hscrollbar_policy = gtk.POLICY_AUTOMATIC
32 self.props.vscrollbar_policy = gtk.POLICY_AUTOMATIC
34 self.buffer = gtk.TextBuffer()
35 self.view = gtk.TextView(self.buffer)
36 self.view.props.editable = False
37 self.view.props.wrap_mode = gtk.WRAP_CHAR
39 self.add(self.view)
40 self.view.show()