mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-104338 folding area clickable area misalignment
This commit is contained in:
+3
-1
@@ -1425,8 +1425,10 @@ class EditorGutterComponentImpl extends EditorGutterComponentEx implements Mouse
|
||||
Collection<DisplayedFoldingAnchor> displayedAnchors = myAnchorsDisplayStrategy.getAnchorsToDisplay(neighbourhoodStartOffset,
|
||||
neighbourhoodEndOffset,
|
||||
null);
|
||||
x = convertX(x);
|
||||
for (DisplayedFoldingAnchor anchor : displayedAnchors) {
|
||||
if (rectangleByFoldOffset(anchor.visualLine, anchorWidth, anchorX).contains(convertX(x), y)) return anchor.foldRegion;
|
||||
Rectangle r = rectangleByFoldOffset(anchor.visualLine, anchorWidth, anchorX);
|
||||
if (r.x < x && x <= (r.x + r.width) && r.y < y && y <= (r.y + r.height)) return anchor.foldRegion;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user