YadGui 14.0

Yet Another Dialog

Program allows you to display GTK+ dialog boxes from command line or shell scripts. YAD depends on GTK+ only. Minimal GTK+ version is 3.22.0

This software is licensed under the GPL v.3

Project homepage: https://github.com/v1cont/yad
Complex examples: https://github.com/v1cont/yad/wiki/YAD-Examples
Mailing list: http://groups.google.com/group/yad-common

Some miscellaneous stuff can be found in data/misc directory including notify-send script and simple zenity-compatible wrapper

A fresh gtk2 branch of YAD can be obtained from this repository - https://github.com/step-/yad

Building git version

Get git version with command

git clone https://github.com/v1cont/yad.git yad-dialog-code

Before run the standard ./configure && make && make install procedure you need to generate build scripts. This can be done by running command

autoreconf -ivf && intltoolize

You must manually run gtk-update-icon-cache after installation.

For successfully build you may need to install the following packages:

Additionally, you can build yad with the following libraries:

In standalone build (configure option --enable-standalone) some defaults can be redefined with the following defines

BORDERS - set the default border width around dialog. Default is 5
REMAIN - if defined, timeout indicator will show the remaining time
COMBO_EDIT - if defined, combo-box in entry dialog will be always editable
TERM_CMD - string with terminal command. Default is "xterm -e '%s'"
OPEN_CMD - string with open command. Default is "xdg-open '%s'"
DATE_FMT - string with date output format. Default is "%x". See strftime(3) for details
URI_COLOR - color for URIs in text-info dialog. Default is blue
MARK1_COLOR - color for first type of text marks in text-info dialog. Default is lightgreen
MARK2_COLOR - color for second type of text marks in text-info dialog. Default is pink
MAX_TABS - set the number of tabs for tabbed dialog. Default is 100

Defines can be added througs CFLAGS environment variable

Comments

NoticeLog in

