Guide¶
The guide covers all aspects of textual-wtf in depth. Work through it in order, or jump to the section that interests you most.
Sections¶
-
Learn how to declare form classes, set class-level defaults such as
label_styleandrequired, and useget_data()/set_data()to move data in and out of a form instance. -
Every built-in field type explained with examples. Then the full set of built-in validators, how to write an inline
FunctionValidator, and how to subclassValidatorfor reusable logic. -
Three rendering modes —
layout(),simple_layout(), and the rawbf()call. All threelabel_styleoptions and bothhelp_styleoptions. Custom layouts by subclassingFormLayout. -
Assign a
Forminstance as a class attribute to embed its fields with a name prefix. Controlrequiredstate independently for each embedding. -
When validators fire, how to run validation manually, and how to add cross-field errors with
clean_form()andadd_error(). -
TabbedFormrenders multiple forms as tabs. Tab labels turn red when a field in that tab has an error.