Klasse RendererBase

java.lang.Object
com.flexganttfx.view.graphics.renderer.RendererBase
Bekannte direkte Unterklassen:
LinkRenderer, Renderer, SystemLayer

public abstract class RendererBase extends Object
The base class of all renderers used by FlexGanttFX.
  • Eigenschaftsübersicht

    Eigenschaften
    Typ
    Eigenschaft
    Beschreibung
     
     
     
  • Konstruktorübersicht

    Konstruktoren
    Konstruktor
    Beschreibung
    RendererBase(GraphicsBase<?> graphics, String name)
    Constructs a new renderer.
  • Methodenübersicht

    Modifizierer und Typ
    Methode
    Beschreibung
     
    protected final void
    Disables automatic redrawing of the graphics area when one of the observed properties changes.
     
    protected final void
    Enabled automatic redrawing of the graphics area when one of the observed properties changes.
    final double
    Ruft den Wert der alpha-Eigenschaft ab.
    final GraphicsBase<?>
     
    protected final double
    getLocation(Instant time, Canvas canvas)
    Calculates the x coordinate for the given time.
    final String
     
    protected final Instant
    getTimeAt(double location)
    Calculates the time at the given x coordinate.
    final boolean
    Ruft den Wert der enabled-Eigenschaft ab.
    final boolean
    Ruft den Wert der snapToPixel-Eigenschaft ab.
    protected void
    Registers the given observable as something that requires a redraw of the graphics area.
    final void
    setAlpha(double alpha)
    Legt den Wert der alpha-Eigenschaft fest.
    final void
    setEnabled(boolean enabled)
    Legt den Wert der enabled-Eigenschaft fest.
    final void
    setSnapToPixel(boolean snap)
    Legt den Wert der snapToPixel-Eigenschaft fest.
    double
    snapPositionX(double value)
    If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the horizontal direction, else returns the same value.
    double
    snapPositionY(double value)
    If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the vertical direction, else returns the same value.
    double
    snapSizeX(double value)
    If this renderer's snapToPixel property is true, returns a value ceiled to the nearest pixel in the horizontal direction, else returns the same value.
    double
    snapSizeY(double value)
    If this renderer's snapToPixel property is true, returns a value ceiled to the nearest pixel in the vertical direction, else returns the same value.
    double
    snapSpaceX(double value)
    If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the horizontal direction, else returns the same value.
    double
    snapSpaceY(double value)
    If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the vertical direction, else returns the same value.
     

    Von Klasse geerbte Methoden java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Eigenschaftsdetails

  • Konstruktordetails

    • RendererBase

      public RendererBase(GraphicsBase<?> graphics, String name)
      Constructs a new renderer.
      Parameter:
      graphics - the graphics control where the renderer will be used
      name - the name of the renderer (useful for tooling)
  • Methodendetails

    • snapSpaceX

      public double snapSpaceX(double value)
      If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the horizontal direction, else returns the same value.
      Parameter:
      value - the space value to be snapped
      Gibt zurück:
      value rounded to nearest pixel
    • snapSpaceY

      public double snapSpaceY(double value)
      If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the vertical direction, else returns the same value.
      Parameter:
      value - the space value to be snapped
      Gibt zurück:
      value rounded to nearest pixel
    • snapSizeX

      public double snapSizeX(double value)
      If this renderer's snapToPixel property is true, returns a value ceiled to the nearest pixel in the horizontal direction, else returns the same value.
      Parameter:
      value - the size value to be snapped
      Gibt zurück:
      value ceiled to nearest pixel
    • snapSizeY

      public double snapSizeY(double value)
      If this renderer's snapToPixel property is true, returns a value ceiled to the nearest pixel in the vertical direction, else returns the same value.
      Parameter:
      value - the size value to be snapped
      Gibt zurück:
      value ceiled to nearest pixel
    • snapPositionX

      public double snapPositionX(double value)
      If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the horizontal direction, else returns the same value.
      Parameter:
      value - the position value to be snapped
      Gibt zurück:
      value rounded to nearest pixel
    • snapPositionY

      public double snapPositionY(double value)
      If this renderer's snapToPixel property is true, returns a value rounded to the nearest pixel in the vertical direction, else returns the same value.
      Parameter:
      value - the position value to be snapped
      Gibt zurück:
      value rounded to nearest pixel
    • disableRedrawAfterPropertyChange

      protected final void disableRedrawAfterPropertyChange()
      Disables automatic redrawing of the graphics area when one of the observed properties changes. Useful for not going into infinite loops.
    • enableRedrawAfterPropertyChange

      protected final void enableRedrawAfterPropertyChange()
      Enabled automatic redrawing of the graphics area when one of the observed properties changes. Useful for not going into infinite loops.
    • redrawObservable

      protected void redrawObservable(Observable observable)
      Registers the given observable as something that requires a redraw of the graphics area. E.g.: the stroke color has changed.
      Parameter:
      observable - the observable to monitor for changes
    • getName

      public final String getName()
    • getGraphics

      public final GraphicsBase<?> getGraphics()
    • getLocation

      protected final double getLocation(Instant time, Canvas canvas)
      Calculates the x coordinate for the given time. This method only returns valid results when the renderer is used in a layout with horizontal orientation. It will not work in AgendaLayout.
      Parameter:
      time - the time for which to calculate the x coordinate
      Gibt zurück:
      the location of the given time point
      Seit:
      1.0
      Siehe auch:
    • getTimeAt

      protected final Instant getTimeAt(double location)
      Calculates the time at the given x coordinate. This method only returns valid results when the renderer is used in a layout with horizontal orientation. It will not work in AgendaLayout.
      Parameter:
      location - the location for which to return the time
      Gibt zurück:
      the time at the given x coordinate
      Seit:
      1.0
      Siehe auch:
    • enabledProperty

      public final BooleanProperty enabledProperty()
      Gibt zurück:
      die Eigenschaft enabled
      Siehe auch:
    • isEnabled

      public final boolean isEnabled()
      Ruft den Wert der enabled-Eigenschaft ab.
      Eigenschaftsbeschreibung:
      Gibt zurück:
      Wert der Eigenschaft enabled
      Siehe auch:
    • setEnabled

      public final void setEnabled(boolean enabled)
      Legt den Wert der enabled-Eigenschaft fest.
      Eigenschaftsbeschreibung:
      Parameter:
      enabled - Wert für die Eigenschaft enabled
      Siehe auch:
    • snapToPixelProperty

      public final BooleanProperty snapToPixelProperty()
      Gibt zurück:
      die Eigenschaft snapToPixel
      Siehe auch:
    • setSnapToPixel

      public final void setSnapToPixel(boolean snap)
      Legt den Wert der snapToPixel-Eigenschaft fest.
      Eigenschaftsbeschreibung:
      Parameter:
      snap - Wert für die Eigenschaft snapToPixel
      Siehe auch:
    • isSnapToPixel

      public final boolean isSnapToPixel()
      Ruft den Wert der snapToPixel-Eigenschaft ab.
      Eigenschaftsbeschreibung:
      Gibt zurück:
      Wert der Eigenschaft snapToPixel
      Siehe auch:
    • alphaProperty

      public final DoubleProperty alphaProperty()
      Gibt zurück:
      die Eigenschaft alpha
      Siehe auch:
    • setAlpha

      public final void setAlpha(double alpha)
      Legt den Wert der alpha-Eigenschaft fest.
      Eigenschaftsbeschreibung:
      Parameter:
      alpha - Wert für die Eigenschaft alpha
      Siehe auch:
    • getAlpha

      public final double getAlpha()
      Ruft den Wert der alpha-Eigenschaft ab.
      Eigenschaftsbeschreibung:
      Gibt zurück:
      Wert der Eigenschaft alpha
      Siehe auch: