FileDocCategorySizeDatePackage
TextFieldLF.javaAPI DocphoneME MR2 API (J2ME)3395Wed May 02 18:00:22 BST 2007javax.microedition.lcdui

TextFieldLF

public interface TextFieldLF implements ItemLF
Look and Feel interface used by TextField.

See Naming Conventions for information about method naming conventions.

Fields Summary
Constructors Summary
Methods Summary
public voiditemDeleted()
Notifies item that it has been recently deleted

public voidlDelete(int offset, int length)
Notifies L&F of character deletion in the corresponding TextField.

param
offset the beginning of the deleted region
param
length the number of characters deleted

public intlGetCaretPosition()
Gets the current input position.

return
the current caret position, 0 if at the beginning

public voidlInsert(char[] data, int offset, int length, int position)
Notifies L&F of a character insertion in the corresponding TextField.

param
data the source of the character data
param
offset the beginning of the region of characters copied
param
length the number of characters copied
param
position the position at which insertion occurred

public voidlSetChars()
Notifies L&F of a content change in the corresponding TextField.

public voidlSetConstraints()
Notifies L&F that constraints have to be changed.

public voidlSetInitialInputMode(java.lang.String characterSubset)
Notifies L&F that preferred initial input mode was changed.

param
characterSubset a string naming a Unicode character subset, or null

public voidlSetMaxSize(int maxSize)
Notifies L&F of a maximum size change in the corresponding TextField.

param
maxSize - the new maximum size

public booleanlUpdateContents()
Update the character buffer in TextField with latest user input.

return
true if there is new user input updated in the buffer

public booleanlValidate(com.sun.midp.lcdui.DynamicCharacterArray buffer, int constraints)
Validate a given character array against a constraints.

param
buffer a character array
param
constraints text input constraints
return
true if constraints is met by the character array