I fixed the bug myself. The problem was actually not visible in the code I've been providing.
I have a method which changes self.image
before any drawing is made. Thus the image which I assign to the ClientDC in the class body is not the same image than self.image
when I begin to draw. Adding self.dc = wx.ClientDC(self.image)
in the image setter solved my problem.
I don't understand why this code worked when being executed on MS Windows. This should not have never worked in the first place.