Class YAHOO.ext.grid.TextEditor
Provides basic text editing for a cells and supports the following configuration options:
- allowBlank - True if the cell is allowed to be empty.
- minLength - The minimum length the cell will accept.
- maxLength - The maximum length the cell will allow.
- minText - The tooltip to display when the length of the value in the cell is below the minimum.
- maxText - The tooltip to display when the length of the value in the cell is above the maximum.
- selectOnFocus - True to select the text when the editor is activated.
- blankText - The tooltip (error message) to display when the cell is empty and is not allowed to be.
- regex - A regular expression to match if the value is valid. If the regex.test(value) returns false, the value is considered invalid.
- regexText - The tooltip (error message) to display when regex does not match.
- validator - Any custom validation function you want called. The function must return true if the data is valid or an error message otherwise.
- validationDelay - The delay in milliseconds for validation. Each time the user types something the field is validated after a specified delay, setting this value allows you to customize that delay (for example, if your custom validation routine is slow).
For more information on using this editor, see
this blog post.
Public Properties
This class has no public properties.
Public Methods
|
TextEditor(Object config ) |
TextEditor |
Create a new TextEditor |
Public Events
This class has no public events.
Constructor Details
TextEditor
public function TextEditor(Object config
)
yui-ext - Copyright © 2006 Jack Slocum. |
Yahoo! UI - Copyright © 2006 Yahoo! Inc.
All rights reserved.