def point_to_column(p: QPointF, columns: Sequence[int]) -> int | None:
        """
        Given a point `p` and list of column offsets `columns`, return the index of column point p or None if the point
        is not contained.
        """
        x = p.x()
        for i in range(len(columns) - 1):
            if columns[i] <= x < columns[i + 1]:
                return i
        return None

        Given a point `p` and list of column offsets `columns`, return the index of column point p or None if the point
        is not contained.
        
angrmanagement/ui/views/hex_view.py