Hoogle Search

Within LTS Haskell 24.51 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. module Brick.Forms

    Note - this API is designed to support a narrow (but common!) set of use cases. If you find that you need more customization than this offers, then you will need to consider building your own layout and event handling for input fields. For a fuller introduction to this API, see the "Input Forms" section of the Brick User Guide. Also see the demonstration programs for examples of forms in action. This module provides an input form API. This API allows you to construct an input interface based on a data type of your choice. Each input in the form corresponds to a field in your data type. This API then automatically dispatches keyboard and mouse input events to each form input field, manages rendering of the form, notifies the user when a form field's value is invalid, and stores valid inputs in your data type when possible. A form has both a visual representation and a corresponding data structure representing the latest valid values for that form (referred to as the "state" of the form). A FormField is a single input component in the form and a FormFieldState defines the linkage between that visual input and the corresponding portion of the state represented by that visual; there may be multiple FormFields combined for a single FormFieldState (e.g. a radio button sequence). To use a Form, you must include it within your application state type. You can use formState to access the underlying state whenever you need it. See programs/FormDemo.hs for a complete working example. Also note that, by default, forms and their field inputs are concatenated together in a vBox. This can be customized on a per-field basis and for the entire form by using the functions setFieldConcat and setFormConcat, respectively. Bear in mind that for most uses, the FormField and FormFieldState types will not be used directly. Instead, the constructors for various field types (such as editTextField) will be used instead.

  2. data Form s e n

    brick Brick.Forms

    A form: a sequence of input fields that manipulate the fields of an underlying state that you choose. This value must be stored in the Brick application's state. Type variables are as follows:

    • s - the data type of your choosing containing the values manipulated by the fields in this form.
    • e - your application's event type
    • n - your application's resource name type

  3. data FormField a b e n

    brick Brick.Forms

    A form field. This represents an interactive input field in the form. Its user input is validated and thus converted into a type of your choosing. Type variables are as follows:

    • a - the type of the field in your form state that this field manipulates
    • b - the form field's internal state type
    • e - your application's event type
    • n - your application's resource name type

  4. FormField :: n -> (b -> Maybe a) -> Bool -> (Bool -> b -> Widget n) -> (BrickEvent n e -> EventM n b ()) -> FormField a b e n

    brick Brick.Forms

    No documentation available.

  5. data FormFieldState s e n

    brick Brick.Forms

    A form field state accompanied by the fields that manipulate that state. The idea is that some record field in your form state has one or more form fields that manipulate that value. This data type maps that state field (using a lens into your state) to the form input fields responsible for managing that state field, along with a current value for that state field and an optional function to control how the form inputs are rendered. Most form fields will just have one input, such as text editors, but others, such as radio button collections, will have many, which is why this type supports more than one input corresponding to a state field. Type variables are as follows:

    • s - the data type containing the value manipulated by these form fields.
    • e - your application's event type
    • n - your application's resource name type

  6. FormFieldState :: forall b s a e n . b -> Lens' s a -> (a -> b -> b) -> [FormField a b e n] -> (Widget n -> Widget n) -> ([Widget n] -> Widget n) -> FormFieldVisibilityMode -> FormFieldState s e n

    brick Brick.Forms

    No documentation available.

  7. data FormFieldVisibilityMode

    brick Brick.Forms

    How to bring form fields into view when a form is rendered in a viewport with viewport.

  8. ForShare :: LockingKind

    esqueleto Database.Esqueleto

    Deprecated: The constructors for LockingKind are deprecated in v3.6.0.0. Instead, please refer to the smart constructor forShare exported from Database.Esqueleto.PostgreSQL.

  9. ForUpdate :: LockingKind

    esqueleto Database.Esqueleto

    Deprecated: The constructors for LockingKind are deprecated in v3.6.0.0. Instead, please refer to the smart constructors forUpdate and forUpdateSkipLocked.

  10. ForUpdateSkipLocked :: LockingKind

    esqueleto Database.Esqueleto

    Deprecated: The constructors for LockingKind are deprecated in v3.6.0.0. Instead, please refer to the smart constructors forUpdate and forUpdateSkipLocked.

Page 285 of many | Previous | Next