Search Issue Tracker
Won't Fix
Votes
0
Found in
2020.1.0a5
2020.2
2020.2.1f1
2021.1
2021.2
Issue ID
1310730
Regression
Yes
Popup window will be drawn at a incorrect position when using PopupWindow.Show()
How to reproduce:
1. Open the attached project (case_1310730_PopupPosition)
2. Click Tools > Popup 00
3. Observe where the pop up is drawn
4. Click Popup MyWindow 00
5. Observe where the Popup is drawn
Expected result: Popup 00 is drawn at the top left corner of the Unity window. Popup MyWindow 00 is drawn at the top left corner of MyWindow window.
Actual result: Popup 00 is drawn below the top left corner. Popup MyWindow 00 is drawn either completely outside of MyWindow or below the top left corner of MyWindow.
Reproducible with: 2020.1.0a5, 2020.2.4f1, 2021.1.0b5, 2021.2.0a4
Not reproducible with: 2018.4.30f1, 2019.4.19f1, 2020.1.0a4
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- D3D11 swapchain error pop-up appears and the Editor shuts down when Generating Lighting with Probe Volumes present
- Articulation Bodies spawn at the same point on a Spline when entering the Play mode
- [HDRP] Mip Map Debugging View turns White if there are Directional Lights in the Scene
- RenderDoc Capture Frame can't be completed after Particle System is simulated
- Editor crashes when attempting to connect the client machine to the host machine
Resolution Note (2021.2.X):
Restoring this legacy behavior has caused other regressions. The correct solution is either to only call PopupWindow.Show() inside OnGUI() calls as shown in the documentation: https://docs.unity3d.com/ScriptReference/PopupWindow.html
Or to convert the screen space coordinate you desire into the current GUI space using GUIUtility.ScreenToGUIPoint()