Klasse RowCanvas<R extends Row<?,?,?>>

java.lang.Object
javafx.scene.Node
javafx.scene.canvas.Canvas
impl.com.flexganttfx.skin.graphics.RowCanvas<R>
Alle implementierten Schnittstellen:
Styleable, EventTarget

public final class RowCanvas<R extends Row<?,?,?>> extends Canvas
Canvas that renders the activities of a single row. It manages per-row layout state, selection visuals, and redraw requests for the row content.
  • Eigenschaftsdetails

  • Konstruktordetails

    • RowCanvas

      public RowCanvas(GraphicsBase<R> graphics)
      Constructs a new row canvas for the given graphics control.
      Parameter:
      graphics - the graphics control
  • Methodendetails

    • requestRedraw

      public void requestRedraw(String reason, Instant oldTime)
      Requests a redraw for the given reason.
      Parameter:
      reason - the redraw reason
      oldTime - the previous time
    • getGraphics

      public GraphicsBase<R> getGraphics()
      Returns the graphics control.
      Gibt zurück:
      the graphics control
    • rowProperty

      public ObjectProperty<R> rowProperty()
      The row property.
      Gibt zurück:
      the row property
      Siehe auch:
    • setRow

      public void setRow(R row)
      Legt den Wert der row-Eigenschaft fest.
      Eigenschaftsbeschreibung:
      The row property.
      Parameter:
      row - Wert für die Eigenschaft row
      Siehe auch:
    • getRow

      public R getRow()
      Ruft den Wert der row-Eigenschaft ab.
      Eigenschaftsbeschreibung:
      The row property.
      Gibt zurück:
      Wert der Eigenschaft row
      Siehe auch:
    • getTimelineModel

      public TimelineModel<?> getTimelineModel()
      Returns the timeline model.
      Gibt zurück:
      the timeline model
    • isResizable

      public boolean isResizable()
      Returns whether this canvas is resizable.
      Setzt außer Kraft:
      isResizable in Klasse Node
      Gibt zurück:
      true if this canvas is resizable
    • prefHeight

      public double prefHeight(double width)
      Returns the preferred height for the given width.
      Setzt außer Kraft:
      prefHeight in Klasse Node
      Parameter:
      width - the width
      Gibt zurück:
      the preferred height
    • prefWidth

      public double prefWidth(double height)
      Returns the preferred width for the given height.
      Setzt außer Kraft:
      prefWidth in Klasse Node
      Parameter:
      height - the height
      Gibt zurück:
      the preferred width
    • isDirty

      public boolean isDirty()
      Returns whether a redraw is pending.
      Gibt zurück:
      true if a redraw is pending
    • requestRedraw

      public void requestRedraw(String reason)
      Requests a redraw for the given reason.
      Parameter:
      reason - the redraw reason
    • draw

      public void draw()
      Draws the canvas contents.
    • getAllActivityBounds

      public List<ActivityBounds> getAllActivityBounds()
      Returns all activity bounds.
      Gibt zurück:
      all activity bounds
    • getAllActivityBounds

      public List<ActivityBounds> getAllActivityBounds(double x, double y)
      Returns all activity bounds at the given coordinates.
      Parameter:
      x - the x coordinate
      y - the y coordinate
      Gibt zurück:
      the activity bounds at the given coordinates
    • getActivityBounds

      public ActivityBounds getActivityBounds(double x, double y)
      Returns the activity bounds at the given coordinates.
      Parameter:
      x - the x coordinate
      y - the y coordinate
      Gibt zurück:
      the activity bounds at the given coordinates
    • getActivityBounds

      public ActivityBounds getActivityBounds(ActivityRef<?> activityRef)
      Returns the activity bounds for the given activity reference.
      Parameter:
      activityRef - the activity reference
      Gibt zurück:
      the activity bounds for the activity reference
    • getActivityBounds

      public List<ActivityBounds> getActivityBounds(double x, double y, double w, double h)
      Returns the activity bounds within the given area.
      Parameter:
      x - the x coordinate
      y - the y coordinate
      w - the width
      h - the height
      Gibt zurück:
      the activity bounds within the given area
    • getLayoutAt

      public Layout getLayoutAt(double y)
      Returns the layout at the given y coordinate.
      Parameter:
      y - the y coordinate
      Gibt zurück:
      the layout at the given y coordinate
    • getLayoutBoundsAt

      public Rectangle2D getLayoutBoundsAt(double y)
      Returns the layout bounds at the given y coordinate.
      Parameter:
      y - the y coordinate
      Gibt zurück:
      the layout bounds at the given y coordinate
    • snapToPixelProperty

      public BooleanProperty snapToPixelProperty()
      The snap to pixel property.
      Gibt zurück:
      the snap to pixel property
      Siehe auch:
    • setSnapToPixel

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

      public boolean isSnapToPixel()
      Ruft den Wert der snapToPixel-Eigenschaft ab.
      Eigenschaftsbeschreibung:
      The snap to pixel property.
      Gibt zurück:
      Wert der Eigenschaft snapToPixel
      Siehe auch:
    • snapSpaceX

      public double snapSpaceX(double value)
      If this canvas' 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 canvas' 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 canvas' 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 canvas' 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 canvas' 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 canvas' 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