Your need to be logged in to be able to comment.

    • Admin Yadbash

      Help Options:
       -h, --help                                     Show help options
       --help-all                                     Show all help options
       --help-general                                 Show general options
       --help-common                                  Show common options
       --help-about                                   Show custom about dialog options
       --help-app                                     Show application selection options
       --help-calendar                                Show calendar options
       --help-color                                   Show color selection options
       --help-dnd                                     Show drag-n-drop options https://yadbash.com/yad-dnd
       --help-entry                                   Show text entry options
       --help-file                                    Show file selection options
       --help-font                                    Show font selection options
       --help-form                                    Show form options
       --help-html                                    Show HTML options https://yadbash.com/yad-html
       --help-icons                                   Show icons box options
       --help-list                                    Show list options
       --help-notebook                                Show notebook dialog options
       --help-notification                            Show notification icon options
       --help-paned                                   Show paned dialog options
       --help-picture                                 Show picture dialog options
       --help-print                                   Show print dialog options
       --help-progress                                Show progress options
       --help-scale                                   Show scale options
       --help-text                                    Show text information options
       --help-source                                  Show SourceView options
       --help-filter                                  Show file filter options
       --help-misc                                    Show miscellaneous options
       --help-gtk                                     Show GTK+ Options

      General options
       --title=TITLE                                  Set the dialog title
       --window-icon=ICONPATH                         Set the window icon
       --width=WIDTH                                  Set the window width
       --height=HEIGHT                                Set the window height
       --posx=NUMBER                                  Set the X position of a window
       --posy=NUMBER                                  Set the Y position of a window
       --geometry=WxH+X+Y                             Set the window geometry
       --timeout=TIMEOUT                              Set dialog timeout in seconds
       --timeout-indicator=POS                        Show remaining time indicator (top, bottom, left, right)
       --text=TEXT                                    Set the dialog text
       --text-width=NUMBER                            Set the dialog text width in characters
       --text-align=TYPE                              Set the dialog text alignment (left, center, right, fill)
       --image=IMAGE                                  Set the dialog image
       --icon-theme=THEME                             Use specified icon theme instead of default
       --expander=[TEXT]                              Hide main widget with expander
       --button=NAME:ID                               Add dialog button (may be used multiple times)
       --no-buttons                                   Don't show buttons
       --buttons-layout=TYPE                          Set buttons layout type (spread, edge, start, end or center)
       --no-markup                                    Don't use pango markup language in dialog's text
       --no-escape                                    Don't close dialog if Escape was pressed
       --escape-ok                                    Escape acts like OK button
       --borders=NUMBER                               Set window borders
       --always-print-result                          Always print result
       --response=NUMBER                              Set default return code
       --selectable-labels                            Dialog text can be selected
       --keep-icon-size                               Don't scale icons
       --use-interp=CMD                               Run commands under specified interpreter (default: bash -c '%s')
       --uri-handler=CMD                              Set URI handler
       --f1-action=CMD                                Set command running when F1 was pressed
       --workdir=PATH                                 Set working directory
       --sticky                                       Set window sticky
       --fixed                                        Set window unresizable
       --on-top                                       Place window on top
       --center                                       Place window on center of screen
       --mouse                                        Place window at the mouse position
       --undecorated                                  Set window undecorated
       --skip-taskbar                                 Don't show window in taskbar
       --maximized                                    Set window maximized
       --fullscreen                                   Set window fullscreen
       --no-focus                                     Don't focus dialog window
       --close-on-unfocus                             Close window when it sets unfocused
       --splash                                       Open window as a splashscreen (Deprecated, see man page for details)
       --window-type=TYPE                             Specify the window type for the dialog
       --plug=KEY                                     Special type of dialog for XEMBED
       --tabnum=NUMBER                                Tab number of this dialog
       --kill-parent=[SIGNAL]                         Send SIGNAL to parent
       --print-xid=[FILENAME]                         Print X Window Id to the file/stderr

      Common options
       --date-format=PATTERN                          Set the format for the returned date
       --float-precision=NUMBER                       Set presicion of floating numbers (default - 3)
       --command=CMD                                  Set command handler
       --listen                                       Listen for data on stdin
       --separator=SEPARATOR                          Set common separator character
       --item-separator=SEPARATOR                     Set item separator character
       --editable                                     Allow changes to text in some cases
       --tail                                         Autoscroll to end of text
       --auto-scroll                                  Autoscroll to end of text (alias to tail)
       --quoted-output                                Quote dialogs output
       --num-output                                   Output number instead of text for combo-box
       --fontname=FONTNAME                            Specify font name to use
       --multiple                                     Allow multiple selection
       --add-preview                                  Enable preview
       --large-preview                                Use large preview
       --show-hidden                                  Show hidden files in file selection dialogs
       --filename=FILENAME                            Set source filename
       --mime=TYPE                                    Set mime type of input data
       --vertical                                     Set vertical orientation
       --key=KEY                                      Identifier of embedded dialogs
       --complete=TYPE                                Set extended completion for entries (any, all, or regex)
       --bool-fmt=TYPE                                Set type of output for boolean values (T, t, Y, y, O, o, 1)
       --scroll                                       Make main widget scrollable
       --disable-search                               Disable search in text and html dialogs
       --file-op                                      Enable file operations
       --iec-format                                   Use IEC (base 1024) units with for size values

      About dialog options
       --pname=STRING                                 Set application name
       --pversion=STRING                              Set application version
       --copyright=STRING                             Set application copyright string
       --comments=TEXT                                Set application comments string
       --license=TEXT                                 Set application license
       --authors=LIST                                 Set application authors
       --website=URI                                  Set application website
       --website-label=STRING                         Set application website label

      Application selection options
       --enable-fallback                              Show fallback applications
       --enable-other                                 Show other applications
       --enable-all                                   Show all applications
       --extended                                     Output all application data

      Calendar options
       --day=DAY                                      Set the calendar day
       --month=MONTH                                  Set the calendar month
       --year=YEAR                                    Set the calendar year
       --details=FILENAME                             Set the filename with dates details
       --show-weeks                                   Show week numbers at the left side of calendar

      Color selection options
       --init-color=COLOR                             Set initial color value
       --gtk-palette                                  Show system palette in color dialog
       --palette=[FILENAME]                           Set path to palette file. Default - /etc/X11/rgb.txt
       --expand-palette                               Expand user palette
       --picker                                       Show color picker
       --mode=MODE                                    Set output mode to MODE. Values are hex (default) or rgb
       --alpha                                        Add opacity to output color value

      DND options   https://yadbash.com/yad-dnd
       --tooltip                                      Use dialog text as tooltip
       --exit-on-drop=NUMBER                          Exit after NUMBER of drops

      Text entry options
       --entry-label=TEXT                             Set the entry label
       --entry-text=TEXT                              Set the entry text
       --hide-text                                    Hide the entry text
       --completion                                   Use completion instead of combo-box
       --numeric                                      Use spin button for text entry
       --licon=IMAGE                                  Set the left entry icon
       --licon-action=CMD                             Set the left entry icon action
       --ricon=IMAGE                                  Set the right entry icon
       --ricon-action=CMD                             Set the right entry icon action

      File selection options
       --directory                                    Activate directory-only selection
       --save                                         Activate save mode
       --confirm-overwrite=[TEXT]                     Confirm file selection if filename already exists

      Font selection options
       --preview=TEXT                                 Set text string for preview
       --separate-output                              Separate output of font description

      Form options
       --field=LABEL[:TYPE]                           Add field to form (see man page for list of possible types)
       --align=TYPE                                   Set alignment of filed labels (left, center or right)
       --columns=NUMBER                               Set number of columns in form
       --homogeneous                                  Make form fields height and columns width the same size
       --output-by-row                                Order output fields by rows
       --focus-field=NUMBER                           Set focused field
       --cycle-read                                   Cycled reading of stdin data
       --align-buttons                                Align labels on button fields
       --changed-action=CMD                           Set changed action

      HTML options https://yadbash.com/yad-html
       --uri=URI                                      Open specified location
       --browser                                      Turn on browser mode
       --print-uri                                    Print clicked uri to stdout
       --encoding=ENCODING                            Set encoding of input stream data
       --user-agent=STRING                            Set user agent string
       --user-style=STRING                            Set custom user style
       --wk-prop=PROP                                 Set WebKit property

      Icons box options
       --read-dir=DIR                                 Read data from .desktop files in specified directory
       --compact                                      Use compact (list) view
       --generic                                      Use GenericName field instead of Name for icon label
       --item-width                                   Set the width of dialog items
       --icon-size=SIZE                               Force using specified icon size
       --term=PATTERN                                 Use specified pattern for launch command in terminal (default: xterm -e %s)
       --sort-by-name                                 Sort items by name instead of filename
       --descend                                      Sort items in descending order
       --single-click                                 Activate items by single click
       --monitor                                      Watch fot changes in directory

      List options
       --column=COLUMN[:TYPE]                         Set the column header (see man page for list of possible types)
       --tree                                         Enbale tree mode
       --checklist                                    Use checkboxes for first column
       --radiolist                                    Use radioboxes for first column
       --no-headers                                   Don't show column headers
       --no-click                                     Disable clickable column headers
       --grid-lines=TYPE                              Set grid lines (hor[izontal], vert[ical] or both)
       --print-all                                    Print all data from list
       --editable-cols=LIST                           Set the list of editable columns
       --wrap-width=NUMBER                            Set the width of a column for start wrapping text
       --wrap-cols=LIST                               Set the list of wrapped columns
       --ellipsize=TYPE                               Set ellipsize mode for text columns (none, start, middle or end)
       --ellipsize-cols=LIST                          Set the list of ellipsized columns
       --print-column=NUMBER                          Print a specific column. By default or if 0 is specified will be printed all columns
       --hide-column=NUMBER                           Hide a specific column
       --expand-column=NUMBER                         Set the column expandable by default. 0 sets all columns expandable
       --search-column=NUMBER                         Set the quick search column. Default is first column. Set it to 0 for disable searching
       --tooltip-column=NUMBER                        Set the tooltip column
       --sep-column=NUMBER                            Set the row separator column
       --sep-value=TEXT                               Set the row separator value
       --limit=NUMBER                                 Set the limit of rows in list
       --dclick-action=CMD                            Set double-click action
       --select-action=CMD                            Set select action
       --row-action=CMD                               Set row action
       --tree-expanded                                Expand all tree nodes
       --regex-search                                 Use regex in search
       --no-selection                                 Disable selection
       --add-on-top                                   Add new records on the top of a list
       --simple-tips                                  Don't use markup in tooltips
       --header-tips                                  Use column name as a header tooltip
       --column-align=STRING                          Set columns alignment
       --header-align=STRING                          Set headers alignment

      Notebook options
       --tab=LABEL                                    Add a tab to notebook
       --tab-pos=TYPE                                 Set position of a notebook tabs (top, bottom, left or right)
       --tab-borders=NUMBER                           Set tab borders
       --active-tab=NUMBER                            Set active tab
       --expand                                       Expand tabs
       --stack                                        Use stack mode

      Notification icon options
       --menu=STRING                                  Set initial popup menu
       --no-middle                                    Disable exit on middle click
       --hidden                                       Doesn't show icon at startup
       --icon-size=SIZE                               Set icon size for fully specified icons (default - 16)

      Paned dialog options
       --orient=TYPE                                  Set orientation (hor[izontal] or vert[ical])
       --splitter=POS                                 Set initial splitter position
       --focused=PANE                                 Set focused pane (1 or 2)

      Picture dialog options
       --size=TYPE                                    Set initial size (fit or orig)
       --inc=NUMBER                                   Set increment for picture scaling (default - 5)
       --image-changed=CMD                            Set action on image changing

      Print dialog options
       --type=TYPE                                    Set source type (text, image or raw)
       --headers                                      Add headers to page

      Progress options
       --bar=LABEL[:TYPE]                             Add the progress bar (norm, rtl, pulse or perm)
       --watch-bar=NUMBER                             Watch for specific bar for auto close
       --align=TYPE                                   Set alignment of bar labels (left, center or right)
       --progress-text=TEXT                           Set progress text
       --hide-text                                    Hide text on progress bar
       --pulsate                                      Pulsate progress bar
       --auto-close                                   Dismiss the dialog when 100% has been reached
       --auto-kill                                    Kill parent process if cancel button is pressed
       --rtl                                          Right-To-Left progress bar direction
       --enable-log=[TEXT]                            Show log window
       --log-expanded                                 Expand log window
       --log-on-top                                   Place log window above progress bar
       --log-height                                   Height of log window

      Scale options
       --value=VALUE                                  Set initial value
       --min-value=VALUE                              Set minimum value
       --max-value=VALUE                              Set maximum value
       --step=VALUE                                   Set step size
       --enforce-step                                 Only allow values in step increments
       --page=VALUE                                   Set paging size
       --print-partial                                Print partial values
       --hide-value                                   Hide value
       --invert                                       Invert direction
       --inc-buttons                                  Show +/- buttons in scale
       --mark=NAME:VALUE                              Add mark to scale (may be used multiple times)

      Text information options
       --wrap                                         Enable text wrapping
       --justify=TYPE                                 Set justification (left, right, center or fill)
       --margins=SIZE                                 Set text margins
       --line=NUMBER                                  Jump to specific line
       --fore=COLOR                                   Use specified color for text
       --back=COLOR                                   Use specified color for background
       --show-cursor                                  Show cursor in read-only mode
       --show-uri                                     Make URI clickable
       --uri-color=COLOR                              Use specified color for links
       --formatted                                    Use pango markup
       --in-place                                     Save file instead of print on exit
       --confirm-save=[TEXT]                          Confirm save the file if text was changed

      SourceView options
       --lang=LANG                                    Use specified langauge for syntax highlighting
       --theme=THEME                                  Use specified theme
       --line-num                                     Show line numbers
       --line-hl                                      Highlight current line
       --line-marks                                   Enable line marks
       --mark1-color=COLOR                            Set color for first type marks
       --mark2-color=COLOR                            Set color for second type marks
       --right-margin=[POS]                           Set position of right margin
       --brackets                                     Highlight matching brackets
       --indent                                       Use autoindent
       --tab-width=VALUE                              Set tabulation width
       --indent-width=VALUE                           Set indentation width
       --smart-he=TYPE                                Set smart Home/End behavior
       --smart-bs                                     Enable smart backspace
       --spaces                                       Insert spaces instead of tabs

      File filter options
       --file-filter=NAME | PATTERN1 PATTERN2 ...     Sets a filename filter
       --mime-filter=NAME | MIME1 MIME2 ...           Sets a mime-type filter
       --image-filter=[NAME]                          Add filter for images

      Miscellaneous options
       --version                                      Print version
       --css=STRING                                   Load additional CSS settings from file or string
       --gtkrc=FILENAME                               Load additional CSS settings from file
       --hscroll-policy=TYPE                          Set policy for horizontal scrollbars (auto, always, never)
       --vscroll-policy=TYPE                          Set policy for vertical scrollbars (auto, always, never)
       --image-path=PATH                              Add path for search icons by name

      GTK+ Options
       --class=CLASS                                  Program class as used by the window manager
       --name=NAME                                    Program name as used by the window manager
       --gtk-module=MODULES                           Load additional GTK+ modules
       --g-fatal-warnings                             Make all warnings fatal

      Application Options:
       --rest=FILENAME                                Load extra arguments from file
       --about                                        Display about dialog
       --app                                          Display application selection dialog
       --calendar                                     Display calendar dialog
       --color                                        Display color selection dialog
       --dnd                                          Display drag-n-drop box   https://yadbash.com/yad-dnd
       --entry                                        Display text entry or combo-box dialog
       --file                                         Display file selection dialog
       --font                                         Display font selection dialog
       --form                                         Display form dialog
       --html                                         Display HTML dialog https://yadbash.com/yad-html
       --icons                                        Display icons box dialog
       --list                                         Display list dialog
       --notebook                                     Display notebook dialog
       --notification                                 Display notification
       --paned                                        Display paned dialog
       --picture                                      Display picture dialog
       --print                                        Display printing dialog
       --progress                                     Display progress indication dialog
       --scale                                        Display scale dialog
       --text-info                                    Display text information dialog
       --display=DISPLAY                              X display to use