SoilWise Geopackage

Customized Attribute Forms in QGIS

In QGIS, customized attribute forms allow full control over the layout and behavior of the user interface used for viewing, inserting, and editing attribute data.
Instead of relying on automatically generated forms, a clearer and more structured layout has been defined, enabling precise control over which fields are displayed, how they are grouped, and under which conditions they are visible.

Each field has been associated with a specific widget, i.e., a control designed to facilitate data entry and reduce user errors.

Available Widgets

The main widget types used include:

  • Text Edit– free‑text input
  • Checkbox– boolean values
  • Date/Time– date and time selection
  • Value Map / Value Relation – predefined lists of values (fixed or derived from another table)
  • Relation Reference / Relation Editor– handling one‑to‑many or many‑to‑many table relationships
  • HTML / Text / Spacer– support elements for notes, layout structure, or separators

These widgets allow the form to guide the user and enforce the data‑entry rules defined in the underlying data model.

Important

When the Relation Reference widget contains a large number of entries, it is possible to quickly filter the list by typing one or more letters into the text input field. The list is automatically filtered in real time based on the entered characters, allowing faster and easier selection of the desired item.

Purpose of Customized Forms

Customized forms are used to:

  • guide the user through data entry with a clear and structured layout
  • apply constraints, conditional visibility, and default values
  • ensure consistency with the data model
  • display enriched information (images, documents, related records)

Important

The goal is to provide a functional interface, more efficient and clearer than the default one, particularly suitable for complex datasets.

Interface Elements Related to Forms

Fig.1 On the left side of the interface, a panel ① lists all the records belonging to the layer. Selecting a record from this list displays its attribute content on the right-hand side ②, using the associated customized form.

The attribute toolbar provides two main viewing modes ③:

Form View Displays the attribute form for a single record at a time.
Table View Shows the attributes in tabular mode, useful for multi-record inspection and quick selection operations.

Selection tools ④ ⑤ determine which records can be opened or edited through the form.



Note

Selection is an essential part of the editing workflow, as it controls which records are loaded into the form.

Tooltip

Fig.1 These tooltips provide concise, context‑specific descriptions ① of the attributes when the user hovers over their labels. They offer additional clarification on the fields’ purpose and meaning within the form, helping users correctly interpret the data without leaving the editing interface.



Tip

For more details, refer to the official QGIS documentation