Switch to: V10V9V8V7V6V5

Form Editor - LineEdit - Field Help

Form Editor - LineEdit - Field

The LineEdit - Field control is a one-line text editor.

A line edit allows the user to enter and edit a single line of plain text with a useful collection of editing functions, including undo and redo, cut and paste, and drag and drop.

This control is bound to the table field and allows the user to edit its value. The names of these table and field are shown inside of the control in the design mode. The current value of the line edit is taken right from the field and each change is applied immediately to the field.

Properties

Form Editor - LineEdit - Field Properties

  • Data Mode – Defines how the control value change is applied to the field:
    • Inherited – The mode is inherited from the parent form
    • Add – The value is intended for a new record
    • Edit – The value is assigned to the field, but not committed
    • Edit And Commit – The value is assigned to the field and committed
    • ReadOnly – The value can't be changed
    • Filter – The value is used to filter data by the bound field, the filter must be applied manually using the applyFilters method.
    • Filter And Accept – The value is used to filter data by the bound field, filter applied automatically.
  • Name – The name of the control.
  • Field – The bound field.
  • Items – The list of items to choose from.
  • Read Only – Defines whether the control is editable or not.

Widget

  • Auto Fill Background – This property holds whether the control background is filled automatically.
  • Enabled – Defines whether the control is enabled or not.
  • Font – This property holds the font currently set for the control. The default depends on the system environment.
  • Palette – This property describes the control's palette.

The palette is used by the control's style when rendering. The color roles from this palette are combined with the control's default palette to form the control's final palette. The default depends on the system environment and may be different on different platforms. Control propagates explicit palette roles from parent to child. If you assign a brush or color to a specific role on a palette, that role will propagate to all the control's children, overriding any system defaults for that role.

  • Tooltip – The tooltip text.

Layout Item

  • Alignment – Defines both the horizontal and vertical alignment.
  • Expand Horizontal – If ON the control is expanded horizontally.
  • Expand Vertical – If ON the control is expanded vertically.

Size

  • Width – The width of the control.
  • Height – The height of the control (Disabled).

Signals

Form Editor - LineEdit - Field Signals

QLineEdit

  • cursorPositionChanged( oldPos, newPos ) – This signal is emitted whenever the cursor moves. The previous position is given by oldPos, and the new position by newPos.
  • editingFinished – This signal is emitted when the Return or Enter key is pressed or the line edit loses focus.
  • returnPressed – This signal is emitted when the Return or Enter key is pressed.
  • textChanged( text ) – This signal is emitted whenever the text changes. The first argument is the new text. Unlike textEdited, this signal is also emitted when the text is changed programmatically. The text argument is the new text.
  • textEdited( text ) – This signal is emitted whenever the text is edited. The text argument is the new text. Unlike textChanged, this signal is not emitted when the text is changed programmatically. The text argument is the new text.

QWidget

  • customMenuRequested – This signal is emitted when the user has requested a context menu on the control.
  • windowIconChanged – This signal is emitted when the window's icon has changed.
  • windowTitleChanged( title ) – This signal is emitted when the window's title has changed, with the new title as an argument.

QObject

  • created – This signal is emitted after the object is created.
  • destroyed – This signal is emitted immediately before the object is destroyed, and can not be blocked. All the objects's children are destroyed immediately after this signal is emitted.
  • needUpdate – This signal is emitted when the control needs to be updated, for example, on the change of the current record.
  • objectNameChanged( objectName ) – This signal is emitted after the object's name has been changed, with the new object name passed as an argument.