ui.igTextEditor

ui.igTextEditor_image

The igTextEditor control provides support for handling text user input. Options include specifying null text, plain text, password, and multiline modes. Further information regarding the classes, options, events, methods and themes of this API are available under the associated tabs above.

For more details on the igTextEditor control API, refer to the base igEditor control’s API documentation.

The following code snippet demonstrates how to initialize the igTextEditor control.

Click here for more information on how to get started using this API. For details on how to reference the required scripts and themes for the igTextEditor control read, Using JavaScript Resources in Ignite UI and Styling and Theming Ignite UI.

Code Sample

     <!doctype html>
      <html>
      <head>
          <!-- Infragistics Combined CSS -->
          <link href="css/themes/infragistics/infragistics.theme.css" rel="stylesheet" type="text/css" />
          <link href="css/structure/infragistics.css" rel="stylesheet" type="text/css" />
          <!-- jQuery Core -->
          <script src="js/jquery.js" type="text/javascript"></script>
          <!-- jQuery UI -->
          <script src="js/jquery-ui.js" type="text/javascript"></script>
          <!-- Infragistics Combined Scripts -->
          <script src="js/infragistics.core.js" type="text/javascript"></script>
          <script src="js/infragistics.lob.js" type="text/javascript"></script>
          <script type="text/javascript">
                $(function () {
                    $("#textEditor").igTextEditor({
                        width: 160,
                        placeHolder: "Enter Text"
                    });
                });
           </script>
      
      </head>
      <body>
         <input id="textEditor" />
       </body>
      </html>
      

Related Samples

Related Topics

Dependencies

jquery-1.9.1.js
jquery.ui-1.9.0.js
infragistics.util.js
infragistics.ui.popover.js
infragistics.ui.notifier.js

