Chances are this is a dumb question, but hey, I don't have anywhere else to go. I wrote a basic hangingman game on my pc desktop using a paint event to draw the hangman. Unfortunately, this code doesn't seem to run the same on my new apple computer. It comes back with
<'Hangman has no attribute 'dc'>.
Here's setting up the paint event in a panel:
def on_paint(event):
self.dc == wx.PaintDC(event.GetEventObject())
self.dc.SetPen(wx.Pen("BLACK", 4))
self.hangingman.Bind(wx.EVT_PAINT, on_paint)
And here's trying to draw something into the event upon the start of a new game:
self.dc.Clear()
self.dc.SetPen(wx.Pen("BLACK", 4))
self.dc.DrawLine(200, 350, 500, 350)
self.dc.DrawLine(300, 350, 300, 50)
self.dc.DrawLine(300, 50, 400, 50)
self.dc.DrawLine(400, 50, 400, 125)
Please let me know what I'm doing wrong here.