rem stringlengths 1 322k | add stringlengths 0 2.05M | context stringlengths 4 228k | meta stringlengths 156 215 |
|---|---|---|---|
self.EnsureVisible(line) | self.GotoLine(line) | def ShowPosition(self, pos): line = self.LineFromPosition(pos) self.EnsureVisible(line) | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py |
self.SetViewEOL(False) | self.SetEOLMode(wx.stc.STC_EOL_LF) self.SetViewEOL(False) | def SetUpEditor(self): """ This method carries out the work of setting up the demo editor. It's seperate so as not to clutter up the init code. """ import keyword self.SetLexer(stc.STC_LEX_PYTHON) self.SetKeyWords(0, " ".join(keyword.kwlist)) | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py |
f = open(modifiedFilename, "w") | f = open(modifiedFilename, "wt") | def OnSave(self, event): if self.demoModules.Exists(modModified): if self.demoModules.GetActiveID() == modOriginal: overwriteMsg = "You are about to overwrite an already existing modified copy\n" + \ "Do you want to continue?" dlg = wx.MessageDialog(self, overwriteMsg, "wxPython Demo", wx.YES_NO | wx.NO_DEFAULT| wx.ICO... | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py |
file = open(filename, "r") | file = open(filename, "rt") | def LoadFromFile(self, modID, filename): self.modules[modID][2] = filename file = open(filename, "r") self.LoadFromSource(modID, file.read()) file.close() | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py |
file = open(filename, "w") | file = open(filename, "wt") | def UpdateFile(self, modID = None): """Updates the file from which a module was loaded with (possibly updated) source""" if modID is None: modID = self.modActive | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py |
helpID = wx.NewId() findID = wx.NewId() findnextID = wx.NewId() | def EmptyHandler(evt): pass | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py | |
prevSelect = self.UpdateNotebook() | def RunModule(self): """Runs the active module""" | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py | |
self.UpdateNotebook() | self.UpdateNotebook(prevSelect) | def RunModule(self): """Runs the active module""" | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py |
if select >= 0: | if select >= 0 and select < nb.GetPageCount(): | def UpdatePage(page, pageText): pageExists = False pagePos = -1 for i in range(nb.GetPageCount()): if nb.GetPageText(i) == pageText: pageExists = True pagePos = i break if page: if not pageExists: # Add a new page | 887a1bd93e986556d3118913cf1ca020a4077f74 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/887a1bd93e986556d3118913cf1ca020a4077f74/Main.py |
dc.SetPen(wx.Pen(wx.NamedColour(colour), int(width), style)) | pen = wx.Pen(wx.NamedColour(colour), width, style) pen.SetCap(wx.CAP_BUTT) dc.SetPen(pen) | def draw(self, dc, printerScale, coord= None): colour = self.attributes['colour'] width = self.attributes['width'] * printerScale style= self.attributes['style'] dc.SetPen(wx.Pen(wx.NamedColour(colour), int(width), style)) if coord == None: dc.DrawLines(self.scaled) else: dc.DrawLines(coord) # draw legend line | 00b9c8672fa526a520f6bc7793fdcdde97278d33 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/00b9c8672fa526a520f6bc7793fdcdde97278d33/plot.py |
dc.SetPen(wx.Pen(wx.NamedColour(colour),int(width))) | dc.SetPen(wx.Pen(wx.NamedColour(colour), width)) | def draw(self, dc, printerScale, coord= None): colour = self.attributes['colour'] width = self.attributes['width'] * printerScale size = self.attributes['size'] * printerScale fillcolour = self.attributes['fillcolour'] fillstyle = self.attributes['fillstyle'] marker = self.attributes['marker'] | 00b9c8672fa526a520f6bc7793fdcdde97278d33 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/00b9c8672fa526a520f6bc7793fdcdde97278d33/plot.py |
dc = FloatDCWrapper(wx.BufferedDC(wx.ClientDC(self), self._Buffer)) | dc = wx.BufferedDC(wx.ClientDC(self), self._Buffer) | def Draw(self, graphics, xAxis = None, yAxis = None, dc = None): """Draw objects in graphics with specified x and y axis. graphics- instance of PlotGraphics with list of PolyXXX objects xAxis - tuple with (min, max) axis range to view yAxis - same as xAxis dc - drawing context - doesn't have to be specified. If it's no... | 00b9c8672fa526a520f6bc7793fdcdde97278d33 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/00b9c8672fa526a520f6bc7793fdcdde97278d33/plot.py |
return int(ptx),int(pty),int(rectWidth),int(rectHeight) | return ptx, pty, rectWidth, rectHeight | def _point2ClientCoord(self, corner1, corner2): """Converts user point coords to client screen int coords x,y,width,height""" c1= Numeric.array(corner1) c2= Numeric.array(corner2) # convert to screen coords pt1= c1*self._pointScale+self._pointShift pt2= c2*self._pointScale+self._pointShift # make height and width posit... | 00b9c8672fa526a520f6bc7793fdcdde97278d33 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/00b9c8672fa526a520f6bc7793fdcdde97278d33/plot.py |
dc.SetPen(wx.Pen(wx.NamedColour('BLACK'),int(penWidth))) | dc.SetPen(wx.Pen(wx.NamedColour('BLACK'), penWidth)) | def _drawAxes(self, dc, p1, p2, scale, shift, xticks, yticks): penWidth= self.printerScale # increases thickness for printing only dc.SetPen(wx.Pen(wx.NamedColour('BLACK'),int(penWidth))) # set length of tick marks--long ones make grid if self._gridEnabled: x,y,width,height= self._point2ClientCoord(p1,p2) yTic... | 00b9c8672fa526a520f6bc7793fdcdde97278d33 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/00b9c8672fa526a520f6bc7793fdcdde97278d33/plot.py |
dc = FloatDCWrapper(self.GetDC()) | dc = self.GetDC() | def OnPrintPage(self, page): dc = FloatDCWrapper(self.GetDC()) # allows using floats for certain functions | 00b9c8672fa526a520f6bc7793fdcdde97278d33 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/00b9c8672fa526a520f6bc7793fdcdde97278d33/plot.py |
class FloatDCWrapper: def __init__(self, aDC): self.theDC = aDC def DrawLine(self, x1,y1,x2,y2): self.theDC.DrawLine(int(x1),int(y1), int(x2),int(y2)) def DrawText(self, txt, x, y): self.theDC.DrawText(txt, int(x), int(y)) def DrawRotatedText(self, txt, x, y, angle): self.theDC.DrawRotatedText(txt, int(x), int... | def OnPrintPage(self, page): dc = FloatDCWrapper(self.GetDC()) # allows using floats for certain functions | 00b9c8672fa526a520f6bc7793fdcdde97278d33 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/00b9c8672fa526a520f6bc7793fdcdde97278d33/plot.py | |
elif pt._type == CONTROL_POINT_DIAGONAL and (keys & KEYS or self.GetMaintainAspectRatio()): | elif pt._type == CONTROL_POINT_DIAGONAL and (keys & KEY_SHIFT or self.GetMaintainAspectRatio()): | def OnSizingBeginDragLeft(self, pt, x, y, keys = 0, attachment = 0): self._canvas.CaptureMouse() | bc37bfe2ee241f9c8d5da57011c8f5ba5d8bc29e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/bc37bfe2ee241f9c8d5da57011c8f5ba5d8bc29e/_basic.py |
def __init__(self, parent): wx.Panel.__init__(self, parent, -1, style=wx.SUNKEN_BORDER) | 9ca5a18a01a7d87870427cb0fc1962db2f11a45d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/9ca5a18a01a7d87870427cb0fc1962db2f11a45d/embedded_sample.py | ||
self.rowHeights = [] self.colWidths = [] | def CalcMin( self ): items = self.GetChildren() if not items: return wxSize(10, 10) | 47feb54b6b1d9225664cdf29eded39897cb3a9db /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/47feb54b6b1d9225664cdf29eded39897cb3a9db/rcsizer.py | |
return (0, 1, 1, 1) | return (1, 1, 1, 1) | def GetPageInfo(self): return (0, 1, 1, 1) # disable page numbers | e5ce86d84f4c697621182b63ce6c0a96fea2df70 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/e5ce86d84f4c697621182b63ce6c0a96fea2df70/plot.py |
ext = ft.GetExtensions()[0] if ext[0] == ".": ext = ext[1:] | extList = ft.GetExtensions() if extList: ext = extList[0] if ext[0] == ".": ext = ext[1:] else: ext = "" | def Update(self, ft): #icon = ft.GetIcon() info = ft.GetIconInfo() if info is None: bmp = MyBitmapsFunc(0) ##print bmp.Ok(), bmp.GetWidth(), bmp.GetHeight() self.GetIconBmp().SetBitmap(bmp) self.GetIconFileTxt().SetValue("") self.GetIconIndexTxt().SetValue("") else: icon, file, idx = info #bmp = wxBitmapFromIcon(icon) ... | 0d3859bf1efe083d145bea1d4c67b67c58ba995b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0d3859bf1efe083d145bea1d4c67b67c58ba995b/wxMimeTypesManager.py |
wx.wxButton(dlg, wx.ID_OK, "Find Next", (280, 5), wx.DefaultSize).SetDefault() wx.wxButton(dlg, wx.ID_CANCEL, "Cancel", (280, 35), wx.DefaultSize) | wx.Button(dlg, wx.ID_OK, "Find Next", (280, 5), wx.DefaultSize).SetDefault() wx.Button(dlg, wx.ID_CANCEL, "Cancel", (280, 35), wx.DefaultSize) | def findDialog(parent=None, searchText='', wholeWordsOnly=0, caseSensitive=0): dlg = wx.Dialog(parent, -1, "Find", wx.DefaultPosition, (370, 120)) wx.StaticText(dlg, -1, 'Find what:', (7, 10)) wSearchText = wx.TextCtrl(dlg, -1, searchText, (70, 7), (195, -1)) wSearchText.SetValue(searchText) wx.wxButton(dlg, wx.ID_OK,... | a5deb2fbe715756970bfef8adce7bb0c9dcb0af9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a5deb2fbe715756970bfef8adce7bb0c9dcb0af9/dialogs.py |
frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) | self.frame = frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) | def OnInit(self): frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) panel = wx.Panel(frame, -1) self.panel = panel | a5deb2fbe715756970bfef8adce7bb0c9dcb0af9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a5deb2fbe715756970bfef8adce7bb0c9dcb0af9/dialogs.py |
frame.Show(1) | def OnInit(self): frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) panel = wx.Panel(frame, -1) self.panel = panel | a5deb2fbe715756970bfef8adce7bb0c9dcb0af9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a5deb2fbe715756970bfef8adce7bb0c9dcb0af9/dialogs.py | |
self.nameList = wx.ListBox(panel, -1, (0, 0), (130, 180), dialogNames, style=wx.LB_SINGLE) self.Bind(wx.EVT_LISTBOX, self.OnNameListSelected, id=self.nameList.GetId()) | self.nameList = wx.ListBox(panel, -1, size=(130, 180), choices=dialogNames, style=wx.LB_SINGLE) self.Bind(wx.EVT_LISTBOX, self.OnNameListSelected, self.nameList) | def OnInit(self): frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) panel = wx.Panel(frame, -1) self.panel = panel | a5deb2fbe715756970bfef8adce7bb0c9dcb0af9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a5deb2fbe715756970bfef8adce7bb0c9dcb0af9/dialogs.py |
self.text1 = wx.TextCtrl(panel, -1, pos=(150, 0), size=(200, 180), style=tstyle) | self.text1 = wx.TextCtrl(panel, -1, size=(200, 180), style=tstyle) sizer = wx.BoxSizer(wx.HORIZONTAL) sizer.Add(self.nameList, 0, wx.EXPAND|wx.ALL, 20) sizer.Add(self.text1, 1, wx.EXPAND|wx.ALL, 20) panel.SetSizer(sizer) | def OnInit(self): frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) panel = wx.Panel(frame, -1) self.panel = panel | a5deb2fbe715756970bfef8adce7bb0c9dcb0af9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a5deb2fbe715756970bfef8adce7bb0c9dcb0af9/dialogs.py |
frame.Show(1) | def OnInit(self): frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) panel = wx.Panel(frame, -1) self.panel = panel | a5deb2fbe715756970bfef8adce7bb0c9dcb0af9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a5deb2fbe715756970bfef8adce7bb0c9dcb0af9/dialogs.py | |
'A Message Box', wx.wxOK | wx.wxICON_INFORMATION) | 'A Message Box', wx.OK | wx.ICON_INFORMATION) | def OnNameListSelected(self, evt): import pprint sel = evt.GetString() result = None if sel == 'alertDialog': result = alertDialog(message='Danger Will Robinson') elif sel == 'colorDialog': result = colorDialog() elif sel == 'directoryDialog': result = directoryDialog() elif sel == 'fileDialog': wildcard = "JPG files (... | a5deb2fbe715756970bfef8adce7bb0c9dcb0af9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a5deb2fbe715756970bfef8adce7bb0c9dcb0af9/dialogs.py |
def CreateView(self, document, flags=0): | def CreateView(self, doc, flags=0): | def CreateView(self, document, flags=0): """ Creates a new view for the given document. If more than one view is allowed for the document (by virtue of multiple templates mentioning the same document type), a choice of view is presented to the user. """ templates = [] for temp in self._templates: if temp.IsVisible(): i... | 5088276afa09aa8fa540f670d6d5b8ef53957a8f /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/5088276afa09aa8fa540f670d6d5b8ef53957a8f/docview.py |
if os.path.exists("splash.png"): self.ShowSplash("splash.png") | if os.path.exists(TextEditorApplication.SPLASH): self.ShowSplash(TextEditorApplication.SPLASH) | def OnInit(self): # Call the super - this is important!!! pydocview.DocApp.OnInit(self) | e4f504f02b68c0bf933209edee227ec8c0c4f046 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/e4f504f02b68c0bf933209edee227ec8c0c4f046/PyDocViewDemo.py |
if os.path.exists("splash.jpg"): aboutService = self.InstallService(pydocview.AboutService(image=wx.Image("splash.jpg"))) | if os.path.exists(TextEditorApplication.SPLASH): aboutService = self.InstallService(pydocview.AboutService(image=wx.Image(TextEditorApplication.SPLASH))) | def OnInit(self): # Call the super - this is important!!! pydocview.DocApp.OnInit(self) | e4f504f02b68c0bf933209edee227ec8c0c4f046 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/e4f504f02b68c0bf933209edee227ec8c0c4f046/PyDocViewDemo.py |
if os.path.exists("splash.jpg"): | if os.path.exists(TextEditorApplication.SPLASH): | def OnInit(self): # Call the super - this is important!!! pydocview.DocApp.OnInit(self) | e4f504f02b68c0bf933209edee227ec8c0c4f046 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/e4f504f02b68c0bf933209edee227ec8c0c4f046/PyDocViewDemo.py |
In addition to the usual arguments, wxFloatBar accepts keyword args of: title(string): the title that should appear on the toolbar's frame when it is floating. floatable(bool): whether user actions (i.e., dragging) can float the toolbar or not. | wxToolBar subclass which can be dragged off its frame and later replaced there. Drag on the toolbar to release it, close it like a normal window to make it return to its original position. Programmatically, call SetFloatable(true) and then Float(true) to float, Float(false) to dock. | def __init__(self,*_args,**_kwargs): """ In addition to the usual arguments, wxFloatBar accepts keyword args of: title(string): the title that should appear on the toolbar's frame when it is floating. floatable(bool): whether user actions (i.e., dragging) can float the toolbar or not. """ args = (self,) + _args apply(... | 8211bdcc03edec14659d55433553dcdd648dc7db /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/8211bdcc03edec14659d55433553dcdd648dc7db/floatbar.py |
args = (self,) + _args apply(wxToolBar.__init__, args, _kwargs) if _kwargs.has_key('floatable'): self.floatable = _kwargs['floatable'] assert type(self.floatable) == type(0) else: self.floatable = 0 self.floating = 0 if _kwargs.has_key('title'): self.title = _kwargs['title'] assert type(self.title) == type("") else: se... | def __init__(self,*_args,**_kwargs): """ In addition to the usual arguments, wxFloatBar accepts keyword args of: title(string): the title that should appear on the toolbar's frame when it is floating. floatable(bool): whether user actions (i.e., dragging) can float the toolbar or not. """ args = (self,) + _args apply... | def __init__(self,*_args,**_kwargs): """ In addition to the usual arguments, wxFloatBar accepts keyword args of: title(string): the title that should appear on the toolbar's frame when it is floating. floatable(bool): whether user actions (i.e., dragging) can float the toolbar or not. """ args = (self,) + _args apply(... | 8211bdcc03edec14659d55433553dcdd648dc7db /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/8211bdcc03edec14659d55433553dcdd648dc7db/floatbar.py |
self.floatframe.SetToolBar(None) self.floatframe.Destroy() size = self.parentframe.GetSize() self.parentframe.SetSize(wxSize(0,0)) self.parentframe.SetSize(size) self.SetBackgroundColour(self.oldcolor) def OnDock(self, e): self.Float(0) if hasattr(self, 'oldpos'): del self.oldpos def OnMove(self, e): homepos = self... | if _kwargs.has_key('title'): self.title = _kwargs['title'] assert type(self.title) == type("") else: self.title = "" EVT_MOUSE_EVENTS(self, self.OnMouse) self.parentframe = wxPyTypeCast(args[1], 'wxFrame') def IsFloatable(self): return self.floatable def SetFloatable(self, float): self.floatable = float if not has... | def Float(self, bool): "Floats or docks the toolbar programmatically." if bool: self.parentframe = wxPyTypeCast(self.GetParent(), 'wxFrame') print self.title if self.title: useStyle = wxDEFAULT_FRAME_STYLE else: useStyle = wxTHICK_FRAME self.floatframe = wxFrame(self.parentframe, -1, self.title, style = useStyle) | 8211bdcc03edec14659d55433553dcdd648dc7db /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/8211bdcc03edec14659d55433553dcdd648dc7db/floatbar.py |
homepos = self.parentframe.ClientToScreen(wxPoint(0,0)) floatpos = self.floatframe.GetPosition() if (abs(homepos.x - floatpos.x) < _DOCKTHRESHOLD and abs(homepos.y - floatpos.y) < _DOCKTHRESHOLD): self.Float(0) return if e.Dragging(): if not self.IsFloating(): self.Float(true) self.oldpos = (e.GetX(), e.GetY()) else: ... | self.floatframe.SetTitle(self.title) def Float(self, bool): "Floats or docks the toolbar programmatically." if bool: self.parentframe = wxPyTypeCast(self.GetParent(), 'wxFrame') print self.title if self.title: useStyle = wxDEFAULT_FRAME_STYLE else: useStyle = wxTHICK_FRAME self.float... | def OnMouse(self, e): if not self.IsFloatable(): e.Skip() return | 8211bdcc03edec14659d55433553dcdd648dc7db /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/8211bdcc03edec14659d55433553dcdd648dc7db/floatbar.py |
print "Set size" else: print self.parentframe.GetToolBar() else: if self.parentframe.GetToolBar() != None: print "Removing fauxbar" self.nullbar.Reparent(self.floatframe) self.parentframe.SetToolBar(None) size = self.parentframe.GetSize() self.parentframe.SetSize(wxSize(0,0)) self.parentframe.SetSize(size) ... | self.SetBackgroundColour(self.oldcolor) def OnDock(self, e): self.Float(0) if hasattr(self, 'oldpos'): del self.oldpos def OnMove(self, e): homepos = self.parentframe.ClientToScreen(wxPoint(0,0)) floatpos = self.floatframe.GetPosition() if (abs(homepos.x - floatpos.x) < _DOCKTHRESHOLD and abs(homepos.y - floatpos.y... | def _SetFauxBarVisible(self, vis): return if vis: if self.parentframe.GetToolBar() == None: if not hasattr(self, 'nullbar'): self.nullbar = wxToolBar(self.parentframe, -1) print "Adding fauxbar." self.nullbar.Reparent(self.parentframe) print "Reparented." self.parentframe.SetToolBar(self.nullbar) print "Set toolbar" co... | 8211bdcc03edec14659d55433553dcdd648dc7db /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/8211bdcc03edec14659d55433553dcdd648dc7db/floatbar.py |
bottomPanel.SetOwnBackroundColour("light blue") | bottomPanel.SetOwnBackgroundColour("light blue") | def __init__(self): wx.Frame.__init__(self, None, -1, "Widget Layout Tester") | a39c03f9d298283c5ea91532c7544aeaf4c0f243 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a39c03f9d298283c5ea91532c7544aeaf4c0f243/widgetLayoutTest.py |
self.testPanel.SetOwnBackroundColour((205, 183, 181)) | self.testPanel.SetOwnBackgroundColour((205, 183, 181)) | def __init__(self): wx.Frame.__init__(self, None, -1, "Widget Layout Tester") | a39c03f9d298283c5ea91532c7544aeaf4c0f243 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a39c03f9d298283c5ea91532c7544aeaf4c0f243/widgetLayoutTest.py |
class BasePopupFrame(wx.MiniFrame): | class BasePopupFrame(wx.Frame): | def GetSelection(self): """ Extend GetSelection to never return the root item if the root item is hidden. """ selection = super(IterableTreeCtrl, self).GetSelection() if selection == self.GetRootItem() and \ (self.GetWindowStyle() & wx.TR_HIDE_ROOT): return wx.TreeItemId() # Return an invalid TreeItemId else: return se... | 49e0b673c32de3a1447242aad9d7b84299ed7859 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/49e0b673c32de3a1447242aad9d7b84299ed7859/combotreebox.py |
fucntions, in order to reduce the clutter in the API docs. | functions, in order to reduce the clutter in the API docs. | def Notify(self): """ The timer has expired so call the callable. """ if self.callable and getattr(self.callable, 'im_self', True): self.runCount += 1 self.running = False self.result = self.callable(*self.args, **self.kwargs) self.hasRun = True if not self.running: # if it wasn't restarted, then cleanup wx.CallAfter(s... | 955e46d25d6ac0f9fa55ec9fe11f0c21da3a494d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/955e46d25d6ac0f9fa55ec9fe11f0c21da3a494d/_core_ex.py |
self.printData.SetPrintMode(wx.PRINT_MODE_PRINTER) | def __init__(self, parent, frame, log): wx.Panel.__init__(self, parent, -1) self.log = log self.frame = frame | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py | |
self.Bind(wx.EVT_BUTTON, self.OnPrintSetup, id=ID_Setup) | self.Bind(wx.EVT_BUTTON, self.OnPrintSetup, btn) | def __init__(self, parent, frame, log): wx.Panel.__init__(self, parent, -1) self.log = log self.frame = frame | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py |
self.Bind(wx.EVT_BUTTON, self.OnPrintPreview, id=ID_Preview) | self.Bind(wx.EVT_BUTTON, self.OnPrintPreview, btn) | def __init__(self, parent, frame, log): wx.Panel.__init__(self, parent, -1) self.log = log self.frame = frame | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py |
self.Bind(wx.EVT_BUTTON, self.OnDoPrint, id=ID_Print) | self.Bind(wx.EVT_BUTTON, self.OnDoPrint, btn) | def __init__(self, parent, frame, log): wx.Panel.__init__(self, parent, -1) self.log = log self.frame = frame | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py |
printerDialog = wx.PrintDialog(self) printerDialog.GetPrintDialogData().SetPrintData(self.printData) | data = wx.PrintDialogData(self.printData) printerDialog = wx.PrintDialog(self, data) | def OnPrintSetup(self, event): printerDialog = wx.PrintDialog(self) printerDialog.GetPrintDialogData().SetPrintData(self.printData) printerDialog.GetPrintDialogData().SetSetupDialog(True) printerDialog.ShowModal(); self.printData = printerDialog.GetPrintDialogData().GetPrintData() printerDialog.Destroy() | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py |
self.preview = wx.PrintPreview(printout, printout2, self.printData) | self.preview = wx.PrintPreview(printout, printout2, data) | def OnPrintPreview(self, event): self.log.WriteText("OnPrintPreview\n") printout = MyPrintout(self.canvas, self.log) printout2 = MyPrintout(self.canvas, self.log) self.preview = wx.PrintPreview(printout, printout2, self.printData) | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py |
pdd = wx.PrintDialogData() pdd.SetPrintData(self.printData) | pdd = wx.PrintDialogData(self.printData) pdd.SetToPage(2) | def OnDoPrint(self, event): pdd = wx.PrintDialogData() pdd.SetPrintData(self.printData) printer = wx.Printer(pdd) printout = MyPrintout(self.canvas, self.log) | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py |
if not printer.Print(self.frame, printout): | if not printer.Print(self.frame, printout, True): | def OnDoPrint(self, event): pdd = wx.PrintDialogData() pdd.SetPrintData(self.printData) printer = wx.Printer(pdd) printout = MyPrintout(self.canvas, self.log) | d88d4683f3e85a5a9b63e8bd95686a42e7d1203a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d88d4683f3e85a5a9b63e8bd95686a42e7d1203a/PrintFramework.py |
changeCallback= lambda x:x | changeCallback= lambda x:x, labelWidth = 0 | def __init__ (self, parent, id= -1, pos = wx.DefaultPosition, size = wx.DefaultSize, style = wx.TAB_TRAVERSAL, labelText= "File Entry:", buttonText= "Browse", toolTip= "Type filename or click browse to choose file", # following are the values for a file dialog box dialogTitle = "Choose a file", startDirectory = ".", in... | 82184c0abfd1020218fd6ee1d0b2b914002b60a2 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/82184c0abfd1020218fd6ee1d0b2b914002b60a2/filebrowsebutton.py |
self.labelWidth = labelWidth | def __init__ (self, parent, id= -1, pos = wx.DefaultPosition, size = wx.DefaultSize, style = wx.TAB_TRAVERSAL, labelText= "File Entry:", buttonText= "Browse", toolTip= "Type filename or click browse to choose file", # following are the values for a file dialog box dialogTitle = "Choose a file", startDirectory = ".", in... | 82184c0abfd1020218fd6ee1d0b2b914002b60a2 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/82184c0abfd1020218fd6ee1d0b2b914002b60a2/filebrowsebutton.py | |
label.SetSize((w+5, h)) | if self.labelWidth > 0: label.SetSize((self.labelWidth+5, h)) else: label.SetSize((w+5, h)) | def createLabel( self ): """Create the label/caption""" label = wx.StaticText(self, -1, self.labelText, style =wx.ALIGN_RIGHT ) font = label.GetFont() w, h, d, e = self.GetFullTextExtent(self.labelText, font) label.SetSize((w+5, h)) return label | 82184c0abfd1020218fd6ee1d0b2b914002b60a2 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/82184c0abfd1020218fd6ee1d0b2b914002b60a2/filebrowsebutton.py |
self.GetEventHandler().OnEndSize(bound_x, bound_y) | self.GetEventHandler().OnBeginSize(bound_x, bound_y) | def OnSizingBeginDragLeft(self, pt, x, y, keys = 0, attachment = 0): self._canvas.CaptureMouse() | b14b1312ace5e4056f68951679241bdd53f1f987 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/b14b1312ace5e4056f68951679241bdd53f1f987/_basic.py |
H = ((y3 - y2) / (x32 - x2)) | H = ((y3 - y2) / (x2 - x2)) | def DrawArcToEllipse(x1, y1, width1, height1, x2, y2, x3, y3): a1 = width1 / 2 b1 = height1 / 2 # Check that x2 != x3 if abs(x2 - x3)<0.05: x4 = x2 if y3>y2: y4 = y1 - sqrt((b1 * b1 - (((x2 - x1) * (x2 - x1)) * (b1 * b1) / (a1 * a1)))) else: y4 = y1 + sqrt((b1 * b1 - (((x2 - x1) * (x2 - x1)) * (b1 * b1) / (a1 * a1))))... | 04717ee7df0ddc5d7857e2c277988cfb193e376b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/04717ee7df0ddc5d7857e2c277988cfb193e376b/oglmisc.py |
buttonPanel.SetAutoLayout(1) | def __init__(self, parent, log): wx.Panel.__init__(self, parent, -1) self.log = log | 78a32590b12dd14507a3c175e346543bef4ad63e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/78a32590b12dd14507a3c175e346543bef4ad63e/EventManager.py | |
self.SetAutoLayout(1) | def __init__(self, parent, log): wx.Panel.__init__(self, parent, -1) self.log = log | 78a32590b12dd14507a3c175e346543bef4ad63e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/78a32590b12dd14507a3c175e346543bef4ad63e/EventManager.py | |
class Tile(wx.Panel): | class Tile(wx.Window): | def __init__(self, parent, log): wx.Panel.__init__(self, parent, -1) self.log = log | 78a32590b12dd14507a3c175e346543bef4ad63e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/78a32590b12dd14507a3c175e346543bef4ad63e/EventManager.py |
wx.Panel.__init__(self, parent, -1, size=size, style=wx.CLIP_CHILDREN) | wx.Window.__init__(self, parent, -1, size=size, style=wx.CLIP_CHILDREN) | def __init__(self, parent, log, factor=1, thingToWatch=None, bgColor=None, active=1, size=(38,38), borderWidth=3): wx.Panel.__init__(self, parent, -1, size=size, style=wx.CLIP_CHILDREN) self.tile = InnerTile(self, log, factor, thingToWatch, bgColor) self.log = log sizer = wx.BoxSizer(wx.HORIZONTAL) sizer.Add(self.tile... | 78a32590b12dd14507a3c175e346543bef4ad63e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/78a32590b12dd14507a3c175e346543bef4ad63e/EventManager.py |
self.SetAutoLayout(1) | def __init__(self, parent, log, factor=1, thingToWatch=None, bgColor=None, active=1, size=(38,38), borderWidth=3): wx.Panel.__init__(self, parent, -1, size=size, style=wx.CLIP_CHILDREN) self.tile = InnerTile(self, log, factor, thingToWatch, bgColor) self.log = log sizer = wx.BoxSizer(wx.HORIZONTAL) sizer.Add(self.tile... | 78a32590b12dd14507a3c175e346543bef4ad63e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/78a32590b12dd14507a3c175e346543bef4ad63e/EventManager.py | |
class InnerTile(wx.Panel): | class InnerTile(wx.Window): | def setNormal(self, event): self.SetBackgroundColour(Tile.normal) self.Refresh() | 78a32590b12dd14507a3c175e346543bef4ad63e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/78a32590b12dd14507a3c175e346543bef4ad63e/EventManager.py |
wx.Panel.__init__(self, parent, -1) | wx.Window.__init__(self, parent, -1) | def __init__(self, parent, log, factor, thingToWatch=None, bgColor=None): wx.Panel.__init__(self, parent, -1) self.log=log if bgColor: self.SetBackgroundColour(bgColor) if thingToWatch: self.factor = factor self.thingToWatch = thingToWatch self.state = 0 self.toggleOnOff() # Watch for the mouse click to en... | 78a32590b12dd14507a3c175e346543bef4ad63e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/78a32590b12dd14507a3c175e346543bef4ad63e/EventManager.py |
def __del__(self): if hasattr(self, "set_colour_val"): del self.set_colour_val | def __del__(self): if hasattr(self, "set_colour_val"): del self.set_colour_val | a6ee08e16adcbd4aaf1f47690b79d8040f8ea1ee /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a6ee08e16adcbd4aaf1f47690b79d8040f8ea1ee/colourselect.py | |
self.set_colour_val = wxColour(bcolour[0], bcolour[1], bcolour[2]) | def SetColourValue(self, bcolour): self.set_colour_val = wxColour(bcolour[0], bcolour[1], bcolour[2]) self.set_colour = bcolour | a6ee08e16adcbd4aaf1f47690b79d8040f8ea1ee /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a6ee08e16adcbd4aaf1f47690b79d8040f8ea1ee/colourselect.py | |
self.SetBackgroundColour(self.set_colour_val) | self.SetBackgroundColour(self.Get_wxColour()) | def SetColourValue(self, bcolour): self.set_colour_val = wxColour(bcolour[0], bcolour[1], bcolour[2]) self.set_colour = bcolour | a6ee08e16adcbd4aaf1f47690b79d8040f8ea1ee /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/a6ee08e16adcbd4aaf1f47690b79d8040f8ea1ee/colourselect.py |
return list( self.history ) | return [] | def GetHistory( self ): """Return the current history list""" if self.historyCallBack != None: return self.historyCallBack() else: return list( self.history ) | 2c3e35c2fcd636a3c9a280e19feb47dc5eb053ae /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/2c3e35c2fcd636a3c9a280e19feb47dc5eb053ae/filebrowsebutton.py |
result.text = wSearchText.GetValue() result.wholeword = wWholeWord.GetValue() result.casesensitive = wCase.GetValue() | result.searchText = wSearchText.GetValue() result.wholeWordsOnly = wWholeWord.GetValue() result.caseSensitive = wCase.GetValue() | def findDialog(parent=None, searchText='', wholeWordsOnly=0, caseSensitive=0): dlg = wx.Dialog(parent, -1, "Find", wx.DefaultPosition, (380, 120)) wx.StaticText(dlg, -1, 'Find what:', (7, 10)) wSearchText = wx.TextCtrl(dlg, -1, searchText, (80, 7), (195, -1)) wSearchText.SetValue(searchText) wx.Button(dlg, wx.ID_OK, "... | 19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b/dialogs.py |
aFontData.SetInitialFont(font) | fontData.SetInitialFont(font) | def fontDialog(parent=None, fontData=None, font=None): if fontData is None: fontData = wx.FontData() fontData.SetColour(wx.BLACK) fontData.SetInitialFont(wx.SystemSettings.GetFont(wx.SYS_DEFAULT_GUI_FONT)) if font is not None: aFontData.SetInitialFont(font) dialog = wx.FontDialog(parent, fontData) result = DialogResu... | 19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b/dialogs.py |
dialog = wx.SingleChoiceDialog(parent, message, title, lst, style) | dialog = wx.SingleChoiceDialog(parent, message, title, list(lst), style | wx.DEFAULT_DIALOG_STYLE) | def singleChoiceDialog(parent=None, message='', title='', lst=[], style=wx.OK | wx.CANCEL | wx.CENTRE): dialog = wx.SingleChoiceDialog(parent, message, title, lst, style) result = DialogResults(dialog.ShowModal()) result.selection = dialog.GetStringSelection() dialog.Destroy() return result | 19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b/dialogs.py |
self.frame = frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) | self.frame = frame = wx.Frame(None, -1, "Dialogs", size=(400, 240)) | def OnInit(self): self.frame = frame = wx.Frame(None, -1, "Dialogs", size=(400, 200)) panel = wx.Panel(frame, -1) self.panel = panel | 19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/19cc8ed9e1e5501e5181c61ac69cc5a1a9b5772b/dialogs.py |
def __del__(self): try: self.RestoreStdio() finally: wx.PyApp.__del__(self) | def __del__(self, destroy=wx.PyApp.__del__): self.RestoreStdio() destroy(self) | def __del__(self): try: self.RestoreStdio() # Just in case the MainLoop was overridden finally: wx.PyApp.__del__(self) | 99269e6cd14977d540e4c8f816bfc6eadb788848 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/99269e6cd14977d540e4c8f816bfc6eadb788848/_app_ex.py |
_sys.stdout, _sys.stderr = self.saveStdio | try: _sys.stdout, _sys.stderr = self.saveStdio except: pass | def RestoreStdio(self): _sys.stdout, _sys.stderr = self.saveStdio | 99269e6cd14977d540e4c8f816bfc6eadb788848 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/99269e6cd14977d540e4c8f816bfc6eadb788848/_app_ex.py |
elif evt.LeftUp and self._draggedShape and self._dragState == ContinueDraggingLeft: | elif evt.LeftUp() and self._draggedShape and self._dragState == ContinueDraggingLeft: | def OnMouseEvent(self, evt): dc = wx.ClientDC(self) self.PrepareDC(dc) x, y = evt.GetLogicalPosition(dc) | 478ba84485d00d0d9a80ce3304f226355f457471 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/478ba84485d00d0d9a80ce3304f226355f457471/_canvas.py |
raise VersionError("wxversion.select() must be called before wxPython is imported") | raise VersionError("wxversion.selectNewest() must be called before wxPython is imported") | def selectNewest(minVersion): """ Selects a version of wxPython that has a version number greater than or equal to the version given. If a matching version is not found then instead of raising an exception like select() does this function will inform the user of that fact with a message dialog, open the system's defau... | 14b0f0d5066f2fe05201be98c1d563c9bd83280d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/14b0f0d5066f2fe05201be98c1d563c9bd83280d/wxversion.py |
0, wx.ALIGN_RIGHT|wx.ALIGN_CENTER_VERTICAL |wx.LEFT, 10) | 0, wx.ALIGN_RIGHT|wx.ALIGN_CENTER_VERTICAL |wx.LEFT|wx.RIGHT, 10) | def __init__(self): wx.Frame.__init__(self, None, -1, "Widget Layout Tester") | 0bdcd2f50750d235bff2766f3d03d7228aa88dff /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0bdcd2f50750d235bff2766f3d03d7228aa88dff/widgetLayoutTest.py |
idx = self.testHistory.GetSelection() | idx = evt.GetInt() | def OnHistorySelect(self, evt): idx = self.testHistory.GetSelection() if idx != wx.NOT_FOUND: item = self.history[idx] self.moduleName.SetValue(item[0]) self.className.SetValue(item[1]) self.parameters.SetValue(item[2]) self.postCreate.SetValue(item[3]) | 0bdcd2f50750d235bff2766f3d03d7228aa88dff /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0bdcd2f50750d235bff2766f3d03d7228aa88dff/widgetLayoutTest.py |
app = wx.PySimpleApp(redirect=True) | app = wx.PySimpleApp(redirect=False) | def Clear(self): self._fgtxt.SetValue("") self._bgtxt.SetValue("") self._fgclr.SetBackgroundColour(self.GetBackgroundColour()) self._bgclr.SetBackgroundColour(self.GetBackgroundColour()) self._fgclr.Refresh() self._bgclr.Refresh() | 0bdcd2f50750d235bff2766f3d03d7228aa88dff /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0bdcd2f50750d235bff2766f3d03d7228aa88dff/widgetLayoutTest.py |
if WXPREFIX.startswith(root): | if root is None or WXPREFIX.startswith(root): | def run(self): if os.name == 'nt': return headers = self.distribution.headers if not headers: return | 862b53623ba193fd91e86f4f22d367b1e08e2816 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/862b53623ba193fd91e86f4f22d367b1e08e2816/config.py |
"wx.Choice and then move the mouse into the dineo below \n" | "wx.Choice and then move the mouse into the window below \n" | def __init__(self, parent, log): self.log = log wx.Panel.__init__(self, parent, -1) | 2fa9ab8174120441e96d8e1031a57fb6ffd34441 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/2fa9ab8174120441e96d8e1031a57fb6ffd34441/Cursor.py |
self._controlPoints.Append(control) | self._controlPoints.append(control) | def MakeControlPoints(self): """Make handle control points.""" if self._canvas and self._lineControlPoints: first = self._lineControlPoints[0] last = self._lineControlPoints[-1] | d8f9d612beeee767cc969468c635e494dcbf08df /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d8f9d612beeee767cc969468c635e494dcbf08df/_lines.py |
self._controlPoints.Append(control) | self._controlPoints.append(control) | def MakeControlPoints(self): """Make handle control points.""" if self._canvas and self._lineControlPoints: first = self._lineControlPoints[0] last = self._lineControlPoints[-1] | d8f9d612beeee767cc969468c635e494dcbf08df /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d8f9d612beeee767cc969468c635e494dcbf08df/_lines.py |
self._controlPoints.Append(control) | self._controlPoints.append(control) | def MakeControlPoints(self): """Make handle control points.""" if self._canvas and self._lineControlPoints: first = self._lineControlPoints[0] last = self._lineControlPoints[-1] | d8f9d612beeee767cc969468c635e494dcbf08df /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d8f9d612beeee767cc969468c635e494dcbf08df/_lines.py |
repr_ = reduce(lambda a,b: '%s|%s' % (a,b), value) | if value: repr_ = reduce(lambda a,b: '%s|%s' % (a,b), value) else: repr_ = '' | def SetValue(self, value): self.freeze = True if not value: value = [] self.value = value repr_ = reduce(lambda a,b: '%s|%s' % (a,b), value) self.text.SetValue(repr_) # update text ctrl self.freeze = False | 96bfe7feee455ee1d97a970c403c21d176634310 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/96bfe7feee455ee1d97a970c403c21d176634310/params.py |
self.InsertWindow(sys.maxint, window, sashPos) | self.InsertWindow(len(self._windows), window, sashPos) | def AppendWindow(self, window, sashPos=-1): """ Add a new window to the splitter at the right side or bottom of the window stack. If sashPos is given then it is used to size the new window. """ self.InsertWindow(sys.maxint, window, sashPos) | 8948306f7868ceea54691f31209c9daf3882be1d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/8948306f7868ceea54691f31209c9daf3882be1d/splitter.py |
idx = idx * 5 + ends[1] / 12 idx = idx - 1 if idx < 0 or idx > 59: | idx = idx * 5 + ends[1] / 12 - 1 elif idx <= 0 or idx > 60: | def _draw(self, dc, shadow=False): ends = [int(x) for x in strftime("%I %M %S", localtime()).split()] | 5079d4eb4115649dd1e54d9ccd9581388d367054 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/5079d4eb4115649dd1e54d9ccd9581388d367054/helpers.py |
print icon.__class__.__name__ | def AddIcon(self, icon, mask = wxNullBitmap): '''Add an icon to the image list, or get the index if already there''' index = self.__magicImageListMapping.get (id (icon)) if index is None: if isinstance( icon, wxIconPtr ): index = self.__magicImageList.AddIcon( icon ) elif isinstance( icon, wxBitmapPtr ): if isinstance(... | 60be92e035d03a3ebb7f956ee0a447fdbd3adfff /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/60be92e035d03a3ebb7f956ee0a447fdbd3adfff/imagelist.py | |
self._lastColMinWidth = None | self._resizeColMinWidth = None self._resizeColStyle = "LAST" self._resizeCol = 0 | def __init__(self): """ Standard initialiser. """ self._lastColMinWidth = None | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py |
self._lastColMinWidth = minWidth | self.resizeCloumn(self, minWidth) def resizeColumn(self, minWidth): self._resizeColMinWidth = minWidth | def resizeLastColumn(self, minWidth): """ Resize the last column appropriately. | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py |
if self._lastColMinWidth == None: self._lastColMinWidth = self.GetColumnWidth(numCols - 1) | if(self._resizeColStyle == "LAST"): resizeCol = self.GetColumnCount() else: resizeCol = self._resizeCol if self._resizeColMinWidth == None: self._resizeColMinWidth = self.GetColumnWidth(resizeCol - 1) | def _doResize(self): """ Resize the last column as appropriate. | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py |
for col in range(numCols-1): totColWidth = totColWidth + self.GetColumnWidth(col) lastColWidth = self.GetColumnWidth(numCols - 1) if totColWidth + self._lastColMinWidth > listWidth: | for col in range(numCols): if col != (resizeCol-1): totColWidth = totColWidth + self.GetColumnWidth(col) resizeColWidth = self.GetColumnWidth(resizeCol - 1) if totColWidth + self._resizeColMinWidth > listWidth: | def _doResize(self): """ Resize the last column as appropriate. | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py |
self.SetColumnWidth(numCols-1, self._lastColMinWidth) | self.SetColumnWidth(resizeCol-1, self._resizeColMinWidth) | def _doResize(self): """ Resize the last column as appropriate. | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py |
self.SetColumnWidth(numCols-1, listWidth - totColWidth) | self.SetColumnWidth(resizeCol-1, listWidth - totColWidth) | def _doResize(self): """ Resize the last column as appropriate. | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py |
style |= {wx.LIST_FORMAT_LEFT: wx.TE_LEFT, wx.LIST_FORMAT_RIGHT: wx.TE_RIGHT, wx.LIST_FORMAT_CENTRE : wx.TE_CENTRE}[col_style] | style |= {wx.LIST_FORMAT_LEFT: wx.TE_LEFT, wx.LIST_FORMAT_RIGHT: wx.TE_RIGHT, wx.LIST_FORMAT_CENTRE : wx.TE_CENTRE }[col_style] | def make_editor(self, col_style=wx.LIST_FORMAT_LEFT): editor = wx.PreTextCtrl() style =wx.TE_PROCESS_ENTER|wx.TE_PROCESS_TAB|wx.TE_RICH2 style |= {wx.LIST_FORMAT_LEFT: wx.TE_LEFT, wx.LIST_FORMAT_RIGHT: wx.TE_RIGHT, wx.LIST_FORMAT_CENTRE : wx.TE_CENTRE}[col_style] editor.Create(self, -1, style=style) editor.SetBackgro... | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py |
def OpenEditor(self, col, row): ''' Opens an editor at the current position. ''' | 27ed367cb23b71ba64c7176044f4b8dc33e753dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/27ed367cb23b71ba64c7176044f4b8dc33e753dd/listctrl.py | ||
w = self.text.GetSize().width + self.text.GetPosition().x | w = self.text.GetSize().width + self.text.GetPosition().x + 2 | def __init__(self, parent, log): wx.Panel.__init__(self, parent, -1) self.log = log self.count = 0 | d1f46a1c4d50ed5f29bc5a146968e776ae4cb00f /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d1f46a1c4d50ed5f29bc5a146968e776ae4cb00f/SpinButton.py |
self.spin = wx.SpinButton(self, -1, (w + 6, 50), (h/2, h), wx.SP_VERTICAL) | self.spin = wx.SpinButton(self, -1, (w, 50), (h*2/3, h), wx.SP_VERTICAL) | def __init__(self, parent, log): wx.Panel.__init__(self, parent, -1) self.log = log self.count = 0 | d1f46a1c4d50ed5f29bc5a146968e776ae4cb00f /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/d1f46a1c4d50ed5f29bc5a146968e776ae4cb00f/SpinButton.py |
dc.DrawLineXY(*coords) | dc.DrawLine(*coords) | def DrawSavedLines(self, dc): dc.BeginDrawing() dc.SetPen(wx.Pen(wx.BLUE, 3)) for line in self.lines: for coords in line: dc.DrawLineXY(*coords) dc.EndDrawing() | 0dfb2393ddd200cb698351dbd44590898590d8c1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0dfb2393ddd200cb698351dbd44590898590d8c1/CustomDragAndDrop.py |
coords = ((self.x, self.y), event.GetPosition()) | coords = ((self.x, self.y), event.GetPositionTuple()) | def OnMotion(self, event): if event.Dragging() and not self.mode == "Drag": dc = wx.ClientDC(self) dc.BeginDrawing() dc.SetPen(wx.Pen(wx.BLUE, 3)) coords = ((self.x, self.y), event.GetPosition()) self.curLine.append(coords) dc.DrawLineXY(*coords) self.x, self.y = event.GetPositionTuple() dc.EndDrawing() | 0dfb2393ddd200cb698351dbd44590898590d8c1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0dfb2393ddd200cb698351dbd44590898590d8c1/CustomDragAndDrop.py |
dc.DrawLineXY(*coords) | dc.DrawLine(*coords) | def OnMotion(self, event): if event.Dragging() and not self.mode == "Drag": dc = wx.ClientDC(self) dc.BeginDrawing() dc.SetPen(wx.Pen(wx.BLUE, 3)) coords = ((self.x, self.y), event.GetPosition()) self.curLine.append(coords) dc.DrawLineXY(*coords) self.x, self.y = event.GetPositionTuple() dc.EndDrawing() | 0dfb2393ddd200cb698351dbd44590898590d8c1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0dfb2393ddd200cb698351dbd44590898590d8c1/CustomDragAndDrop.py |
lines = wx.InputStream(cPickle.loads(linesdata)) | lines = cPickle.loads(linesdata) | def OnData(self, x, y, d): self.log.WriteText("OnData: %d, %d, %d\n" % (x, y, d)) | 0dfb2393ddd200cb698351dbd44590898590d8c1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0dfb2393ddd200cb698351dbd44590898590d8c1/CustomDragAndDrop.py |
dc.DrawLineXY(*coords) | dc.DrawLine(*coords) | def DrawSavedLines(self, dc): dc.BeginDrawing() dc.SetPen(wx.Pen(wx.RED, 3)) | 0dfb2393ddd200cb698351dbd44590898590d8c1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12725/0dfb2393ddd200cb698351dbd44590898590d8c1/CustomDragAndDrop.py |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.