Inherits

  • allowNullValue
    Inherited

    Type:
    bool
    Default:
    false

    Sets/Gets ability to prevent null value.
    If that option is false, and editor has no value, then value is set to an empty string.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                allowNullValue : false
            });
    
            //Get
            var allowNullValue = $(".selector").igTextEditor("option", "allowNullValue");
    
            //Set
            $(".selector").igTextEditor("option", "allowNullValue", false);
            
  • buttonType

    Type:
    enumeration
    Default:
    none

    Gets visibility of spin and drop-down button. That option can be set only on initialization. Combinations like 'dropdown,spin' or 'spinclear' are supported too. Note! This option can not be set runtime.

    Members

    • dropdown
    • Type:string
    • button to open list is located on the right side of input-field (or left side if base html element has direction:rtl);.
    • clear
    • Type:string
    • button to clear value is located on the right side of input-field (or left side if base html element has direction:rtl);.
    • spin
    • Type:string
    • spin buttons are located on the right side of input-field (or left side if base html element has direction:rtl).

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                buttonType : "dropdown"
            });
    
            //Get
            var button = $(".selector").igTextEditor("option", "buttonType");
            
  • disabled
    Inherited

    Type:
    bool
    Default:
    false

    Gets/Sets the disabled attribute.Does not allow editing. Disables all the buttons and iteracitons applied. On submit the current value is not sent into the request.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                disabled : false
            });
    
            //Get
            var disabled = $(".selector").igTextEditor("option", "disabled");
    
            //Set
            $(".selector").igTextEditor("option", "disabled", true);
            
  • dropDownAnimationDuration

    Type:
    number
    Default:
    300

    Gets/Sets show/hide drop-down list animation duration in milliseconds.

    Code Sample

            //Initialize
            $(".selector").igTextEditor({
              dropDownAnimationDuration: 500
            });
     
            //Get
            var animationShowDuration= $(".selector").igTextEditor("option", "dropDownAnimationDuration");
     
            //Set
            $(".selector").igTextEditor("option", "dropDownAnimationDuration", 500);
            
  • dropDownAttachedToBody

    Type:
    bool
    Default:
    false

    Gets location of drop-down list.
    Value false will create html element for list as a child of main html element.
    Value true creates list as a child of body.
    Note! This option can not be set runtime.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                dropDownAttachedToBody : true
            });
    
            //Get
            var attachedToBody = $(".selector").igTextEditor("option", "dropDownAttachedToBody");      
            
  • dropDownOnReadOnly

    Type:
    bool
    Default:
    false

    Gets ability to limit editor to be used only from the dropdown list. When set to true the editor input is not editable.
    Note! In case there are no list items - the editor will reamin readonly
    Note! This option can not be set runtime.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                dropDownOnReadOnly : true
            });
    
            //Get
            var readOnly = $(".selector").igTextEditor("option", "dropDownOnReadOnly");  
          
  • dropDownOrientation

    Type:
    enumeration
    Default:
    auto

    Gets/Sets drop down opening orientation for the dorp down list when open button is clicked. If auto option is set the component calculates if there is enough space at the bottom, if not checks the space above the component and if in both directions there is not enough space it openes the dropdown down way.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                dropDownOrientation : "top"
            });
    
            //Get
            var orientation = $(".selector").igTextEditor("option", "dropDownOrientation");
    
            //Set
            $(".selector").igTextEditor("option", "dropDownOrientation", "bottom");      
            
  • excludeKeys

    Type:
    string
    Default:
    null

    Gets/Sets ability to prevent entering specific characters from keyboard or on paste.
    Notes:
    If both "excludeKeys" and "includeKeys" options are used, then "excludeKeys" has priority and includeKeys options is not respected.
    The option is case sensitive!.

    Code Sample

            //Initialize
            $(".selector").igTextEditor({
                   excludeKeys: "AaBC"
            });
     
            //Get
            var excludedKeys= $(".selector").igTextEditor("option", "excludeKeys");
     
            //Set
            $(".selector").igTextEditor("option", "excludeKeys", "ABC");
            
  • height
    Inherited

    Type:
    enumeration
    Default:
    null

    Gets/Sets how the height of the control can be set.

    Members

    • null
    • Type:object
    • will fit the editor inside its parent container, if no other heights are defined.
    • string
    • The height can be set in pixels (px) and percentage (%).
    • number
    • The height can be set as a number in pixels.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                height : 25
            });
    
            //Get
            var height = $(".selector").igTextEditor("option", "height");
    
            //Set
            $(".selector").igTextEditor("option", "height", 25);
            
  • includeKeys

    Type:
    string
    Default:
    null

    Gets/Sets ability to enter only specific characters in input-field from keyboard and on paste.
    Notes:
    If both "excludeKeys" and "includeKeys" options are used, then "excludeKeys" has priority and includeKeys options is not respected.
    The option is case sensitive!.

    Code Sample

            //Initialize
            $(".selector").igTextEditor({
                 includeKeys: "AaBC"
            });
     
            //Get
            var includedKeys= $(".selector").igTextEditor("option", "includeKeys");
     
            //Set
            $(".selector").igTextEditor("option", "includeKeys", "ABC");
           
  • inputName
    Inherited

    Type:
    string
    Default:
    null

    Sets the name attribute of the value input. This input is used to sent the value to the server. In case the target element is input and it has name attribute, but the developer has set the inputName option, so this option overwrites the value input and removes the attribute from the element.

    Code Sample

          //Initialize 
          $(".selector").igTextEditor({     
              inputName : "textField"
          });  
     
          //Get 
          var inputName = $(".selector").igTextEditor("option", "inputName");  
     
          //Set 
          $(".selector").igTextEditor("option", "inputName", "textField");
          
  • isLimitedToListValues

    Type:
    bool
    Default:
    false

    Sets the ability to allow values only set into the list items. This validation is done only when the editor is blured, or enter key is pressed.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                isLimitedToListValues : true
            });
    
            //Get
            var limited = $(".selector").igTextEditor("option", "isLimitedToListValues");
    
            //Set
            $(".selector").igTextEditor("option", "isLimitedToListValues", false);      
          
  • listItemHoverDuration

    Type:
    number
    Default:
    0

    Sets the hover/unhover animation duration.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                listItemHoverDuration : 100
            });
    
            //Get
            var hoverDuration = $(".selector").igTextEditor("option", "listItemHoverDuration");
    
            //Set
            $(".selector").igTextEditor("option", "listItemHoverDuration", 100);      
          
  • listItems

    Type:
    array
    Default:
    null
    Elements Type:

    Gets/Sets list of items which are used for drop-down list.
    Items in list can be strings, numbers or objects. The items are directly rendered without casting, or manipulating them.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                listItems : [
                    "item 1",
                    "item 2",
                    "item 3"
                ]
            });
    
            //Get
            var items = $(".selector").igTextEditor("option", "listItems");
    
            //Set
            $(".selector").igTextEditor("option", "listItems", ["item 1", "item 2", "item 3"]);
            
  • listWidth

    Type:
    number
    Default:
    0

    Gets/Sets custom width of drop-down list in pixels. If value is equal to 0 or negative, then the width of editor is used.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                listWidth : 200
            });
    
            //Get
            var width = $(".selector").igTextEditor("option", "listWidth");
    
            //Set
            $(".selector").igTextEditor("option", "listWidth", 200);
            
  • locale

    Type:
    object
    Default:
    null

    Gets/Sets strings used for title of buttons. Value of object should contain pairs or key:value members. Note: any sub-option of locale can appear within the main option of igEditor. In this case those values within main options will have highest priority and override corresponding value in locale.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                locale: {
    			        spinUpperTitle: 'SpinUp'
                }
            });
    
            //Get
            var locale = $(".selector").igTextEditor("option", "locale");
    
            //Set
            $(".selector").igTextEditor("option", "locale", {spinUpperTitle: 'SpinUp'});
            
  • maxLength

    Type:
    number
    Default:
    null

    Gets/Sets maximum length of text which can be entered by user.
    Negative values or 0 disables that behavior.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                maxLength : 25
            });
    
            //Get
            var textLength = $(".selector").igTextEditor("option", "maxLength");
    
            //Set
            $(".selector").igTextEditor("option", "maxLength", 25);
            
  • nullValue
    Inherited

    Type:
    enumeration
    Default:
    null

    Sets/Gets the representation of null value. In case of default the value for the input is set to null, which makes the input to hold an empty string.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                nullValue : null
            });
    
            //Get
            var nullValue = $(".selector").igTextEditor("option", "nullValue");
    
            //Set
            $(".selector").igTextEditor("option", "nullValue", null);
            
  • placeHolder

    Type:
    string
    Default:
    null

    Gets/Sets text which appears in editor when editor has no focus and "value" in editor is null or empty string.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                placeHolder : "Enter Value"
            });
    
            //Get
            var placeHolder = $(".selector").igTextEditor("option", "placeHolder");
    
            //Set
            $(".selector").igTextEditor("option", "placeHolder", "Enter Value");
            
  • preventSubmitOnEnter

    Type:
    bool
    Default:
    false

    Sets the ability of the editor to prevent form submition on enter key pressed.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                preventSubmitOnEnter : false
            });
    
            //Get
            var preventSubmitOnEnter = $(".selector").igTextEditor("option", "preventSubmitOnEnter");
    
            //Set
            $(".selector").igTextEditor("option", "preventSubmitOnEnter", false);
            
  • readOnly
    Inherited

    Type:
    bool
    Default:
    false

    Gets/Sets the readonly attribute.Does not allow editing. Disables all the buttons and iteracitons applied. On submit the current value is sent into the request.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                readOnly : true
            });
    
            //Get
            var readOnly = $(".selector").igTextEditor("option", "readOnly");
    
            //Set
            $(".selector").igTextEditor("option", "readOnly", true);
            
  • revertIfNotValid

    Type:
    bool
    Default:
    true

    Sets the editor to revert value to previous value in case of not valid value on blur, or enter key. If set to false clear is called.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                revertIfNotValid : true
            });
    
            //Get
            var revertIfNotValid = $(".selector").igTextEditor("option", "revertIfNotValid");
    
            //Set
            $(".selector").igTextEditor("option", "revertIfNotValid", true);
            
  • selectionOnFocus

    Type:
    enumeration
    Default:
    selectAll

    Set the action when the editor gets focused. The default value is selectAll.

    Members

    • selectAll
    • Type:string
    • Setting this option will select all the text into the editor when the edit mode gets enetered.
    • atStart
    • Type:string
    • Setting this option will move the cursor at the begining the text into the editor when the edit mode gets enetered.
    • atEnd
    • Type:string
    • Setting this option will move the cursor at the end the text into the editor when the edit mode gets enetered.
    • browserDefault
    • Type:string
    • Setting this option won't do any extra logic, but proceed with browser default behavior.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                selectionOnFocus: 0
            });
     
            //Get
            var selectionOnFocus= $(".selector").igTextEditor("option", "selectionOnFocus");
     
            //Set
            $(".selector").igTextEditor("option", "selectionOnFocus", 0);
          
  • spinWrapAround

    Type:
    bool
    Default:
    false

    Gets/Sets ability to automatically change the hoverd item into the opened dropdown list to its oposide side. When last item is reached and the spin down is clicked the first item gets hovered and vice versa.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                spinWrapAround : true
            });
    
            //Get
            var spinAround = $(".selector").igTextEditor("option", "spinWrapAround");
    
            //Set
            $(".selector").igTextEditor("option", "spinWrapAround", true);
            
  • suppressNotifications

    Type:
    bool
    Default:
    false

    Disables default notifications for basic validation scenarios built in the editors such as required list selection, value wrapping around or spin limits.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                suppressNotifications : true
            });
    
            //Get
            var suppressNotifications = $(".selector").igTextEditor("option", "suppressNotifications");
    
            //Set
            $(".selector").igTextEditor("option", "suppressNotifications", true);
            
  • tabIndex
    Inherited

    Type:
    number
    Default:
    null

    Gets/Sets value in tabIndex for editor.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                tabIndex : 3
            });
    
            //Get
            var tabIndex = $(".selector").igTextEditor("option", "tabIndex");
    
            //Set
            $(".selector").igTextEditor("option", "tabIndex", 3);
            
  • textAlign

    Type:
    enumeration
    Default:
    left

    Gets/Sets horizontal alignment of text in editor. If that option is not set, then 'right' is used for 'numeric', 'currency' and 'percent' editors and the 'left' is used for all other types of editor.

    Members

    • left
    • Type:string
    • right
    • Type:string
    • center
    • Type:string

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                textAlign : "center"
            });
    
            //Get
            var align = $(".selector").igTextEditor("option", "textAlign");
    
            //Set
            $(".selector").igTextEditor("option", "textAlign", "center");
            
  • textMode

    Type:
    enumeration
    Default:
    text

    Gets text mode of editor such as: single-line text editor, password editor or multiline editor. That option has effect only on initialization. If based element (selector) is TEXTAREA, then it is used as input-field.

    Members

    • text
    • Type:string
    • Single line text editor based on INPUT element is created.
    • password
    • Type:string
    • Editor based on INPUT element with type password is created.
    • multiline
    • Type:string
    • multiline editor based on TEXTAREA element is created.

    Code Sample

     
            //Initialize
            $(".selector").igEditor({
                textMode : "multiline"
            });
    
            //Get
            var mode = $(".selector").igTextEditor("option", "textMode");
    
            //Set
            $(".selector").igTextEditor("option", "textMode", "multiline");      
            
  • toLower

    Type:
    bool
    Default:
    false

    Gets/Sets ability to convert input characters to lower case (true) or keeps characters as they are (false). That option has effect only while keyboard entries and paste.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                toLower : true
            });
    
            //Get
            var toLower = $(".selector").igTextEditor("option", "toLower");
    
            //Set
            $(".selector").igTextEditor("option", "toLower", true);
            
  • toUpper

    Type:
    bool
    Default:
    false

    Gets/Sets ability to convert input characters to upper case (true) or keeps characters as they are (false). That option has effect only while keyboard entries and paste.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                toUpper : true
            });
    
            //Get
            var toUpper = $(".selector").igTextEditor("option", "toUpper");
    
            //Set
            $(".selector").igTextEditor("option", "toUpper", true);
            
  • validatorOptions
    Inherited

    Type:
    object
    Default:
    null

    Sets/Gets options supported by the igValidator widget.
    Note: Validation rules of igValidator, such as min and max value/length are applied separately triggering errors,
    while similar options of the editor work to prevent wrong values from being entered.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                validatorOptions : {
                   successMessage: "Success",
    					     required: true,
    					     onchange: true,
                   notificationOptions: { mode: "popover" }
                }
            });
    
            //Get
            var validateOptions = $(".selector").igTextEditor("option", "validatorOptions");
    
            //Set
            $(".selector").igTextEditor("option", "validatorOptions", {onblur: true, onchange: true});
            
  • value
    Inherited

    Type:
    object
    Default:
    null

    Gets/Sets value in editor. The effect of setting/getting that option depends on type of editor and on dataMode options for every type of editor.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                value : "Some text"
            });
    
            //Get
            var value = $(".selector").igTextEditor("option", "value");
    
            //Set
            $(".selector").igTextEditor("option", "value", "Some text");      
            
  • visibleItemsCount

    Type:
    number
    Default:
    5

    Gets how many items should be shown at once.
    Notes:
    That option is overwritten if the number of list items is less than the value. In that case the height of the dropdown is adjusted to the number of items.
    Note! This option can not be set runtime.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                visibleItemsCount : 5
            });
    
            //Get
            var visibleItemsCount = $(".selector").igTextEditor("option", "visibleItemsCount");    
            
  • width
    Inherited

    Type:
    enumeration
    Default:
    null

    Gets/Sets how the width of the control can be set.

    Members

    • null
    • Type:object
    • will stretch to fit data, if no other widths are defined.
    • string
    • The widget width can be set in pixels (px) and percentage (%).
    • number
    • The widget width can be set as a number in pixels.

    Code Sample

     
            //Initialize
            $(".selector").igTextEditor({
                width : 200
            });
    
            //Get
            var width = $(".selector").igTextEditor("option", "width");
    
            //Set
            $(".selector").igTextEditor("option", "width", 200);
            

