| Trees | Indices | Help |
|---|
|
|
1 ################################################################################ 2 # Authors: Brian Schott (Sir Alaran) 3 # Copyright: Brian Schott (Sir Alaran) 4 # Date: Sep 23 2009 5 # License: 6 # 7 # This program is free software: 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. 11 # 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. 16 # 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/>. 19 ################################################################################ 20 21 """ 22 Contains code for previewing graphical user preferences 23 """ 24 25 26 import cairo 27 import gtk 28 29 import graphics 30 import shapes 31 import preferences 32 3335 """ 36 Widget for previewing preferences 37 """ 38 __gsignals__ = {"expose-event" : "override"} 398041 gtk.DrawingArea.__init__(self) 42 self.__checkerBoard = graphics.getCheckerPattern(16) 43 44 self.shapes = [] 45 vPoly = shapes.Polygon([ 46 shapes.Point(10, 10), 47 shapes.Point(10, 86), 48 shapes.Point(40, 86), 49 shapes.Point(86, 10), 50 ]) 51 iPoly = shapes.Polygon([ 52 shapes.Point(106, 10), 53 shapes.Point(96, 86), 54 shapes.Point(140, 86), 55 shapes.Point(120, 50), 56 shapes.Point(160, 10), 57 ]) 58 circle = shapes.Circle(35) 59 circle.setCenter(shapes.Point(200, 48)) 60 self.shapes.append(vPoly) 61 self.shapes.append(iPoly) 62 self.shapes.append(circle) 63 64 self.set_size_request(256, 96)65 71
| Trees | Indices | Help |
|---|
| Generated by Epydoc 3.0.1 on Tue Oct 6 15:18:46 2009 | http://epydoc.sourceforge.net |