Liking cljdoc? Tell your friends :D

jdk.awt.TextArea

A TextArea object is a multi-line region that displays text. It can be set to allow editing or to be read-only.

The following image shows the appearance of a text area:

This text area could be created by the following line of code:

new TextArea("Hello", 5, 40);

A TextArea object is a multi-line region
that displays text. It can be set to allow editing or
to be read-only.

The following image shows the appearance of a text area:



This text area could be created by the following line of code:



new TextArea("Hello", 5, 40);
raw docstring

*-scrollbars-bothclj

Static Constant.

Create and display both vertical and horizontal scrollbars.

type: int

Static Constant.

Create and display both vertical and horizontal scrollbars.

type: int
raw docstring

*-scrollbars-horizontal-onlyclj

Static Constant.

Create and display horizontal scrollbar only.

type: int

Static Constant.

Create and display horizontal scrollbar only.

type: int
raw docstring

*-scrollbars-noneclj

Static Constant.

Do not create or display any scrollbars for the text area.

type: int

Static Constant.

Do not create or display any scrollbars for the text area.

type: int
raw docstring

*-scrollbars-vertical-onlyclj

Static Constant.

Create and display vertical scrollbar only.

type: int

Static Constant.

Create and display vertical scrollbar only.

type: int
raw docstring

->text-areaclj

(->text-area)
(->text-area text)
(->text-area rows columns)
(->text-area text rows columns)
(->text-area text rows columns scrollbars)

Constructor.

Constructs a new text area with the specified text, and with the rows, columns, and scroll bar visibility as specified. All TextArea constructors defer to this one.

The TextArea class defines several constants that can be supplied as values for the scrollbars argument:

SCROLLBARS_BOTH, SCROLLBARS_VERTICAL_ONLY, SCROLLBARS_HORIZONTAL_ONLY, SCROLLBARS_NONE.

Any other value for the scrollbars argument is invalid and will result in this text area being created with scrollbar visibility equal to the default value of SCROLLBARS_BOTH.

text - the text to be displayed; if text is null, the empty string "" will be displayed - java.lang.String rows - the number of rows; if rows is less than 0, rows is set to 0 - int columns - the number of columns; if columns is less than 0, columns is set to 0 - int scrollbars - a constant that determines what scrollbars are created to view the text area - int

throws: java.awt.HeadlessException - if GraphicsEnvironment.isHeadless returns true

Constructor.

Constructs a new text area with the specified text,
 and with the rows, columns, and scroll bar visibility
 as specified.  All TextArea constructors defer to
 this one.

 The TextArea class defines several constants
 that can be supplied as values for the
 scrollbars argument:

 SCROLLBARS_BOTH,
 SCROLLBARS_VERTICAL_ONLY,
 SCROLLBARS_HORIZONTAL_ONLY,
 SCROLLBARS_NONE.

 Any other value for the
 scrollbars argument is invalid and will result in
 this text area being created with scrollbar visibility equal to
 the default value of SCROLLBARS_BOTH.

text - the text to be displayed; if text is null, the empty string "" will be displayed - `java.lang.String`
rows - the number of rows; if rows is less than 0, rows is set to 0 - `int`
columns - the number of columns; if columns is less than 0, columns is set to 0 - `int`
scrollbars - a constant that determines what scrollbars are created to view the text area - `int`

throws: java.awt.HeadlessException - if GraphicsEnvironment.isHeadless returns true
raw docstring

add-notifyclj

(add-notify this)

Creates the TextArea's peer. The peer allows us to modify the appearance of the TextArea without changing any of its functionality.

Creates the TextArea's peer.  The peer allows us to modify
the appearance of the TextArea without changing any of its
functionality.
raw docstring

appendclj

(append this str)

Appends the given text to the text area's current text. Note that passing null or inconsistent parameters is invalid and will result in unspecified behavior.

str - the non-null text to append - java.lang.String

Appends the given text to the text area's current text.
 Note that passing null or inconsistent
 parameters is invalid and will result in unspecified
 behavior.

str - the non-null text to append - `java.lang.String`
raw docstring

append-textclj

(append-text this str)

Deprecated. As of JDK version 1.1, replaced by append(String).

str - java.lang.String

Deprecated. As of JDK version 1.1,
 replaced by append(String).

str - `java.lang.String`
raw docstring

get-accessible-contextclj

(get-accessible-context this)

Returns the AccessibleContext associated with this TextArea. For text areas, the AccessibleContext takes the form of an AccessibleAWTTextArea. A new AccessibleAWTTextArea instance is created if necessary.

returns: an AccessibleAWTTextArea that serves as the AccessibleContext of this TextArea - javax.accessibility.AccessibleContext

Returns the AccessibleContext associated with
 this TextArea. For text areas, the
 AccessibleContext takes the form of an
 AccessibleAWTTextArea.
 A new AccessibleAWTTextArea instance is created if necessary.

returns: an AccessibleAWTTextArea that serves as the
         AccessibleContext of this TextArea - `javax.accessibility.AccessibleContext`
raw docstring

get-columnsclj

(get-columns this)

Returns the number of columns in this text area.

returns: the number of columns in the text area - int

Returns the number of columns in this text area.

returns: the number of columns in the text area - `int`
raw docstring

get-minimum-sizeclj

(get-minimum-size this)
(get-minimum-size this rows columns)

Determines the minimum size of a text area with the specified number of rows and columns.