For more information on how to interact with the Ignite UI controls' events, refer to
Using Events in Ignite UI.

Note: Calling API methods programmatically does not raise events related to their operation unless specifically stated otherwise by the corresponding API documentation; those events are only raised by their respective user interaction.

Show Details
  • blur
    Inherited

    Cancellable:
    false

    Event which is raised when input field of editor loses focus.
    Function takes argument evt.
    Use ui.owner to obtain reference to igEditor.
    Use evt.originalEvent to obtain reference to event of browser.

    Code Sample

              $(document).delegate(".selector", "igtexteditorblur", function (evt) {
    
                  //return browser event
                  evt.originalEvent;
              });
    
              //Initialize
              $(".selector").igTextEditor({
                  blur: function (evt) {
                  ...
                  }
              });
          
  • dropDownItemSelected

    Cancellable:
    true

    Event which is raised when the drop down list item is selected.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.editorInput to obtain reference to the editable input
    Use ui.list to obtain reference to the list contaier.
    Use ui.item to obtain reference to the list item which is selected.

    Code Sample

              $(document).delegate(".selector", "igtexteditordropDownItemSelected", function (evt, ui) {
    
                  //return browser event
                  evt.originalEvent;
                  
                  //use to obtain reference to igEditor
                  ui.owner;
    				      //use to obtain reference to the editable input
                  ui.editorInput;
    				      //use to obtain reference to the list contaier 
                  ui.list;
    				      //use to obtain reference to the list item which is selected
                  ui.item;
              });
    
              //Initialize
              $(".selector").igTextEditor({
                  dropDownItemSelected: function (evt, ui) {
                  ...
                  }
              });
          
  • dropDownItemSelecting

    Cancellable:
    true

    Event which is raised when the drop down list item is selecting.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.editorInput to obtain reference to the editable input
    Use ui.list to obtain reference to the list contaier.
    Use ui.item to obtain reference to the list item which is about to be selected.

    Code Sample

              $(document).delegate(".selector", "igtexteditordropDownItemSelecting", function (evt, ui) {
    
                  //return browser event
                  evt.originalEvent;
                  //use to obtain reference to igEditor
                  ui.owner;
    				      //use to obtain reference to the editable input
                  ui.editorInput;
    				      //use to obtain reference to the list contaier 
                  ui.list;
    				      //use to obtain reference to the list item which is selected
                  ui.item;
              });
    
              //Initialize
              $(".selector").igTextEditor({
                  dropDownItemSelecting: function (evt, ui) {
                  ...
                  }
              });
          
  • dropDownListClosed

    Cancellable:
    false

    Event which is raised when the drop down is already closed.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.editorInput to obtain reference to the editable input
    Use ui.list to obtain reference to the list contaier.

    Code Sample

                 $(document).delegate(".selector", "igtexteditordropDownListClosed", function (evt, ui) {                  
                 
                 //return browser event
                  evt.originalEvent;
                  
                  //use to obtain reference to igEditor
                  ui.owner;
    				      //use to obtain reference to the editable input
                  ui.editorInput;
    				      //use to obtain reference to the list contaier 
                  ui.list;
                });
                
                //Initialize
                $(".selector").igTextEditor({
                    dropDownListClosed: function (evt, ui) {
                    ...
                    }
                });
              
  • dropDownListClosing

    Cancellable:
    true

    Event which is raised when the drop down is closing.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.editorInput to obtain reference to the editable input
    Use ui.list to obtain reference to the list contaier.

    Code Sample

                 $(document).delegate(".selector", "igtexteditordropDownListClosing", function (evt, ui) {                  
                  
                  //return browser event
                  evt.originalEvent;
                  
                  //use to obtain reference to igEditor
                  ui.owner;
    				      //use to obtain reference to the editable input
                  ui.editorInput;
    				      //use to obtain reference to the list contaier 
                  ui.list;
                });
                
                //Initialize
                $(".selector").igTextEditor({
                    dropDownListClosing: function (evt, ui) {
                    ...
                    }
                });
              
  • dropDownListOpened

    Cancellable:
    false

    Event which is raised when the drop down is already opened.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.editorInput to obtain reference to the editable input
    Use ui.list to obtain reference to the list contaier.

    Code Sample

                 $(document).delegate(".selector", "igtexteditordropDownListOpened", function (evt, ui) {                  
                    
                  //return browser event
                  evt.originalEvent;
                  
                  //use to obtain reference to igEditor
                  ui.owner;
    				      //use to obtain reference to the editable input
                  ui.editorInput;
    				      //use to obtain reference to the list contaier 
                  ui.list;
                });
                
                //Initialize
                $(".selector").igTextEditor({
                    dropDownListOpened: function (evt, ui) {
                    ...
                    }
                });
              
  • dropDownListOpening

    Cancellable:
    true

    Event which is raised when the drop down is opening.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.editorInput to obtain reference to the editable input
    Use ui.list to obtain reference to the list contaier.

    Code Sample

                 $(document).delegate(".selector", "igtexteditordropDownListOpened", function (evt, ui) {                  
                    
                  //return browser event
                  evt.originalEvent;
                  
                  //use to obtain reference to igEditor
                  ui.owner;
    				      //use to obtain reference to the editable input
                  ui.editorInput;
    				      //use to obtain reference to the list contaier 
                  ui.list;
                });
                
                //Initialize
                $(".selector").igTextEditor({
                    dropDownListOpened: function (evt, ui) {
                    ...
                    }
                });
              
  • focus
    Inherited

    Cancellable:
    false

    Event which is raised when input field of editor gets focus.
    Function takes argument evt.
    Use ui.owner to obtain reference to igEditor.
    Use evt.originalEvent to obtain reference to event of browser.

    Code Sample

                 $(document).delegate(".selector", "igtexteditorfocus", function (evt) {
                      
                    //return browser event
                    evt.originalEvent;
                });
                
                //Initialize
                $(".selector").igTextEditor({
                    focus: function (evt) {
                    ...
                    }
                });
              
  • keydown

    Cancellable:
    true

    Event which is raised on keydown event.
    Return false in order to cancel key action.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.key to obtain value of keyCode.

    Code Sample

          $(document).delegate(".selector", "igtexteditorkeydown", function (evt, ui) {
              //return browser event
              evt.originalEvent;
              //use to obtain reference to igEditor 
              ui.owner; 
              //use to obtain value of keyCode
              ui.key;
          });
    
          //Initialize
          $(".selector").igTextEditor({
              keydown: function (evt, ui) {
              ...
              }
          });
          
  • keypress

    Cancellable:
    true

    Event which is raised on keypress event.
    Return false in order to cancel key action.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.key to obtain value of keyCode.
    Set ui.key to another character which will replace original entry.

    Code Sample

            $(document).delegate(".selector", "igtexteditorkeypress", function (evt, ui) {
                //return browser event
                evt.originalEvent;
                //use to obtain reference to igEditor 
                ui.owner;
                //use to obtain value of keyCode
                ui.key;
                //set the ui.key to "A" -a cahracter which will replace the original entry
                ui.key = 65;
            });
    
            //Initialize
            $(".selector").igTextEditor({
                keypress: function (evt, ui) {
                ...
                }
            });       
            
  • keyup

    Cancellable:
    false

    Event which is raised on keyup event.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.key to obtain value of keyCode.

    Code Sample

            $(document).delegate(".selector", "igtexteditorkeyup", function (evt, ui) {
                //return browser event
                evt.originalEvent;
                
                //use to obtain reference to igEditor 
                ui.owner;
                //use to obtain value of keyCode
                ui.key;
    
            });
    
            //Initialize
            $(".selector").igTextEditor({
                keyup: function (evt, ui) {
                ...
                }
            });
            
  • mousedown
    Inherited

    Cancellable:
    false

    Event which is raised on mousedown at any part of editor including drop-down list.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.elementType to obtain type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
    Use ui.id and ui.elementType to obtain flag which represents html element under mouse.

    Code Sample

            $(document).delegate(".selector", "igtexteditormousedown", function (evt, ui) {
                //return browser event
                evt.originalEvent;
    
                //obtains type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
                ui.elementType;
    
                //obtains id of html element under mouse, such as field, button, spinUpper, spinLower or item#.
                ui.id;
    
            });
    
            //Initialize
            $(".selector").igTextEditor({
                mousedown: function (evt, ui) {
                ...
                }
            });
            
  • mousemove
    Inherited

    Cancellable:
    false

    Event which is raised on mousemove at any part of editor including drop-down list.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.elementType to obtain type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
    Use ui.id and ui.elementType to obtain flag which represents html element under mouse.

    Code Sample

            $(document).delegate(".selector", "igtexteditormousemove", function (evt, ui) {
                //return browser event
                evt.originalEvent;
    
                //obtains type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
                ui.elementType;
    
                //obtains id of html element under mouse, such as field, button, spinUpper, spinLower or item#.
                ui.id;
    
            });
    
            //Initialize
            $(".selector").igTextEditor({
                mousemove: function (evt, ui) {
                ...
                }
            });
            
  • mouseout
    Inherited

    Cancellable:
    false

    Event which is raised on mouseleave at any part of editor including drop-down list.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.elementType to obtain type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
    Use ui.id and ui.elementType to obtain flag which represents html element under mouse.

    Code Sample

            $(document).delegate(".selector", "igtexteditormouseout", function (evt, ui) {
                //return browser event
                evt.originalEvent;
    
                //obtains type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
                ui.elementType;
    
                //obtains id of html element under mouse, such as field, button, spinUpper, spinLower or item#.
                ui.id;
            });
    
            //Initialize
            $(".selector").igTextEditor({
                mouseout: function (evt, ui) {
                ...
                }
            });
            
  • mouseover
    Inherited

    Cancellable:
    false

    Event which is raised on mouseover at any part of editor including drop-down list.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.elementType to obtain type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
    Use ui.id and ui.elementType to obtain flag which represents html element under mouse.

    Code Sample

          $(document).delegate(".selector", "igtexteditormouseover", function (evt, ui) {
              //return browser event
              evt.originalEvent;
              
              //obtains type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
              ui.elementType;
    
              //obtains id of html element under mouse, such as field, button, spinUpper, spinLower or item#.
              ui.id;
          });
    
          //Initialize
          $(".selector").igTextEditor({
              mouseover: function (evt, ui) {
              ...
              }
          });
          
  • mouseup
    Inherited

    Cancellable:
    false

    Event which is raised on mouseup at any part of editor including drop-down list.
    Function takes arguments evt and ui.
    Use evt.originalEvent to obtain reference to event of browser.
    Use ui.owner to obtain reference to igEditor.
    Use ui.elementType to obtain type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
    Use ui.id and ui.elementType to obtain flag which represents html element under mouse.

    Code Sample

          $(document).delegate(".selector", "igtexteditormouseup", function (evt, ui) {
              //return browser event
              evt.originalEvent;
    
    
              //obtains type of html element under mouse, such as field, button, spinUpper, spinLower or item#.
              ui.elementType;
    
              //obtains id of html element under mouse, such as field, button, spinUpper, spinLower or item#.
              ui.id;
    
          });
    
          //Initialize
          $(".selector").igTextEditor({
              mouseup: function (evt, ui) {
              ...
              }
          });
            
  • rendered
    Inherited

    Cancellable:
    false

    Event which is raised after rendering of the editor completes.
    Function takes arguments evt and ui.
    Use ui.owner to get a reference to the editor performing rendering.
    Use ui.element to get a reference to the editor element.

    Code Sample

            $(document).delegate(".selector", "igtexteditorrendered", function (evt, ui) {
              
            });
    
            //Initialize
            $(".selector").igTextEditor({
                rendered: function () {
                ...
                }
            });
            
  • rendering
    Inherited

    Cancellable:
    false

    Event which is raised before rendering of the editor completes.
    Function takes arguments evt and ui.
    Use ui.owner to get a reference to the editor performing rendering.
    Use ui.element to get a reference to the editor element.

    Code Sample

            $(document).delegate(".selector", "igtexteditorrendering", function (evt, ui) {
              
            });
    
            //Initialize
            $(".selector").igTextEditor({
                rendering: function () {
                ...
                }
            });
            
  • textChanged

    Cancellable:
    false

    Event which is raised after text in editor was changed. It can be raised when keyUp event occurs,
    or when the clear button is clicked or when an item from a list is selected.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.text to obtain new text
    Use ui.oldText to obtain the old text.

    Code Sample

            $(document).delegate(".selector", "igtexteditortextChanged", function (evt, ui) {
              
              //Use to obtain reference to igEditor
              ui.owner;
    				  //Use to obtain new text
              ui.text;
    				  //Use to obtain the old text
              ui.oldText;
            });
    
            //Initialize
            $(".selector").igTextEditor({
                textChanged: function (evt, ui) {
                ...
                }
            });
            
  • valueChanged
    Inherited

    Cancellable:
    false

    Event which is raised after value in editor was changed. It can be raised on lost focus or on spin events.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.newValue to obtain the new value.
    Use ui.originalValue to obtain the original value.
    Use ui.editorInput to obtain reference to the editor input.

    Code Sample

            $(document).delegate(".selector", "igtexteditorvaluechanged", function (evt, ui) {
    
    						//Use to obtain reference to igEditor
    						ui.owner;
    						//Use to obtain new value
    						ui.newValue;
    						//Use to obtain the value coming from the native event arguments
    						ui.originalValue;
    						//Use to obtain reference to editor input
    						ui.editorInput
            });
    
            //Initialize
            $(".selector").igTextEditor({
                valueChanged: function (evt, ui) {
                ...
                }
            });
            
  • valueChanging
    Inherited

    Cancellable:
    true

    Event which is raised before value in editor was changed.
    Return false in order to cancel change.
    It can be raised on lost focus or on spin events.
    Function takes arguments evt and ui.
    Use ui.owner to obtain reference to igEditor.
    Use ui.newValue to obtain the new value.
    Use ui.oldValue to obtain the old value.
    Use ui.editorInput to obtain reference to the editor input.

    Code Sample

            $(document).delegate(".selector", "igtexteditorvaluechanging", function (evt, ui) {
    
    						//Use to obtain reference to igEditor
    						ui.owner;
    						//Use to obtain new value
    						ui.newValue;
    						//Use to obtain old value
    						ui.oldValue;
    						//Use to obtain reference to editor input
    						ui.editorInput
            });
    
            //Initialize
            $(".selector").igTextEditor({
                valueChanging: function (evt, ui) {
                ...
                }
            });
            
  • clearButton

    .igTextEditor( "clearButton" );
    Return Type:
    jquery
    Return Type Description:
    Returns reference to jquery object.

    Returns a reference to the clear button UI element of the editor.

    Code Sample

     
          $(".selector").igTextEditor("clearButton");
          
  • destroy
    Inherited

    .igTextEditor( "destroy" );

    Destructor of the widget.

    Code Sample

     
           $(".selector").igTextEditor("destroy");
          
  • displayValue

    .igTextEditor( "displayValue" );
    Return Type:
    string
    Return Type Description:
    Visible text of the editor.

    Gets visible text in the editor.

    Code Sample

     
            $(".selector").igTextEditor("displayValue");
          
  • dropDownButton

    .igTextEditor( "dropDownButton" );
    Return Type:
    jquery
    Return Type Description:
    Returns reference to jquery object.

    Returns a reference to the clear button UI element of the editor.

    Code Sample

     
            $(".selector").igTextEditor("dropDownButton");
          
  • dropDownContainer

    .igTextEditor( "dropDownContainer" );
    Return Type:
    jquery
    Return Type Description:
    Returns reference to jquery object.

    Gets reference to jquery object which is used as container of drop-down.

    Code Sample

     
            $(".selector").igTextEditor("dropDownContainer");
          
  • dropDownVisible

    .igTextEditor( "dropDownVisible" );
    Return Type:
    bool
    Return Type Description:
    The visibility state of the drop down.

    Returns the visibility state of the drop down listing the items.

    Code Sample

     
            $(".selector").igTextEditor("dropDownVisible");
          
  • editorContainer
    Inherited

    .igTextEditor( "editorContainer" );
    Return Type:
    jquery
    Return Type Description:
    The container editor element.

    Gets reference to jquery object which is used as top/outer element of igEditor.

    Code Sample

     
            $(".selector").igTextEditor("editorContainer");
          
  • field
    Inherited

    .igTextEditor( "field" );
    Return Type:
    jquery
    Return Type Description:
    The visual editor element.

    Gets the visual editor element.

    Code Sample

     
            $(".selector").igTextEditor("editorContainer");
          
  • findListItemIndex

    .igTextEditor( "findListItemIndex", text:string, [matchType:object] );
    Return Type:
    number
    Return Type Description:
    Returns index of the found item.

    Finds index of list item by text that matches with the search parameters.

    • text
    • Type:string
    • The text to search for in the drop down list.
    • matchType
    • Type:object
    • Optional
    • The rule that is applied for searching the text.

    Code Sample

     
            $(".selector").igTextEditor("findListItemIndex");
          
  • getSelectedListItem

    .igTextEditor( "getSelectedListItem" );
    Return Type:
    jquery
    Return Type Description:
    Selected list item.

    Gets selected list item.

    Code Sample

     
            $(".selector").igTextEditor("getSelectedListItem");
          
  • getSelectedText

    .igTextEditor( "getSelectedText" );
    Return Type:
    string
    Return Type Description:
    Selected text in editor.

    Gets selected text in editor.

    Code Sample

     
            $(".selector").igTextEditor("getSelectedText");
          
  • getSelectionEnd

    .igTextEditor( "getSelectionEnd" );
    Return Type:
    number
    Return Type Description:
    End index of the selected text in editor.

    Gets end index of the selected text in editor.

    Code Sample

     
            $(".selector").igTextEditor("getSelectionEnd");
          
  • getSelectionStart

    .igTextEditor( "getSelectionStart" );
    Return Type:
    number
    Return Type Description:
    Start index of the selected text in editor.

    Gets start index of the selected text in editor.

    Code Sample

     
            $(".selector").igTextEditor("getSelectionStart");
          
  • hasFocus
    Inherited

    .igTextEditor( "hasFocus" );
    Return Type:
    bool
    Return Type Description:
    Returns if the editor is focused or not.

    Checks if editor has focus.

    Code Sample

     
            $(".selector").igTextEditor("hasFocus");
          
  • hide
    Inherited

    .igTextEditor( "hide" );

    Hides editor.

    Code Sample

     
            $(".selector").igTextEditor("hide");
          
  • hideDropDown

    .igTextEditor( "hideDropDown" );

    Hides the drop down list.

    Code Sample

     
            $(".selector").igTextEditor("hideDropDown");
          
  • inputName
    Inherited

    .igTextEditor( "inputName", [newValue:string] );
    Return Type:
    string
    Return Type Description:
    Current input name.

    Gets/Sets name attribute applied to the editor element.

    • newValue
    • Type:string
    • Optional
    • The new input name.

    Code Sample

     
            $(".selector").igTextEditor("inputName", "newName");
          
  • insert

    .igTextEditor( "insert", string:string );

    Paste text at location of caret. Note: method raises the "valueChanged" event.

    • string
    • Type:string
    • The string to be inserted.

    Code Sample

     
            $(".selector").igTextEditor("insert", "20");
          
  • isValid
    Inherited

    .igTextEditor( "isValid" );
    Return Type:
    bool
    Return Type Description:
    Whether editor value is valid or not.

    Checks if value in editor is valid. Note: This function will not trigger automatic notifications.

    Code Sample

     
            $(".selector").igTextEditor("isValid");
          
  • select

    .igTextEditor( "select", start:number, end:number );

    Selects text in editor. If parameters are equal, then than method sets location of caret. That method has effect only when editor has focus.

    • start
    • Type:number
    • Start of the selection.
    • end
    • Type:number
    • End of the selection.

    Code Sample

     
            $(".selector").igTextEditor("select", 2, 4);
          
  • selectedListIndex

    .igTextEditor( "selectedListIndex", [index:number] );
    Return Type:
    number
    Return Type Description:
    Returns the selected index.

    Gets/Sets selected list item index.

    • index
    • Type:number
    • Optional
    • The index of the item that needs to be selected.

    Code Sample

     
            $(".selector").igTextEditor("selectedListIndex", 1);
          
  • setFocus
    Inherited

    .igTextEditor( "setFocus", [delay:number] );

    Set focus to editor with delay.

    • delay
    • Type:number
    • Optional
    • The delay before focusing the editor.

    Code Sample

     
            $(".selector").igTextEditor("setFocus", 200);
          
  • show
    Inherited

    .igTextEditor( "show" );

    Shows editor.

    Code Sample

     
            $(".selector").igTextEditor("show");
          
  • showDropDown

    .igTextEditor( "showDropDown" );

    Shows the drop down list.

    Code Sample

     
            $(".selector").igTextEditor("showDropDown");
          
  • spinDown

    .igTextEditor( "spinDown" );

    Decrements hovered index in the list.

    Code Sample

     
            $(".selector").igTextEditor("spinDown");
          
  • spinDownButton

    .igTextEditor( "spinDownButton" );
    Return Type:
    jquery
    Return Type Description:
    The jQuery object representing the spin down UI element of the editor.

    Returns a reference to the spin down UI element of the editor.

    Code Sample

     
            $(".selector").igTextEditor("spinDownButton");
          
  • spinUp

    .igTextEditor( "spinUp" );

    Increments hovered index in the list.

    Code Sample

     
            $(".selector").igTextEditor("spinUp");
          
  • spinUpButton

    .igTextEditor( "spinUpButton" );
    Return Type:
    jquery
    Return Type Description:
    The jQuery object representing the spin up UI element of the editor.

    Returns a reference to the spin up UI element of the editor.

    Code Sample

     
            $(".selector").igTextEditor("spinUpButton");
          
  • validate
    Inherited

    .igTextEditor( "validate" );
    Return Type:
    bool
    Return Type Description:
    Whether editor value is valid or not.

    Triggers validation of editor and show potential warning message. If validatorOptions are set will also call validate on the igValidator.

    Code Sample

     
            $(".selector").igTextEditor("validate");
          
  • validator
    Inherited

    .igTextEditor( "validator" );
    Return Type:
    object
    Return Type Description:
    Returns reference to igValidator or null.

    Gets reference to igValidator used by the editor.

    Code Sample

     
            $(".selector").igTextEditor("validator");
          
  • value
    Inherited

    .igTextEditor( "value", newValue:object );

    • newValue
    • Type:object

    Code Sample

     
            $(".selector").igTextEditor("value", "New Text");
          
  • ui-state-active

    Class applied to the top element when editor is active. Default value is 'ui-state-active'.
  • ui-igedit-button-common ui-unselectable

    Class applied commonly to all the button containers, Default value is 'ui-igedit-button-common ui-unselectable ui-igedit-button-ltr ui-state-default'.
  • ui-igedit-buttonhover ui-state-hover

    Classes applied to the SPAN element of button in mouse-over state. Default value is 'ui-igedit-buttonhover ui-state-hover'.
  • ui-igedit-buttonpressed ui-state-highlight

    Classes applied to the SPAN element of button in pressed state. Default value is 'ui-igedit-buttonpressed ui-state-highlight'.
  • ui-igedit-cleararea ui-state-default

    Class applied to the div holding the clear button. Default value is 'ui-igedit-cleararea ui-state-default'.
  • ui-igedit-buttonimage ui-icon-circle-close

    Class applied to the div holding the clear button image. Default value is 'ui-igedit-buttonimage ui-icon-circle-close ui-icon ui-igedit-buttondefault'.
  • ui-igedit ui-igedit-container ui-widget ui-corner-all ui-state-default

    Class applied to the top element when editor is rendered in container. Default value is 'ui-igedit ui-igedit-container ui-widget ui-corner-all ui-state-default'.
  • ui-state-disabled

    Classes applied to the editing element in disabled state. Default value is 'ui-igedit-disabled ui-state-disabled'.
  • ui-igedit-dropdown-button

    Class applied to the div holding the drop down button. Default value is 'ui-igedit-dropdown-button'.
  • ui-icon ui-icon-triangle-1-s ui-igedit-buttonimage

    Class applied to the div holding the drop down button image. Default value is 'ui-icon ui-icon-carat-1-s ui-igedit-buttonimage'.
  • ui-igedit-dropdown ui-widget

    Class applied to the container holding the listitems. Default value is 'ui-igedit-dropdown'.
  • ui-igedit-input

    Class applied to the main/top element. Default value is 'ui-igedit-input'.
  • ui-igeditor-input-container ui-corner-all

    Class applied to the div which wraps the editable input (in case of multiline textarea). Default value is "ui-igeditor-input-container ui-corner-all".
  • ui-state-focus

    Class applied to the top element when editor is on focus. Default value is 'ui-state-focus'.
  • ui-state-hover

    Class applied to the top element when editor is hovered. Default value is 'ui-state-hover'.
  • ui-igedit-listitem ui-state-default

    Class applied to the SPAN element which represents item in dropdown list. Default value is 'ui-igedit-listitem ui-state-default'.
  • ui-state-active ui-igedit-listitemactive

    Class applied to the Class applied to the SPAN element which represents active item in dropdown list. Default value is 'ui-igedit-listitemselected ui-state-highlight'.
  • ui-igedit-listitemhover ui-state-hover

    Class applied to the Class applied to the SPAN element which represents item in dropdown list with mouse-over state. Default value is 'ui-igedit-listitemhover ui-state-hover'.
  • ui-igedit-listitemselected ui-state-highlight

    Class applied to the Class applied to the SPAN element which represents selected item in dropdown list. Default value is 'ui-igedit-listitemselected ui-state-highlight'.
  • ui-igedit-placeholder

    Class applied to the visible input in case of plaseHolder option set. This class is related only to the placeHolder styling. Default value is 'ui-igedit-placeholder'.
  • ui-igedit-spinlowerimage ui-icon-carat-1-s ui-icon

    Class applied to the div holding the spin down button image. Default value is 'ui-igedit-spinlowerimage ui-icon-carat-1-s ui-icon ui-igedit-buttondefault ui-igedit-spinbutton ui-igedit-buttonimage'.
  • ui-igedit-spinupperimage ui-icon-carat-1-n ui-icon

    Class applied to the div holding the spin up button image. Default value is "ui-igedit-spinupperimage ui-icon-carat-1-n ui-icon ui-igedit-buttondefault ui-igedit-spinbutton ui-igedit-buttonimage'.
  • ui-igedit-textarea

    Class applied to the visible textarea element in case of textMode set to 'multiline'.

Copyright © 1996 - 2024 Infragistics, Inc. All rights reserved.

#