Package rope.gui

Class Crope

All Implemented Interfaces:
R_Constants, R_Constants_Colour
Direct Known Subclasses:
R_Board, R_Button, R_Dropdown, R_Palette, R_Palette_Selector, R_Slider

public abstract class Crope extends R_Graphic
  • Constructor Details

    • Crope

      public Crope(String type)
    • Crope

      public Crope(String type, vec2 pos, vec2 size)
    • Crope

      public Crope(String type, float x, float y, float sx, float sy)
  • Method Details

    • update

      public void update()
    • show_struc

      public void show_struc()
    • get

      public float get()
    • get

      public float get(int index)
    • get_all

      public float[] get_all()
    • get_dna

      public int get_dna()
    • set_type

      public Crope set_type(String type)
      Parameters:
      type - set the type, but that's can broken few routine function for event mangement. So use with precaution
      Returns:
      this.
    • get_type

      public String get_type()
    • is_active

      public boolean is_active()
      Returns:
      true when the gui is active
    • is_done

      public boolean is_done()
      Returns:
      true when the action gui is done
    • pos

      public Crope pos(float x, float y)
      Parameters:
      x -
      y -
      Returns:
    • pos

      public Crope pos(vec2 pos)
      Parameters:
      pos -
      Returns:
    • pos

      public vec2 pos()
    • top

      public int top()
    • bottom

      public int bottom()
    • left

      public int left()
    • right

      public int right()
    • size

      public Crope size(float size)
      Parameters:
      size -
      Returns:
    • size

      public Crope size(float w, float h)
      Parameters:
      w -
      h -
      Returns:
    • size

      public Crope size(vec2 size)
      Parameters:
      size -
      Returns:
    • size

      public vec2 size()
    • set_root

      public Crope set_root(float root)
      this function is used when you want create a gui color to set it at the specific start, to use with a color wheel
      Parameters:
      root -
      Returns:
    • set_hue

      public Crope set_hue(float hue)
    • set_sat

      public Crope set_sat(float sat)
    • set_bri

      public Crope set_bri(float bri)
    • opengl

      public Crope opengl(boolean is)
      Use this option when you create a faster color slider, very usefull with big GUI or with gradient one. ACHTUNG: This option can be only use in P2D or P3D Processing context.
      Parameters:
      is -
      Returns:
    • set_mode

      public Crope set_mode(int mode)
      You can select different palette mode, with Processing classic renderer only mode 0 is available. mode 0, GRADIENT : hue range mode 3,4,5 RGB range mode 10, RAINDOW, HUE, SPECTRUM; mode 10, 11,12, 13 all color hsb range.
      Parameters:
      mode - give the opportunity to change the color randering
      Returns:
    • set_fill

      public Crope set_fill(int colour)
      set fill color of your gui
      Parameters:
      colour -
      Returns:
    • set_fill

      public Crope set_fill(int colour_in, int colour_out)
      set fill color of your gui
      Parameters:
      colour_in -
      colour_out -
      Returns:
    • set_stroke

      public Crope set_stroke(int colour)
      set stroke color of your gui
      Parameters:
      colour -
      Returns:
    • set_stroke

      public Crope set_stroke(int colour_in, int colour_out)
      set stroke color in and out of your gui
      Parameters:
      colour_in -
      colour_out -
      Returns:
    • set_thickness

      public Crope set_thickness(float thickness)
      set_thickness() is like strokeWeight
      Parameters:
      thickness -
      Returns:
    • set_rounded

      public Crope set_rounded(float rounded)
      ASPECT
    • set_aspect

      public Crope set_aspect(int fill_colour, int stroke_colour, float thickness)
    • set_aspect

      public Crope set_aspect(int fill_colour_in, int fill_colour_out, int stroke_colour_in, int stroke_colour_out, float thickness)
    • get_label

      public String get_label()
      LABEL
    • set_fill_label

      public Crope set_fill_label(int colour)
    • set_fill_label

      public Crope set_fill_label(int colour_in, int colour_out)
    • set_align_label_name

      public Crope set_align_label_name(int align)
    • set_align_label_value

      public Crope set_align_label_value(int align)
    • set_label

      public Crope set_label(String label)
    • set_label

      public Crope set_label(String label, float x, float y)
    • set_label

      public Crope set_label(String label, vec2 pos_label)
    • set_pos_label

      public Crope set_pos_label(vec2 pos)
    • set_pos_label

      public Crope set_pos_label(float x, float y)
    • show_label

      public void show_label()
    • set_pos_value

      public Crope set_pos_value(vec2 pos)
      VALUE
    • set_pos_value

      public Crope set_pos_value(float x, float y)
    • show_value

      public void show_value()
    • get_font

      public processing.core.PFont get_font()
      Returns:
      the current font of crope
    • set_font

      public Crope set_font(processing.core.PFont font)
    • set_font

      public Crope set_font(String font_name, int size)
    • get_font_size

      public int get_font_size()
      Returns:
      size of crope label
    • set_font_size

      public Crope set_font_size(int font_size)
    • get_rollover_type

      public int get_rollover_type()
      Returns:
      the type of rollover
    • set_rollover_type

      public Crope set_rollover_type(int rollover_type)
    • get_id_midi

      public int get_id_midi()
      Returns:
      int id_midi of crope
    • set_id_midi

      public Crope set_id_midi(int id_midi)
    • get_id

      public int get_id()
      Returns:
      int id of crope
    • set_id

      public Crope set_id(int id)
    • get_rank

      public int get_rank()
      Returns:
      int rank of crope
    • set_rank

      public Crope set_rank(int rank)
    • get_name

      public String get_name()
      Returns:
      String name of crope
    • set_name

      public Crope set_name(String name)
    • inside

      public boolean inside()
      Returns:
      true if the cursor is inside the crope shape