Monday, February 21, 2011

Using Zenity to create the dialog boxes

Zenity is a tool that help you to create a common functional GTK+ dialogs. It have various dialogs that each of them have different ways of presenting data and acquire data from user input.

We have introduce how to make use of GUI dialog box in Using GUI dialog box, where we give an example of how zenity create a question dialog box. Besides question dialog box, zenity can create more than that, such as calendar, entry, error, info, file selection, list, notification, progress, warning, scale and text info. In this tutorial, we would like to illustrate how to create every single zenity dialog by examples.

zenity --warning --text "Could you please tell me who you are"

How to create zenity calendar dialog?
You are allow to specify the initial selection of date in calendar dialog, specified with options –day –month –year. The default selection will be today’s date. Zenity will returns the date selected by user.

No comments:

Post a Comment