Class CanvasPanel.CurveCreator

    • Constructor Detail

      • CurveCreator

        public CurveCreator()
        Constructs a CurveCreator.
    • Method Detail

      • mouseClicked

        public void mouseClicked​(MouseEvent e)
        Invoked when the mouse button has been clicked (pressed and released) on a component. This method is unimplemented (i. e. nothing currently happens).
        Specified by:
        mouseClicked in interface MouseListener
        Parameters:
        e - The mouse event.
      • mouseDragged

        public void mouseDragged​(MouseEvent e)
        Invoked when a mouse button is pressed on a component and then dragged. This will add more Points to the curve, and with each point, it will repaint the CanvasPanel.
        Specified by:
        mouseDragged in interface MouseMotionListener
        Parameters:
        e - The mouse event.
      • mouseEntered

        public void mouseEntered​(MouseEvent e)
        Invoked when the mouse enters a component. This method is unimplemented (i. e. nothing currently happens).
        Specified by:
        mouseEntered in interface MouseListener
        Parameters:
        e - The mouse event.
      • mouseExited

        public void mouseExited​(MouseEvent e)
        Invoked when the mouse exits a component. This method is unimplemented (i. e. nothing currently happens).
        Specified by:
        mouseExited in interface MouseListener
        Parameters:
        e - The mouse event.
      • mouseMoved

        public void mouseMoved​(MouseEvent e)
        Invoked when the mouse button has been moved on a component (with no buttons no down). This method is unimplemented (i. e. nothing currently happens).
        Specified by:
        mouseMoved in interface MouseMotionListener
      • mousePressed

        public void mousePressed​(MouseEvent e)
        Invoked when a mouse button has been pressed on a component. This will start a new curve, and makes sure the current color is saved as the color of the curve.
        Specified by:
        mousePressed in interface MouseListener
        Parameters:
        e - The mouse event.
      • mouseReleased

        public void mouseReleased​(MouseEvent e)
        Invoked when a mouse button has been released on a component. This method is unimplemented (i. e. nothing currently happens).
        Specified by:
        mouseReleased in interface MouseListener
        Parameters:
        e - The mouse event.