def clip(self): # box = self.viewbox() xlim, ylim = self.plotter.viewbox xmin, xmax = xlim ymin, ymax = ylim box = [[xmin, ymin], [xmax, ymin], [xmax, ymax], [xmin, ymax]] return intersection_line_box_xy(self.line, box)
def clip(self) -> List[Point]: """Compute the clipping points of the line for the current view box.""" xlim, ylim = self.plotter.viewbox xmin, xmax = xlim ymin, ymax = ylim box = [[xmin, ymin], [xmax, ymin], [xmax, ymax], [xmin, ymax]] return intersection_line_box_xy(self.line, box)
def clip(self): box = self.viewbox() return intersection_line_box_xy(self.line, box)