# HG changeset patch # User Andrey Skvortsov # Date 1489162663 -10800 # Node ID 9a91faac4d954c9f3d44e9e1e2ff75f9bd6f7630 # Parent 81f6781f7fec8dadae6bb2726362c073e8d7edf3# Parent ccf2bcf66c702c0e78b7e2a5a0ad65710ac4a078 merge Beremiz launcher support Closes #13 diff -r 81f6781f7fec -r 9a91faac4d95 editors/Viewer.py --- a/editors/Viewer.py Fri Mar 10 19:12:43 2017 +0300 +++ b/editors/Viewer.py Fri Mar 10 19:17:43 2017 +0300 @@ -3016,7 +3016,9 @@ _("Please enter comment text"), comment.GetContent(), wx.OK|wx.CANCEL|wx.TE_MULTILINE) - dialog.SetClientSize(wx.Size(400, 200)) + width, height = comment.GetSize() + dialogSize = wx.Size(max(width + 30, 400), max(height + 60, 200)) + dialog.SetClientSize(dialogSize) if dialog.ShowModal() == wx.ID_OK: value = dialog.GetValue() rect = comment.GetRedrawRect(1, 1)