Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/mcs/class
diff options
context:
space:
mode:
authorKarl <contact@scowencomputers.co.nz>2020-01-18 07:11:13 +0300
committerKarl <contact@scowencomputers.co.nz>2020-01-18 07:11:13 +0300
commitd826bebd54552d0f7e1948a8e591b988cce6edb1 (patch)
tree359643084ca459a4dcb6e6ad0117862b2e617749 /mcs/class
parentf39d6526422c3ab4994daa067ff6fde98d774ae0 (diff)
Calculate DPI before Recalculate.
Diffstat (limited to 'mcs/class')
-rw-r--r--mcs/class/System.Windows.Forms/System.Windows.Forms/TextControl.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/mcs/class/System.Windows.Forms/System.Windows.Forms/TextControl.cs b/mcs/class/System.Windows.Forms/System.Windows.Forms/TextControl.cs
index d6eae37f5b4..cf65c990cbf 100644
--- a/mcs/class/System.Windows.Forms/System.Windows.Forms/TextControl.cs
+++ b/mcs/class/System.Windows.Forms/System.Windows.Forms/TextControl.cs
@@ -3908,8 +3908,8 @@ namespace System.Windows.Forms {
private void owner_HandleCreated(object sender, EventArgs e) {
using (var graphics = owner.CreateGraphics()) {
- RecalculateDocument(graphics);
dpi = (graphics.DpiX + graphics.DpiY) / 2;
+ RecalculateDocument(graphics);
}
AlignCaret();
}