From c99701e30b23adc2f1e8f45cb00eeecc96cfd462 Mon Sep 17 00:00:00 2001 From: Dominik Gresch Date: Mon, 9 Jan 2023 18:16:00 +0100 Subject: [PATCH] Use integer division in DockSplitter.draw --- pyface/dock/dock_sizer.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyface/dock/dock_sizer.py b/pyface/dock/dock_sizer.py index 5c43ed007..48f78e0ad 100644 --- a/pyface/dock/dock_sizer.py +++ b/pyface/dock/dock_sizer.py @@ -1314,7 +1314,7 @@ def draw(self, dc): # should be a darkish color in the users color scheme pen = wx.Pen(wx.SystemSettings.GetColour(wx.SYS_COLOUR_BTNSHADOW)) dc.SetPen(pen) - dc.DrawLine(x + idx + 1, y + dy / 2, x + dx - 2, y + dy / 2) + dc.DrawLine(x + idx + 1, y + dy // 2, x + dx - 2, y + dy // 2) iy = y + 2 ix = x @@ -1327,7 +1327,7 @@ def draw(self, dc): # should be a darkish color in the users color scheme pen = wx.Pen(wx.SystemSettings.GetColour(wx.SYS_COLOUR_BTNSHADOW)) dc.SetPen(pen) - dc.DrawLine(x + dx / 2, y + idy + 1, x + dx / 2, y + dy - 2) + dc.DrawLine(x + dx // 2, y + idy + 1, x + dx // 2, y + dy - 2) iy = y ix = x + 2