“Universal” Widgets

Introduction

Short Text Widget

Type:

Value:

Behavior:

HTML:

Emacs:

(read-string "Name :")

CLI (Prompting):

Examples:

Links:

Long Text Widget

Type:

Value:

Behavior:

HTML:

Emacs:

(read-buffer? "Text :")

CLI (Completion):

Examples:

Links:

Secret Text Widget

i.e. Password Input.

Type:

Value:

Behavior:

HTML:

Emacs:

(read-passwors "Password :") TODO

CLI (Prompting):

Examples:

Links:

Choices Widget

i.e. a Checklist.

Type:

Value:

Behavior:

HTML:

Emacs (Minibuffer):

(TODO)

Emacs (Widget):

(widget-create)

Examples:

Links:

Choice Widget (for few choices)

i.e. a Radio-Group.

Type:

Value:

Behavior:

HTML:

Emacs:

(read-choice-

CLI (Prompting):

Examples:

Links:

Choice Widget (for many choices)

i.e. a “Finite-List”.

Type:

Value:

Behavior:

HTML:

Emacs:

(let ((CHOICES '(
  "Google Chrome"
  "Firefox"
  "Internet Explorer"
  "Opera"
  "Safari"
  "Microsoft Edge"
  )))

 (completing-read "Browser: " CHOICES))

CLI (Completion):

Representation (must match):

Representation (free text):

Examples:

Links:

File Widget

i.e. a File-Chooser.

Type:

Value:

Behavior:

HTML:

read-file-name (Emacs): (read-file-name PROMPT &optional DIR DEFAULT-FILENAME MUSTMATCH INITIAL PREDICATE)(a.k.a C-x C-f)

(read-file-name "Open File: " default-directory nil t)
(read-file-name "Open Directory: " )
(read-file-name "New File: " )
(defun sboo-elisp-filename-p (filename)
  (match filename (rx ".el" eos))) ;TODO

  (read-file-name "Open File: " default-directory nil nil nil #'sboo-elisp-filename-p))

CLI (Completion):

Examples:

Links:

Conclusion