import javax.swing.JMenuItem;
import javax.swing.JPanel;
import javax.swing.JPopupMenu;
-import javax.swing.SwingUtilities;
import javax.swing.ToolTipManager;
/**
// todo res calculation should be a method on AlignViewport
int xCords = Math.max(0, evt.getX()); // prevent negative X coordinates
+ ViewportRanges ranges = av.getRanges();
int res = (xCords / av.getCharWidth())
- + av.getRanges().getStartRes();
-
+ + ranges.getStartRes();
+ res = Math.min(res, ranges.getEndRes());
if (av.hasHiddenColumns())
{
res = av.getAlignment().getHiddenColumns()
.visibleToAbsoluteColumn(res);
}
- res = Math.min(res, av.getRanges().getEndRes());
res = Math.max(0, res);
if (!stretchingGroup)