bugged
stringlengths
4
228k
fixed
stringlengths
0
96.3M
__index_level_0__
int64
0
481k
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,600
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,601
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,602
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,603
def demo(): """Demonstrate the package.""" from Numeric import * # A straightforward use of gnuplot. The `debug=1' switch is used # in these examples so that the commands that are sent to gnuplot # are also output on stderr. g = Gnuplot(debug=1) g.title('A simple example') # (optional) g('set data style linespoints'...
def demo(): """Demonstrate the package."""raw_input('Please press return to continue...\n') def f(x,y): import math print x,y return math.exp(- 0.01 * (x**2 + y**2)) g.splot(GridFunc(f, x,y, binary=0)) from Numeric import *raw_input('Please press return to continue...\n') def f(x,y): import math print x,y return...
32,604
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = Gnuplot.Gnuplot() g.clear() # Make a temporary file: filename1 = tempfile.mktemp() f = open(filename1, 'w') for x in Numeric.arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x))) f.close(...
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = Gnuplot.Gnuplot(debug=1) g.clear() # Make a temporary file: filename1 = tempfile.mktemp() f = open(filename1, 'w') for x in Numeric.arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x))) f...
32,605
def float_array(m): """Return the argument as a Numeric array of type at least 'Float32'. Leave 'Float64' unchanged, but upcast all other types to 'Float32'. Allow also for the possibility that the argument is a python native type that can be converted to a Numeric array using 'Numeric.asarray()', but in that case do...
def float_array(m): """Return the argument as a Numeric array of type at least 'Float32'. Leave 'Float64' unchanged, but upcast all other types to 'Float32'. Allow also for the possibility that the argument is a python native type that can be converted to a Numeric array using 'Numeric.asarray()', but in that case ...
32,606
def grid_function(f, xvals, yvals, typecode=Numeric.Float32): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i...
def grid_function(f, xvals, yvals, typecode=None, ufunc=0): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i,j...
32,607
def grid_function(f, xvals, yvals, typecode=Numeric.Float32): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i...
def grid_function(f, xvals, yvals, typecode=Numeric.Float32): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i...
32,608
def grid_function(f, xvals, yvals, typecode=Numeric.Float32): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i...
def grid_function(f, xvals, yvals, typecode=Numeric.Float32): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i...
32,609
def pipein(self, f): if self._data: f.write(self._data)
def pipein(self, f): if self._data: f.write(self._data)
32,610
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, data, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,611
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,612
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,613
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,614
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,615
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,616
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,617
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
def __init__(self, toplot, xvals=None, yvals=None, binary=1, inline=_unset, **keyw): """GridData constructor.
32,618
def demo(): """Demonstrate the package.""" from Numeric import * # A straightforward use of gnuplot. The `debug=1' switch is used # in these examples so that the commands that are sent to gnuplot # are also output on stderr. g = Gnuplot(debug=1) g.title('A simple example') # (optional) g('set data style linespoints'...
def demo(): """Demonstrate the package."""raw_input('Please press return to continue...\n') def f(x,y): import math print x,y return math.exp(- 0.01 * (x**2 + y**2)) g.splot(GridFunc(f, x,y, binary=0)) from Numeric import *raw_input('Please press return to continue...\n') def f(x,y): import math print x,y return...
32,619
def grid_function(f, xvals, yvals, typecode=None, ufunc=0): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i,j...
def grid_function(f, xvals, yvals, typecode=None, ufunc=0): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i,j...
32,620
def test_persist(): global _recognizes_persist if _recognizes_persist is None: g = os.popen('echo | gnuplot -persist 2>&1', 'r') response = g.readlines() g.close() _recognizes_persist = ((not response) or (string.find(response[0], '-persist') == -1)) return _recognizes_persist
def test_persist(): global _recognizes_persist if _recognizes_persist is None: g = os.popen('echo | gnuplot -persist 2>&1', 'r') response = g.readlines() g.close() _recognizes_persist = ((not response) or (string.find(response[0], '-persist') == -1)) return _recognizes_persist
32,621
def plot(*items, **kw): """plot data using gnuplot. This command is roughly compatible with old Gnuplot plot command. It is provided for backwards compatibility only. It is recommended that you use the new object-oriented Gnuplot interface, which is much more flexible. It can only plot Numeric array data. In this r...
def plot(*items, **kw): """plot data using gnuplot. This command is roughly compatible with old Gnuplot plot command. It is provided for backwards compatibility only. It is recommended that you use the new object-oriented Gnuplot interface, which is much more flexible. It can only plot Numeric array data. In this r...
32,622
def plot(*items, **kw): """plot data using gnuplot. This command is roughly compatible with old Gnuplot plot command. It is provided for backwards compatibility only. It is recommended that you use the new object-oriented Gnuplot interface, which is much more flexible. It can only plot Numeric array data. In this r...
def plot(*items, **kw): """plot data using gnuplot. This command is roughly compatible with old Gnuplot plot command. It is provided for backwards compatibility only. It is recommended that you use the new object-oriented Gnuplot interface, which is much more flexible. It can only plot Numeric array data. In this r...
32,623
def plot(*items, **kw): """plot data using gnuplot. This command is roughly compatible with old Gnuplot plot command. It is provided for backwards compatibility only. It is recommended that you use the new object-oriented Gnuplot interface, which is much more flexible. It can only plot Numeric array data. In this r...
def plot(*items, **kw): """plot data using gnuplot. This command is roughly compatible with old Gnuplot plot command. It is provided for backwards compatibility only. It is recommended that you use the new object-oriented Gnuplot interface, which is much more flexible. It can only plot Numeric array data. In this r...
32,624
def write_array(f, set, item_sep=' ', nest_prefix='', nest_suffix='\n', nest_sep=''): """Write an array of arbitrary dimension to a file. A general recursive array writer. The last four parameters allow a great deal of freedom in choosing the output format of the array. The defaults for those parameters give output ...
def write_array(f, set, item_sep=' ', nest_prefix='', nest_suffix='\n', nest_sep=''): """Write an array of arbitrary dimension to a file. A general recursive array writer. The last four parameters allow a great deal of freedom in choosing the output format of the array. The defaults for those parameters give output ...
32,625
def write_array(f, set, item_sep=' ', nest_prefix='', nest_suffix='\n', nest_sep=''): """Write an array of arbitrary dimension to a file. A general recursive array writer. The last four parameters allow a great deal of freedom in choosing the output format of the array. The defaults for those parameters give output ...
def write_array(f, set, item_sep=' ', nest_prefix='', nest_suffix='\n', nest_sep=''): """Write an array of arbitrary dimension to a file. A general recursive array writer. The last four parameters allow a great deal of freedom in choosing the output format of the array. The defaults for those parameters give output ...
32,626
def __init__(self, *set, **keyw): """Construct a Data object from a numeric array.
def __init__(self, *set, **keyw): """Construct a Data object from a numeric array.
32,627
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in Numeric.arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), ma...
32,628
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
32,629
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
32,630
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
32,631
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
32,632
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
def main(): """Exercise the Gnuplot module.""" wait('Popping up a blank gnuplot window on your screen.') g = gp.Gnuplot() g.clear() # Make a temporary file: file1 = gp.TempFile() # will be deleted upon exit f = open(file1.filename, 'w') for x in arange(100)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x...
32,633
def __del__(self): """Delete the referenced file."""
def __del__(self): """Delete the referenced file."""
32,634
def __del__(self): """Delete the referenced file."""
def __del__(self): """Delete the referenced file."""
32,635
def __init__(self, file, **keyw): """construct a file object.
def __init__(self, file, **keyw): """construct a file object.
32,636
def grid_function(f, xvals, yvals, typecode=None, ufunc=0): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i,j...
def grid_function(f, xvals, yvals, typecode=None, ufunc=0): """Evaluate and tabulate a function on a grid. 'xvals' and 'yvals' should be 1-D arrays listing the values of x and y at which 'f' should be tabulated. 'f' should be a function taking two floating point arguments. The return value is a matrix M where 'M[i,j...
32,637
def hardcopy(self, filename=None, terminal='postscript', **keyw): """Create a hardcopy of the current plot.
def hardcopy(self, filename=None, terminal='postscript', **keyw): """Create a hardcopy of the current plot.
32,638
def __init__( self, types, size=0, roll="1d8", range=None ): self.range = range or D20DamageRange( size, roll ) self.types = types super( D20Damage, self ).__init__( 'Damage', 0, self.range.roll ) self.mod.static = True
def __init__( self, types, size=0, roll="1d8", range=None ): self.range = range or D20DamageRange( size, roll ) self.types = types super( D20Damage, self ).__init__( 'Damage', 0, self.__int__ ) self.mod.static = True
32,639
def getLevel( self ): charlevelnum = 1 try: for level in self.levels[ 'RACE' ].values( ): if level.enabled: charlevelnum += 1 except KeyError: pass return charlevelnum
def getLevel( self ): charlevelnum = 1 try: for level in self.levels[ 'RACE' ].values( ): if level.enabled: charlevelnum += 1 except KeyError: pass return charlevelnum
32,640
def getLevel( self ): charlevelnum = 1 try: for level in self.levels[ 'RACE' ].values( ): if level.enabled: charlevelnum += 1 except KeyError: pass return charlevelnum
def getLevel( self ): charlevelnum = 1 try: for level in self.levels[ 'RACE' ].values( ): if level.enabled: charlevelnum += 1 except KeyError: pass return charlevelnum
32,641
def loadAliases(): try: aliases = pickle.load(file(fs.aliases('aliases.pkl'), 'rb')) log.msg('loaded aliases') except IOError, e: # if the file just doesn't exist, assume we have to create it. if e.errno == errno.ENOENT: log.msg('new aliases.pkl') else: raise
def loadAliases(): try: aliases = pickle.load(file(fs.aliases('aliases.pkl'), 'rb')) log.msg('loaded aliases') except IOError, e: # if the file just doesn't exist, assume we have to create it. if e.errno == errno.ENOENT: log.msg('new aliases.pkl') else: raise
32,642
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
32,643
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
32,644
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
32,645
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
def self.canvas.connect('size-allocate', self.on_canvas_expose_event) __init__(self, self.canvas.connect('size-allocate', self.on_canvas_expose_event) deferred, self.canvas.connect('size-allocate', self.on_canvas_expose_event) netclient, self.canvas.connect('size-allocate', self.on_canvas_expose_event) fps): ...
32,646
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=...
def on_canvas_expose_event(self, w, ev): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # ...
32,647
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=...
def paintDefault(self): """Draw the default background""" # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=self.bg) root.add("GnomeCanvasRect", x1=0, x2=384, y1=0, y2...
32,648
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=...
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=...
32,649
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=...
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # w = root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #w = root.add("GnomeCanvasPixbuf", x=-129, y=0, # ...
32,650
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=...
def paintDefault(self): """Draw the default background""" tile_w = self.bg.get_width() tile_h = self.bg.get_height() # tile the texture root = self.canvas.root() if self.model is None: # root.add("GnomeCanvasPixbuf", x=0, y=0, # pixbuf=self.bg) #root.add("GnomeCanvasPixbuf", x=-129, y=0, # pixbuf=...
32,651
def displayModel(self): mapinfo = self._getMapInfo() log.msg('displaying map %s' % (mapinfo['name'],)) self.model = Model(pygame.image.load(fs.downloads(mapinfo['name']))) self.main.blit(self.model.background, (0,0)) for n, character in enumerate(self._getCharacterInfo()): icon_image = pygame.image.load(fs.downloads(ch...
def displayModel(self): mapinfo = self._getMapInfo() log.msg('displaying map %s' % (mapinfo['name'],)) background = gdk.pixbuf_new_from_file(fs.downloads(mapinfo['name'])) self.model = Model(background) root = self.canvas.root() root.add("GnomeCanvasPixbuf", pixbuf=background) self.canvas.set_size_request(background.ge...
32,652
def displayModel(self): mapinfo = self._getMapInfo() log.msg('displaying map %s' % (mapinfo['name'],)) self.model = Model(pygame.image.load(fs.downloads(mapinfo['name']))) self.main.blit(self.model.background, (0,0)) for n, character in enumerate(self._getCharacterInfo()): icon_image = pygame.image.load(fs.downloads(ch...
def displayModel(self): mapinfo = self._getMapInfo() log.msg('displaying map %s' % (mapinfo['name'],)) self.model = Model(pygame.image.load(fs.downloads(mapinfo['name']))) self.main.blit(self.model.background, (0,0)) for n, character in enumerate(self._getCharacterInfo()): icon_image = gdk.pixbuf_new_from_file( fs.down...
32,653
def displayModel(self): mapinfo = self._getMapInfo() log.msg('displaying map %s' % (mapinfo['name'],)) self.model = Model(pygame.image.load(fs.downloads(mapinfo['name']))) self.main.blit(self.model.background, (0,0)) for n, character in enumerate(self._getCharacterInfo()): icon_image = pygame.image.load(fs.downloads(ch...
def displayModel(self): mapinfo = self._getMapInfo() log.msg('displaying map %s' % (mapinfo['name'],)) self.model = Model(pygame.image.load(fs.downloads(mapinfo['name']))) self.main.blit(self.model.background, (0,0)) for n, character in enumerate(self._getCharacterInfo()): icon_image = pygame.image.load(fs.downloads(ch...
32,654
def irccmd_join(self, args, conv): groups=args.split()
def irccmd_join(self, args, conv): groups=args.split()
32,655
def irccmd_join(self, args, conv): groups=args.split()
def irccmd_join(self, args, conv): groups=args.split()
32,656
def irccmd_join(self, args, conv): groups=args.split()
def irccmd_join(self, args, conv): groups=args.split()
32,657
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
32,658
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
32,659
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
32,660
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
def irccmd_part(self, args, conv): groups=args.split() ircgroups=[]
32,661
def __init__(self, widget, *a, **kw): components.Componentized.__init__(self) basechat.Conversation.__init__(self, *a, **kw) self.widget = widget tabs = IChatConversations(widget) self.webPrint = lambda m: tabs.printClean(m, self.person.name)
def __init__(self, widget, *a, **kw): components.Componentized.__init__(self) basechat.Conversation.__init__(self, *a, **kw) self.widget = widget tabs = IChatConversations(widget) self.webPrint = lambda m: tabs.printClean(m, self.person.name)
32,662
def showMessage(self, text, metadata=None): if metadata and metadata.get("style", None) == "emote": t = '* %s %s' % (self.person.name, text) else: t = "<%s> %s" % (self.person.name, text) return self.webPrint(t)
def showMessage(self, text, metadata=None): if metadata and metadata.get("style", None) == "emote": t = '* %s %s' % (self.person.name, text) else: t = "<%s> %s" % (self.person.name, text) return self.webPrint(t)
32,663
def contactChangedNick(self, person, newnick): basechat.Conversation.contactChangedNick(self, person, newnick) event = "-!- %s is now known as %s" % (person.name, newnick) return self.webPrint(event)
def contactChangedNick(self, person, newnick): basechat.Conversation.contactChangedNick(self, person, newnick) event = "-!- %s is now known as %s" % (person.name, newnick) return self.webPrint(event)
32,664
def sendText(self, text, metadata=None): r = self.person.sendMessage(text, metadata) me = self.person.account.client.name if metadata and metadata.get('style', None) == 'emote': out = u'* %s %s' % (me, text) else: out = u'<%s> %s' % (me, text) self.webPrint(out)
def sendText(self, text, metadata=None): r = self.person.sendMessage(text, metadata) me = self.person.account.client.name if metadata and metadata.get('style', None) == 'emote': out = u'* %s %s' % (me, text) else: out = u'<%s> %s' % (me, text) self.webPrint(out)
32,665
def installOn(self, other): other.powerUp(self, IArticle)
def installOn(self, other): other.powerUp(self, IArticle)
32,666
def clientConnectionFailed(self, connector, reason): print "connection failed:", reason reactor.stop()
def clientConnectionFailed(self, connector, reason): print "connection failed:", reason reactor.stop()
32,667
def clientConnectionFailed(self, connector, reason): print "connection failed:", reason reactor.stop()
def clientConnectionFailed(self, connector, reason): print "connection failed:", reason reactor.stop()
32,668
def __init__(self, chatui): self.chatui = chatui
def__init__(self,chatui):self.chatui=chatui
32,669
def doConnection(self, host, username, password, channels): if username in ACCOUNTS and ACCOUNTS[username].isOnline(): self.disconnect(ACCOUNTS[username])
def doConnection(self, host, username, password, channels): if username in ACCOUNTS and ACCOUNTS[username].isOnline(): self.disconnect(ACCOUNTS[username])
32,670
def __init__(self, widget, *a, **kw): basechat.GroupConversation.__init__(self, *a, **kw) self.widget = widget self.webPrint = lambda m: widget.printClean(self.group.name, m)
def __init__(self, widget, *a, **kw): basechat.GroupConversation.__init__(self, *a, **kw) self.widget = widget self.webPrint = lambda m: widget.printClean(self.group.name, m)
32,671
def show(self): """If you don't have a GUI, this is a no-op. """ if self.group.name in self.widget.conversations: self.widget.foregroundConversation = self self.widget.callRemote("show", unicode(self.group.name))
def show(self): """If you don't have a GUI, this is a no-op. """ groupname = ' if groupname in self.widget.conversations: self.widget.foregroundConversation = self self.widget.callRemote("show", unicode(self.group.name))
32,672
def show(self): """If you don't have a GUI, this is a no-op. """ if self.group.name in self.widget.conversations: self.widget.foregroundConversation = self self.widget.callRemote("show", unicode(self.group.name))
def show(self): """If you don't have a GUI, this is a no-op. """ if self.group.name in self.widget.conversations: self.widget.foregroundConversation = self self.widget.callRemote("show", unicode(self.group.name))
32,673
def __init__(self, *args, **kwargs): loadAliases() self.encounters = [] self.party = encounter.Encounter() self.wtf = 0 # number of times a "wtf" has occurred recently. # reset wtf's every 30 seconds self.resetter = task.LoopingCall(self._resetWtfCount).start(30.0)
def __init__(self, *args, **kwargs): loadAliases() self.encounters = [] self.party = encounter.Encounter() self.wtf = 0 # number of times a "wtf" has occurred recently. # reset wtf's every 30 seconds self.resetter = task.LoopingCall(self._resetWtfCount).start(30.0)
32,674
def update(self, x, y): ha = self.gui.canvas.get_hadjustment() va = self.gui.canvas.get_vadjustment()
def update(self, x, y): ha = self.gui.canvas.get_hadjustment() va = self.gui.canvas.get_vadjustment()
32,675
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
32,676
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
32,677
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
32,678
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
32,679
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
32,680
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
32,681
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
def finish(self): """Zoom so the inscribed area is maximized in the main window""" if self.drawn: _d = {} for point in ('x1', 'y1', 'x2', 'y2'): _d[point] = self.drawn.get_property(point)
32,682
def update(self, x, y): if self.drawn: self.drawn.destroy() # FIXME - when bx > x, swap bx/by with x/y x, y = self.gui.canvas.c2w(x, y) bx, by = self.gui.canvas.c2w(self.begin_x, self.begin_y)
defupdate(self,x,y):ifself.drawn:self.drawn.destroy()#FIXME-whenbx>x,swapbx/bywithx/yx,y=self.gui.canvas.c2w(x,y)bx,by=self.gui.canvas.c2w(self.begin_x,self.begin_y)
32,683
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
def __init__(self, deferred, netclient, fps): self.fps = fps self.deferred = deferred self.netclient = netclient
32,684
def _f(*sib): return util.sibpath(webby.__file__, '/'.join(sib))
def _f(*sib): return util.sibpath(webby.__file__, '/'.join(sib))
32,685
def irc_unknown(self, prefix, command, params): log.msg('|||'.join(prefix, command, params))
def irc_unknown(self, prefix, command, params): log.msg('|||'.join(prefix, command, params))
32,686
def doConnection(self, host, username, password, channels): key = (username, host) if key in ACCOUNTS and ACCOUNTS[key].isOnline(): self.disconnect(ACCOUNTS[key])
def doConnection(self, host, username, password, channels): key = (username, host) if key in ACCOUNTS and ACCOUNTS[key].isOnline(): self.disconnect(ACCOUNTS[key])
32,687
def render_debug(self, ctx, data): f = athena.IntrospectionFragment() f.setFragmentParent(self) return ctx.tag[f]
def render_debug(self, ctx, data): f = athena.IntrospectionFragment() f.setFragmentParent(self) return ctx.tag[f]
32,688
def connectionLost(self, reason): """ Basically, t.words.im.basesupport.AbstractClientMixin is completely *fucked* in the head. Subclassing it is impossible, because of the stupid fucking self._protoBase, which turns out to be IRCProto, not this class.
def connectionLost(self, reason): """ Basically, t.words.im.basesupport.AbstractClientMixin is completely *fucked* in the head. Subclassing it is impossible, because of the stupid fucking self._protoBase, which turns out to be IRCProto, not this class.
32,689
def __init__(self): self.__dict__['observers'] = []
def __init__(self): self.__dict__['observers'] = []
32,690
def __setattr__(self, name, value): raise RuntimeError("Assignments must be made through an Arbiter.")
def __setattr__(self, name, value): raise RuntimeError("Assignments must be made through an Arbiter.")
32,691
def __setattr__(self, name, value): n = self.noumenon old = getattr(n, name, None)
def __setattr__(self, name, value): n = self.noumenon old = getattr(n, name, None)
32,692
def __getattr__(self, name): if name in self.noumenon.__phenomena__: return getattr(self.noumenon, name) raise AttributeError(name)
def __getattr__(self, name): if name in self.noumenon.__phenomena__: return getattr(self.noumenon, name) raise AttributeError(name)
32,693
def bar_changed(self, tag, model, old, new): output.append(('bar', old, new, tag))
def bar_changed(self, tag, model, old, new): output.append(('bar', old, new, tag))
32,694
def bar_changed(self, tag, model, old, new): output.append(('bar', old, new, tag))
def bar_changed(self, tag, model, old, new): output.append(('bar', old, new, tag))
32,695
def on_zoomfit_activate(self, widget): if self.canvas: print 'TODO: fit'
def on_zoomfit_activate(self, widget): if self.canvas: print 'TODO: fit'
32,696
def irc_unknown(self, prefix, command, params): log.msg('|||'.join((prefix, command, params)))
def irc_unknown(self, prefix, command, params): log.msg('|||'.join((prefix, command, params)))
32,697
def __init__(self): dispatcher.connect(self.receivePropertyChange, self)
def __init__(self): dispatcher.connect(self.receivePropertyChange, self)
32,698
def begin(self): assert None, "begin must be implemented in a subclass"
def begin(self): assert None, "begin must be implemented in a subclass"
32,699