BBjCEdit
Description
In BBj 5.00 and higher, the BBjCEdit object provides methods for manipulating a GUI CEdit control.
Implemented Interfaces
DragSource, DropTarget, Editable, Focusable, MouseWheelEnabled, RecordSetBindable,Scrollable.SimpleRecordSetBindable,TabTraversable,TextControl,Validateable,
Creation
BBjAPI > BBjSysGui > BBjWindow > BBjCEdit
A BBjCEdit object is created through the following BBjWindow methods:
Return Value |
Method |
---|---|
BBjCEdit |
addCEdit(int ID, number x, number y, number w, number h, string title) |
BBjCEdit |
addCEdit(int ID, number x, number y, number w, number h, string title, string flags) |
BBjCEdit |
addCEdit(int ID, string title) |
BBjCEdit |
addCEdit(int ID, string title, String flags) |
BBjCEdit |
addCEdit(string title) |
BBjCEdit |
addCEdit(string title, String flags) |
Methods of BBjCEdit
Return Value |
Method |
---|---|
void |
addParagraph(int index, string paragraph) |
void |
addParagraphs(int index, BBjVector paragraphs!) |
void |
appendToParagraph(int parNum, string text) |
int | getCurrentParagraphIndex() |
boolean |
|
boolean |
|
boolean |
|
boolean |
|
boolean |
|
int |
|
boolean |
|
int |
|
int |
|
int |
|
boolean |
|
string |
getParagraph(int parNum) |
int |
|
boolean |
|
boolean |
|
void |
highlight(int parIndex1, int off1, int parIndex2, int off2) |
boolean |
|
void |
|
void |
removeParagraph(int parIndex) |
void |
setDrawBorder(boolean draw) |
void |
setEditable(boolean editable) |
void |
setHorizontalScrollable(boolean scroll) |
void |
setIgnoreEnters(boolean ignore) |
void |
setIgnoreTabs(boolean ignore) |
void |
setLimitToOneParagraph(boolean limit) |
void |
setLineCountLimit(int limit) |
void |
setLineWrap(boolean wrap) |
void |
setMaxParagraphSize(int size) |
void |
setMaxLength(int length) |
void |
setOvertypeMode(boolean overtype) |
void |
setTabSize(int size) |
void |
setVerticalScrollable(boolean scroll) |
void |
setWrapStyleWord(boolean word) |
Methods of BBjCEdit implemented for DragSource
Return Value | Method |
---|---|
int | getDragActions() |
string | getDragType() |
void | setDragActions(int actions) |
void | setDragType(string type) |
Methods of BBjCEdit implemented for DropTarget
Return Value | Method |
---|---|
int | getDropActions() |
void | setDropActions(int actions) |
BBjVector | getDropTypes() |
void | setDropTypes(BBjVector types) |
Methods of BBjCEdit implemented for Editable
Return Value | Method |
---|---|
boolean | isEditable() |
void | setEditable(boolean edit) |
Methods of BBjCEdit implemented for Focusable
Return Value | Method |
---|---|
boolean | isFocusable() |
void | setFocusable(boolean focus) |
Methods of BBjCEdit implemented for RecordSetBindable
Return Value | Method |
---|---|
void | bindRecordSet(BBjRecordSet recordset!, string fieldname) |
string | getBoundFieldName() |
Methods of BBjCEdit implemented for Scrollable
Return Value | Method |
---|---|
int | getHorizontalScrollBarHeight() |
int | getHorizontalScrollBarPosition() |
int | getHorizontalScrollBarWidth() |
int | getVerticalScrollBarHeight() |
int | getVerticalScrollBarPosition() |
int | getVerticalScrollBarWidth() |
boolean | isHorizontalScrollBarVisible() |
boolean | isVerticalScrollBarVisible() |
void | setHorizontalScrollBarPosition(int position) |
void | setVerticalScrollBarPosition(int position) |
Methods of BBjCEdit implemented SimpleRecordSetBindable
Return Value | Method |
---|---|
BBjRecordSet | getBoundRecordSet() |
void | unbindRecordSet() |
Methods of BBjCEdit implemented for TabTraversable
Return Value | Method |
---|---|
boolean | isTabTraversable() |
void | setTabTraversable(boolean trav) |
Methods of BBjCEdit implemented for TextControl
Methods of BBjCEdit implemented for MouseWheelEnabled
Return Value | Method |
---|---|
int | getScrollWheelBehavior() |
void | setScrollWheelBehavior(int trav) |
Methods of BBjCEdit implemented for Validateable
Return Value | Method |
---|---|
void | accept(boolean valid) |
string | getValidationText() |
Methods of BBjButton inherited from BBjControl
Events
Callback Code |
Object-oriented Event |
Read Record Event |
Code |
---|---|---|---|
ON_CONTROL_SCROLL |
p | ||
ON_CONTROL_VALIDATION |
v |
||
ON_DROP_TARGET_DROP |
D |
||
ON_EDIT_KEYPRESS (BBj 24.10 and higher) | BBjEditKeypressEvent | Edit Control Notify | N (notify code 1) |
ON_EDIT_MODIFY |
e |
||
ON_GAINED_FOCUS |
f |
||
ON_LOST_FOCUS |
f |
||
ON_MOUSE_ENTER |
E |
||
ON_MOUSE_EXIT |
E |
||
ON_POPUP_REQUEST |
r |
||
ON_RIGHT_MOUSE_DOWN |
R |
CSS
The visual appearance of BUI controls is defined using CSS (cascading style sheets) rules. Easily change the default colors, border, and other settings by customizing these rules, all without changing any application code. See CSS API for a high-level overview of BUI CSS.
The BBjCEdit is implemented as a <textarea> element. It defines the following styles:
.BBjCEdit
.BBjCEdit.bbj-bordered
.BBjCEdit.bbj-disabled
.BBjCEdit.bbj-focused
.BBjCEdit.bbj-readonly
To modify the optional border:
|
By default, the BUI BBjCEdit is not user-resizable because resizing it can conflict with other controls on the page. That option can be added like this:
|
Remarks
In BBj 10 and higher, the BBjCEdit honors the documented $0004$ flag ("Draws a border around the control"). This flag was previously ignored in BBj, so some applications didn't set it, even if they wanted borders. Set the CEDIT_BORDER !COMPAT setting to TRUE to show borders around all CEDIT controls, regardless of the state of the $0004$ flag.
Constants inherited from BBjControl
Example
|
Version History
See Also
CEDIT Mnemonic - Create Multi-Line Text Edit Control
CALLBACK Verb - Register BBj Subroutine
DWC Component: dwc-textarea
See the BBj Object Diagram for an illustration of the relationship between BBj Objects.