rows - the number of rows - int columns - the number of columns - int

returns: the minimum dimensions required to display the text area with the specified number of rows and columns - java.awt.Dimension

Determines the minimum size of a text area with the specified
 number of rows and columns.

rows - the number of rows - `int`
columns - the number of columns - `int`

returns: the minimum dimensions required to display
                       the text area with the specified
                       number of rows and columns - `java.awt.Dimension`
raw docstring

get-preferred-sizeclj

(get-preferred-size this)
(get-preferred-size this rows columns)

Determines the preferred size of a text area with the specified number of rows and columns.

rows - the number of rows - int columns - the number of columns - int

returns: the preferred dimensions required to display the text area with the specified number of rows and columns - java.awt.Dimension

Determines the preferred size of a text area with the specified
 number of rows and columns.

rows - the number of rows - `int`
columns - the number of columns - `int`

returns: the preferred dimensions required to display
                       the text area with the specified
                       number of rows and columns - `java.awt.Dimension`
raw docstring

get-rowsclj

(get-rows this)

Returns the number of rows in the text area.

returns: the number of rows in the text area - int

Returns the number of rows in the text area.

returns: the number of rows in the text area - `int`
raw docstring

get-scrollbar-visibilityclj

(get-scrollbar-visibility this)

Returns an enumerated value that indicates which scroll bars the text area uses.

The TextArea class defines four integer constants that are used to specify which scroll bars are available. TextArea has one constructor that gives the application discretion over scroll bars.

returns: an integer that indicates which scroll bars are used - int

Returns an enumerated value that indicates which scroll bars
 the text area uses.

 The TextArea class defines four integer constants
 that are used to specify which scroll bars are available.
 TextArea has one constructor that gives the
 application discretion over scroll bars.

returns: an integer that indicates which scroll bars are used - `int`
raw docstring

insertclj

(insert this str pos)

Inserts the specified text at the specified position in this text area. Note that passing null or inconsistent parameters is invalid and will result in unspecified behavior.

str - the non-null text to insert - java.lang.String pos - the position at which to insert - int

Inserts the specified text at the specified position
 in this text area.
 Note that passing null or inconsistent
 parameters is invalid and will result in unspecified
 behavior.

str - the non-null text to insert - `java.lang.String`
pos - the position at which to insert - `int`
raw docstring

insert-textclj

(insert-text this str pos)

Deprecated. As of JDK version 1.1, replaced by insert(String, int).

str - java.lang.String pos - int

Deprecated. As of JDK version 1.1,
 replaced by insert(String, int).

str - `java.lang.String`
pos - `int`
raw docstring

minimum-sizeclj

(minimum-size this)
(minimum-size this rows columns)

Deprecated. As of JDK version 1.1, replaced by getMinimumSize(int, int).

rows - int columns - int

returns: java.awt.Dimension

Deprecated. As of JDK version 1.1,
 replaced by getMinimumSize(int, int).

rows - `int`
columns - `int`

returns: `java.awt.Dimension`
raw docstring

preferred-sizeclj

(preferred-size this)
(preferred-size this rows columns)

Deprecated. As of JDK version 1.1, replaced by getPreferredSize(int, int).

rows - int columns - int

returns: java.awt.Dimension

Deprecated. As of JDK version 1.1,
 replaced by getPreferredSize(int, int).

rows - `int`
columns - `int`

returns: `java.awt.Dimension`
raw docstring

replace-rangeclj

(replace-range this str start end)

Replaces text between the indicated start and end positions with the specified replacement text. The text at the end position will not be replaced. The text at the start position will be replaced (unless the start position is the same as the end position). The text position is zero-based. The inserted substring may be of a different length than the text it replaces. Note that passing null or inconsistent parameters is invalid and will result in unspecified behavior.

str - the non-null text to use as the replacement - java.lang.String start - the start position - int end - the end position - int

Replaces text between the indicated start and end positions
 with the specified replacement text.  The text at the end
 position will not be replaced.  The text at the start
 position will be replaced (unless the start position is the
 same as the end position).
 The text position is zero-based.  The inserted substring may be
 of a different length than the text it replaces.
 Note that passing null or inconsistent
 parameters is invalid and will result in unspecified
 behavior.

str - the non-null text to use as the replacement - `java.lang.String`
start - the start position - `int`
end - the end position - `int`
raw docstring

replace-textclj

(replace-text this str start end)

Deprecated. As of JDK version 1.1, replaced by replaceRange(String, int, int).

str - java.lang.String start - int end - int

Deprecated. As of JDK version 1.1,
 replaced by replaceRange(String, int, int).

str - `java.lang.String`
start - `int`
end - `int`
raw docstring

set-columnsclj

(set-columns this columns)

Sets the number of columns for this text area.

columns - the number of columns - int

throws: java.lang.IllegalArgumentException - if the value supplied for columns is less than 0

Sets the number of columns for this text area.

columns - the number of columns - `int`

throws: java.lang.IllegalArgumentException - if the value supplied for columns is less than 0
raw docstring

set-rowsclj

(set-rows this rows)

Sets the number of rows for this text area.

rows - the number of rows - int

throws: java.lang.IllegalArgumentException - if the value supplied for rows is less than 0

Sets the number of rows for this text area.

rows - the number of rows - `int`

throws: java.lang.IllegalArgumentException - if the value supplied for rows is less than 0
raw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close