Class InternalCanvas


  • public class InternalCanvas
    extends java.lang.Object

    Static class that handles all the internal stuff in the package; Cleans up documentation for Canvas

    Also yes everything is static under the hood sue me

    An instance of the globally accessible canvas object can simply be accessed with canvas

    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.util.List<Animation> animations
      the list of animations that are currently running
      static java.lang.Object animationSync
      Sync with animations: Notifies on animation finish
      static Canvas canvas  
      static java.lang.Object drawableSync
      Sync with drawables: Use when modifying a drawable
      static ElementContainer elements
      the elements that are currently on the canvas
      static int frame
      The current frame
      static java.lang.Object frameSync
      Sync with frame: Notifies on end of frame
      static boolean initialized
      Whether this has been initialized yet
      static java.util.HashSet<java.lang.Integer> keysHeld
      A set of keys that are currently pressed down.
      static java.util.Vector<Tuple<java.awt.event.MouseEvent,​java.lang.Integer>> mouseClickEvents
      The list of mouse clicked events that have been fired
      static java.awt.Point mousePosition
      The current mouse position on the canvas, if anything.
      static CanvasOptions options
      The options for the behavior of the canvas, see CanvasOptions
      static CanvasPanel panel
      A CanvasComponent, which handles all the rendering n stuff
      static java.util.List<RenderLifecycle> renderLifecycles
      The RenderLifecycle: allows you to write code to run before and after a frame is rendered
      static java.awt.Dimension startSize
      the initial size of the Canvas
      static java.awt.geom.Point2D.Float translation
      The translation of the canvas, used for centering and panning
      static java.lang.Object translationSync
      Sync for translation: Use when modifying the translation
    • Constructor Summary

      Constructors 
      Constructor Description
      InternalCanvas()  
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • drawableSync

        public static final java.lang.Object drawableSync
        Sync with drawables: Use when modifying a drawable
      • animationSync

        public static final java.lang.Object animationSync
        Sync with animations: Notifies on animation finish
      • frameSync

        public static final java.lang.Object frameSync
        Sync with frame: Notifies on end of frame
      • elements

        public static final ElementContainer elements
        the elements that are currently on the canvas
      • animations

        public static final java.util.List<Animation> animations
        the list of animations that are currently running
      • frame

        public static int frame
        The current frame
      • renderLifecycles

        public static java.util.List<RenderLifecycle> renderLifecycles
        The RenderLifecycle: allows you to write code to run before and after a frame is rendered
      • initialized

        public static boolean initialized
        Whether this has been initialized yet
      • startSize

        public static java.awt.Dimension startSize
        the initial size of the Canvas
      • translation

        public static java.awt.geom.Point2D.Float translation
        The translation of the canvas, used for centering and panning
      • translationSync

        public static final java.lang.Object translationSync
        Sync for translation: Use when modifying the translation
      • mousePosition

        public static java.awt.Point mousePosition
        The current mouse position on the canvas, if anything.
      • mouseClickEvents

        public static final java.util.Vector<Tuple<java.awt.event.MouseEvent,​java.lang.Integer>> mouseClickEvents
        The list of mouse clicked events that have been fired
      • keysHeld

        public static final java.util.HashSet<java.lang.Integer> keysHeld
        A set of keys that are currently pressed down.
      • panel

        public static CanvasPanel panel
        A CanvasComponent, which handles all the rendering n stuff
      • canvas

        public static Canvas canvas
    • Constructor Detail

      • InternalCanvas

        public InternalCanvas()