Fibonacci Extensions are based on three chosen points on chart: the first two points determine the price move while the third point is the end of retracement against that move. Extension lines using Fibonacci ratios are then drawn based on the price moves. Fibonacci Extensions are used to estimate how far the price could move.

Hierarchy

Constructors

Methods

  • Gets the current drawing tool position in axis values.

    Returns Point[]

    • Array containing all control point positions.
  • Unsubscribes from the DrawingToolMoved event.

    Returns void

  • Unsubscribes from the PointerDown event.

    Returns void

  • Unsubscribes from the PointerEnter event.

    Returns void

  • Unsubscribes from the PointerLeave event.

    Returns void

  • Unsubscribes from the PointerUp event.

    Returns void

  • Event that triggers when drawing tool's position has been changed either by dragging it or in code.

    Parameters

    • handler: Handler<DrawingToolMovedEvent>

      Event handler containing X- and Y-position parameters for each of the control points.

    Returns void

  • Event that triggers when pointer is pressed down on top of the drawing tool.

    Parameters

    • handler: Handler<PointerDownEvent>

      Event handler containing the following parameters:

      -'xPosition' and 'yPosition' parameters return the current cursor position in axis values.

      -'xPositionClient' and 'yPositionClient' return the current cursor position in client coordinates (zero equals top-left corner).

      -'drawingTool' gets the drawing tool instance.

      -'isControlPoint' tells if the event was triggered by one of the drawing tool's control points.

      -'button' indicates the pressed mouse button.

    Returns void

  • Event that triggers when pointer is moved onto the drawing tool.

    Parameters

    • handler: Handler<PointerEnterEvent>

      Event handler containing the following parameters:

      -'xPosition' and 'yPosition' parameters return the current cursor position in axis values.

      -'xPositionClient' and 'yPositionClient' return the current cursor position in client coordinates (zero equals top-left corner).

      -'drawingTool' gets the drawing tool instance.

      -'isControlPoint' tells if the event was triggered by one of the drawing tool's control points.

    Returns void

  • Event that triggers when pointer is moved away from the drawing tool.

    Parameters

    • handler: Handler<PointerLeaveEvent>

      Event handler containing the following parameters:

      -'xPosition' and 'yPosition' parameters return the current cursor position in axis values.

      -'xPositionClient' and 'yPositionClient' return the current cursor position in client coordinates (zero equals top-left corner).

      -'drawingTool' gets the drawing tool instance.

      -'isControlPoint' tells if the event was triggered by one of the drawing tool's control points.

    Returns void

  • Event that triggers when pointer is released on top of the drawing tool.

    Parameters

    • handler: Handler<PointerUpEvent>

      Event handler containing the following parameters:

      -'xPosition' and 'yPosition' parameters return the current cursor position in axis values.

      -'xPositionClient' and 'yPositionClient' return the current cursor position in client coordinates (zero equals top-left corner).

      -'drawingTool' gets the drawing tool instance.

      -'isControlPoint' tells if the event was triggered by one of the drawing tool's control points.

      -'button' indicates the released mouse button.

    Returns void

  • Sets whether Fibonacci level lines extend to the edge of the chart.

    Parameters

    • extendLines: boolean

      Set true to extend the lines.

    Returns void

  • Sets whether areas between the Fibonacci levels are colored or not.

    Parameters

    • fillEnabled: boolean

      Set true to enable the fill.

    Returns void

  • Sets the color of the Fibonacci Extension lines.

    Parameters

    • newColor: string

      New line color as string, should be in HEX format e.g. #FFFFFF.

    Returns void

  • Sets the width of the Fibonacci Extension lines.

    Parameters

    • newWidth: number

      New line width.

    Returns void

  • Sets whether the drawing tool should automatically snap to OLHC-data points.

    Parameters

    • isMagnetic: boolean

      Set true to enable snapping to data points.

    Returns void

  • Shows the price values of each Fibonacci level label.

    Parameters

    • showPrices: boolean

      Set true to show the price values.

    Returns void

  • Updates the drawing tool based on the control points' locations.

    Parameters

    • startX: number

      Starting point X location.

    • startY: number

      Starting point Y location.

    • midX: number

      Middle point X location.

    • midY: number

      Middle point Y location.

    • endX: number

      End point X location.

    • endY: number

      End point Y location.

    Returns void