Interface Shape

    • Method Detail

      • asDataObject

        ShapeData asDataObject()
        Returns a ShapeData corresponding to the handled object.
        Specified by:
        asDataObject in interface RemoteObject
        Returns:
        See above.
      • getC

        int getC()
        Gets the channel.
        Returns:
        the channel. -1 if the shape applies to all channels of the image.
      • setC

        void setC​(int c)
        Sets the channel.
        Parameters:
        c - the channel. Pass -1 to remove z value, i.e. shape applies to all channels of the image.
      • getZ

        int getZ()
        Gets the z-section.
        Returns:
        the z-section. -1 if the shape applies to all z-sections of the image.
      • setZ

        void setZ​(int z)
        Sets the z-section.
        Parameters:
        z - the z-section. Pass -1 to remove z value, i.e. shape applies to all z-sections of the image.
      • getT

        int getT()
        Sets the time-point.
        Returns:
        the time-point. -1 if the shape applies to all time-points of the image.
      • setT

        void setT​(int t)
        Sets the time-point.
        Parameters:
        t - the time-point. Pass -1 to remove t value, i.e. shape applies to all time-points of the image.
      • setCZT

        default void setCZT​(int c,
                            int z,
                            int t)
        Sets the channel, z-section and time-point at once.
        Parameters:
        c - the channel. Pass -1 to remove z value, i.e. shape applies to all channels of the image.
        z - the z-section. Pass -1 to remove z value, i.e. shape applies to all z-sections of the image.
        t - the time-point. Pass -1 to remove t value, i.e. shape applies to all time-points of the image.
      • getCZT

        default java.lang.String getCZT()
        Returns the C,Z,T positions as a comma-delimited String.
        Returns:
        See above.
      • getFontSize

        double getFontSize()
        Gets ShapeData font size.
        Returns:
        The font size (in typography points)
      • setFontSize

        void setFontSize​(double value)
        Sets ShapeData font size.
        Parameters:
        value - The font size (in typography points)
      • getStroke

        java.awt.Color getStroke()
        Gets the ShapeData stroke color.
        Returns:
        The stroke color
      • setStroke

        void setStroke​(java.awt.Color strokeColour)
        Sets ShapeData stroke color.
        Parameters:
        strokeColour - The stroke color
      • getFill

        java.awt.Color getFill()
        Gets ShapeData fill color.
        Returns:
        The fill color
      • setFill

        void setFill​(java.awt.Color fillColour)
        Sets the ShapeData fill color.
        Parameters:
        fillColour - The fill color
      • getText

        java.lang.String getText()
        Gets the text on the ShapeData.
        Returns:
        the text
      • setText

        void setText​(java.lang.String text)
        Sets the text on the ShapeData.
        Parameters:
        text - the text
      • toAWTShape

        java.awt.Shape toAWTShape()
        Converts the shape to an Shape.
        Returns:
        The converted AWT Shape.
      • setTransform

        void setTransform​(double a00,
                          double a10,
                          double a01,
                          double a11,
                          double a02,
                          double a12)
        Sets the transform to the matrix specified by the 6 double precision values.
        Parameters:
        a00 - the X coordinate scaling element of the 3x3 matrix
        a10 - the Y coordinate shearing element of the 3x3 matrix
        a01 - the X coordinate shearing element of the 3x3 matrix
        a11 - the Y coordinate scaling element of the 3x3 matrix
        a02 - the X coordinate translation element of the 3x3 matrix
        a12 - the Y coordinate translation element of the 3x3 matrix
      • setTransform

        default void setTransform​(java.awt.geom.AffineTransform transform)
        Sets the transform from a AffineTransform.
        Parameters:
        transform - A Java AffineTransform.
      • toAWTTransform

        java.awt.geom.AffineTransform toAWTTransform()
        Converts AffineTransform to AffineTransform.
        Returns:
        The converted affine transform.
      • createTransformedAWTShape

        default java.awt.Shape createTransformedAWTShape()
        Returns a new Shape defined by the geometry of the specified Shape after it has been transformed by the transform.
        Returns:
        A new transformed Shape.
      • getBoundingBox

        Rectangle getBoundingBox()
        Returns a new Rectangle corresponding to the bounding box of the shape, once the related AffineTransform has been applied.
        Returns:
        The bounding box.
      • toImageJ

        Roi toImageJ()
        Converts shape to ImageJ ROI.
        Returns:
        An ImageJ ROI.