code: public void setContentWidth(int width)
      {
          int w = width;
          if (max_size.width != -1 && w > max_size.width)
              w = max_size.width;
          if (min_size.width != -1 && w < min_size.width)
              w = min_size.width;
          content.width = w;
      }
docs: Sets the width of the content while considering the min- and max- width.
  @param width the width the set if possible