docs: function(opts) {
      Widget.call(this);
      var input = Widget.tag("input");
      this._input = input;
      var that = this;
      this.addClass("wdg-input");
      if (typeof opts !== 'object') opts = {};
      if (typeof opts.type !== 'string') opts.type = 'text';
      input.attr("type", opts.type);
      if (typeof opts.placeholder === 'string') {
          input.attr("placeholder", opts.placeholder);
      }
      if (typeof opts.size !== 'undefined') {
          opts.size = parseInt(opts.size) || 8;
          input.attr("size", opts.size);
      }
      if (typeof opts.width !== 'undefined') {
          input.css("width", opts.width);
      }
      var onValid = opts.onValid;
      if (typeof onValid === 'object' && typeof onValid.enabled === 'function') {
          opts.onValid = function(v) {
              onValid.enabled(v);
          };
      }
      else if (typeof onValid !== 'function') opts.onValid = null;
  
      if (typeof opts.validator === 'object') {
          var rx = opts.validator;
          opts.validator = function(v) {
              return rx.test(v);
          };
      }
      this._valid = 0;
      if (typeof opts.validator === 'function') {
          input.addEvent(
              "keyup",
              function() {
                  opts.validator.call(this);
              }
          );
      }
      input.addEvent(
          "keyup",
          function() {
              that.fireChange();
          }
      );
      if (typeof opts.onEnter === 'object' && typeof opts.onEnter.fire === 'function') {
          var onEnter = opts.onEnter;
          this.Enter(function() {
              onEnter.fire();
          });
      }
      input.addEvent(
          "keyup",
          function(evt) {
              if (that._valid > -1 && evt.keyCode == 13) {
                  // On  rend l'événement  asynchrone pour  éviter les
                  // problèmes de clavier virtuel qui reste affiché.
                  window.setTimeout(
                      function() {
                          that.fireEnter();
                      }
                  );
              } else {
                  that.validate();
              }
          }
      );
      if (typeof opts.value !== 'string') {
          opts.value = "";
      }
      input.addEvent(
          "focus",
          function() {
              that.selectAll();
          }
      );
      this._opts = opts;
      this.val(opts.value);
  
      if (typeof opts.label !== 'undefined') {
          var label = Widget.div("label").text(opts.label).attr("title", opts.label);
          this.append(label);
      }
      this.append(input);
  }