code: public void setRGB(int red, int green, int blue) throws Exception {
  
          CmsColor color = new CmsColor();
          color.setRGB(red, green, blue);
  
          m_red = red;
          m_green = green;
          m_blue = blue;
          m_hue = color.getHue();
          m_saturation = color.getSaturation();
          m_brightness = color.getValue();
  
          m_tbRed.setText(Integer.toString(m_red));
          m_tbGreen.setText(Integer.toString(m_green));
          m_tbBlue.setText(Integer.toString(m_blue));
          m_tbHue.setText(Integer.toString(m_hue));
          m_tbSaturation.setText(Integer.toString(m_saturation));
          m_tbBrightness.setText(Integer.toString(m_brightness));
          m_tbHexColor.setText(color.getHex());
          setPreview(color.getHex());
  
          updateSliders();
      }
docs: Sets the Red, Green, and Blue color variables. This will automatically populate the Hue, Saturation and Brightness and Hexadecimal fields, too.
  
  The RGB color model is an additive color model in which red, green, and blue light are added together in various ways to reproduce a broad array of colors. The name of the model comes from the initials of the three additive primary colors, red, green, and blue.
  @param red strength - valid range is 0-255
  @param green strength - valid range is 0-255
  @param blue strength - valid range is 0-255
  @throws java.lang.Exception Exception if the Red, Green or Blue variables are out of range.