diff --git a/ScreenCaptureLib/Forms/RectangleAnnotate.cs b/ScreenCaptureLib/Forms/RectangleAnnotate.cs index d87654458..f8e07a1ad 100644 --- a/ScreenCaptureLib/Forms/RectangleAnnotate.cs +++ b/ScreenCaptureLib/Forms/RectangleAnnotate.cs @@ -388,11 +388,19 @@ private void DrawTips(Graphics g) Size textSize = g.MeasureString(tipText, tipFont).ToSize(); int rectWidth = textSize.Width + padding * 2; int rectHeight = textSize.Height + padding * 2; - Rectangle textRectangle = new Rectangle(ScreenRectangle0Based.Width / 2 - rectWidth / 2, offset, rectWidth, rectHeight); + Rectangle primaryScreenBounds = Screen.PrimaryScreen.Bounds; + foreach(Screen screen in Screen.AllScreens) + { + if(screen.Bounds.Left < 0) + { + primaryScreenBounds.X -= screen.Bounds.Left; + } + } + Rectangle textRectangle = new Rectangle(primaryScreenBounds.X + (primaryScreenBounds.Width / 2) - (rectWidth / 2), offset, rectWidth, rectHeight); if (textRectangle.RectangleOffset(10).Contains(CurrentMousePosition0Based)) { - textRectangle.Y = ScreenRectangle0Based.Height - rectHeight - offset; + textRectangle.Y = primaryScreenBounds.Height - rectHeight - offset - offset; } using (Brush brush = new SolidBrush(Color.FromArgb(175, Color.White))) @@ -446,4 +454,4 @@ private void DrawDot(Graphics g, Point pos, int size, Color color, bool border = } } } -} \ No newline at end of file +}