# Desktop Technologies

## Application and File Type Registries

In order for applications to be useful, users need to be able to find and run them. Users of the GNOME desktop may run applications using the applications menu, or they may run them by accessing files in the file manager. The GNOME desktop allows you to add applications and file types when you install your application. The mechanism for these is specified on freedesktop.org, so the same data will allow your application to function in other desktop environments.

Adding your application is as simple as providing a desktop entry file with the necessary information. Desktop entry files use a simple key-value syntax, with extra provisions for providing translated content of particular values. Your application's desktop entry file will contain the following information:

- A name and a comment, each translated into as many languages as your application supports,

- A list of categories from a fixed list, which are used to place your application in the applications menu,

- An icon, either as a full file path or as a simple name for the icon theme system,

- A list of file types that your application supports, and

- The command to run your application.

If your application handles custom file types that are not already known by the system, you will need to add those types to the file type registry. All file types are accessed with MIME types. For example, Ogg Vorbis audio files have the MIME type `application/ogg`. To add a MIME type, you need to provide a description of the type using a MIME information XML file. These files provide a translated name for the type as well as information on how to determine which files are of the type, either by matching the file name or by inspecting the contents of the file.

For more information on applications, see The Desktop Entry Specification and The Desktop Menu Specification. For more information on file types, see The Shared MIME Info Specification.

## Aplets del panèl

The GNOME desktop features flexible and powerful panels to which users can add any number of small applications, called panel applets. Panel applets can provide all sorts of quick access to all sorts of useful information and functionality. For instance, the GNOME desktop ships with panel applets to switch between windows and workspaces, display the current weather conditions, and display network activity, among many others.

You may provide a panel applet to augment the functionality of your application, or you may provide a simple stand-alone panel applet. If you simply need to display quick notifications, you should consider using the notification area instead, which is also displayed in the user's panel. Panel applets should be used when you need to provide more functionality than that provided by notification icons.

Panel applets are independent processes that use Bonobo to communicate with the panel. Bonobo allows applets to integrate with the panel to provide a consistent user experience. For example, the context menu for every panel applet contains standard items to remove, move, and lock the applet. Each panel applet can then add items to the context menu to perform other actions. The Weather Report panel applet, for example, has context menu items to display a detailed report and to update the displayed information.

Note that Bonobo has been deprecated in favor of D-Bus and other technologies.

For more information on panel applets, see the Panel Applet Library.

## Zòna de notificacion

In addition to launchers and panel applets, the GNOME panel also features a notification area that applications can use to notify users of events. Notifications can be used to alert the user of new emails, available updates, upcoming meetings, or any number of other events.

Notifications are simple icons that your application can place in the notification area on the user's panel. Your application can then take further action when the user clicks on the icon. Currently, the notification system is implemented in the experimental Egg library; however, the next version of GTK+ will have support for notification icons.

The notification area is a freedesktop.org specification, so your notification icons will appear in other desktop environments as well. For more information on the notification area, see The System Tray Protocol Specification.

## Gestionari de fichièrs

GNOME ships with Nautilus, an intuitive and powerful file manager. Using the advanced GVFS technology, Nautilus is able to display remote folders just like folders on the local file system, giving users access to all their files everywhere with a single consistent interface.

Nautilus provides a plugin interface, enabling developers to extend its functionality to provide more information about users' files. This provides a richer and more coherant experience for users, removing the need for seperate applications to manage various types of files.

Nautilus plugins can extend the file manager's functionality in a number of ways. Plugins can add extra information to file properties dialogs, providing users with everything they need to know about files. For example, GNOME ships with a plugin to display extra information about audio and video files, such as the codec used, the dimensions of the video, and artist and album of music files extracted from a CD.

Plugins can also add columns to the list view and automatically place emblems on files. This can be used to provide pertinent information to the user at a glance. For example, a Nautilus plugin could provide version control information on folders checked out from a version control system. Users could see directly in the file manager if a file is up to date, or if changes have been made locally.

Nautilus also allows developers to add items to the context menu for files and folders. Context menu items can specify for which types of files they should be displayed, so the context menu only provides actions that are relevant for the selected files. For example, File Roller, GNOME's archive file utility, adds an item to the context menu to extract archive files directly. Extra context menu items provide easy access to common operations on different types of files.

In addition to a flexible plugin architecture, Nautilus can also display a thumbnail for any type of file for which a thumbnailer has been provided. Thumbnails show a preview of the file, helping users find the files they want. GNOME can automatically create thumbnails for most image and movie files, and allows applications to install additional thumbnailer programs to create thumbnails for application-specific files. Thumbnail management is fully specified by freedesktop.org, so any thumbnailers you provide can be used by all applications.

## Gestionari de fenèstras

The window manager is a special program responsible for drawing the borders and titlebars around windows. The window manager is responsible for handling all the operations performed on windows, such as moving, resizing, minimizing, and moving between workspaces. Windows are managed consistently with little or no work from application developers. When applications need to influence the window manager, they can provide hints on their windows using function calls in GTK+.

External programs can, however, interact directly with the window manager, and even control its behavior. Using GNOME's libwnck library, applications can get information about the placement and state of all the windows and instruct the window manager to perform various actions on those windows.

The libwnck library isn't specific to GNOME's window manager. All of its functionality uses the Extended Window Manager Hints, or EWMH. EWMH was developed jointly with freedesktop.org to provide unified window manager interaction across multiple desktops.

Window manager interaction with libwnck can be used for simple tasks, such as displaying workspace and window list applets on the user's panel, as well as for complex applications, such as performing automatic actions on new windows based on certain window properties.

## Control Center

The GNOME desktop provides a single menu of all the desktop-wide preferences and system administration settings. Preferences and settings dialogs can be placed in this menu to make them easily accessible. Dialogs can be placed in the preferences menu by adding them to the applications registry with the `Setting` category. Dialogs can be placed in the administration menu using both the `Settings` and `System` categories.

If you provide a dialog that allows administrators to configure desktop systems, then you should add your dialog to the administration menu. If you provide a dialog that allows users to adjust preferences that affect a number of applications, then you should add your dialog to the preferences menu. You should not use these global menus for individual application preferences.

## Storing Passwords

GNOME provides a modern and secure keyring manager to store users' passwords and other sensitive data. Applications can use the keyring manager library to store and access passwords, and users can manage their passwords using GNOME's Seahorse application.

The keyring manager provides any number of keyrings, where each keyring can contain any number of keyring items. Items in a keyring store some piece of data, often a password. Each keyring is locked individually, and users must provide a password to unlock the keyring. Once a keyring has been unlocked, the user has access to all of the items in that keyring.

The keyring manager provides access control lists for each keyring item, controlling which applications are allowed access to that item. If an unknown application attempts to access a keyring item, the keyring manager will prompt the user to allow or deny that application access. This helps prevent malicious or poorly-written programs from accessing the user's sensitive data.

Keyring data stored on the file system is encrypted with the AES block cipher, and SHA1 is used for hashes of the item's attributes. Using the attributes hash, the keyring manager is able to look up items requested by applications without ever unlocking the keyring. The keyring has to be unlocked when a matching item is found and accessed.

The keyring manager also provides a session keyring. Items in the session keyring are never stored on disk, and are lost as soon as the user's session ends. The session keyring can be used to store passwords to be used in the current session only.

If you use GIO to access remote servers, you automatically get the benefits of the keyring manager. Whenever GVFS needs to authenticate the user, it provides the option to store the password, either in the default keyring or in the session keyring.

You should use the keyring manager whenever your application needs to store passwords or other sensitive data for users. Using the keyring manager provides a better user experience while still keeping user data safe and secure.

For API references please see the gnome-keyring Reference Manual and the libseahorse Reference Manual.

## Session Management

GNOME provides tools to allow your application to run smoothly from session to session. Users can log out with running applications and have those applications fully restored when they log back in. To provide this functionality, your application must connect to the session manager and save its state when the user logs out.

Note that this section is outdated as GnomeClient and Libgnomeui are deprecated. Newly written code should use EggSMClient instead. Work is currently underway to integrate EggSMClient directly into GTK+. API and ABI stability guarantees ensures that GnomeClient will continue to be functional and supported throughout the GNOME 2 lifecycle.

GNOME provides a simple API for session management in the GNOME User Interface Library. See the section GnomeClient of the GNOME UI Library Reference Manual for more information on working with the GNOME session manager.

## Quasernet d'adreças e calendièr

With Evolution Data Server, GNOME provides a single address book and calendar that all applications can use to store and retrieve information. Using Evolution Data Server means that users no longer have to maintain separate lists of contacts in each application, or manually copy events to their calendar.

People use computers increasingly to interact with their friends and colleagues. Applications such as email programs, instant messengers, and telephony and video conferencing applications are used to communicate with others. These applications often provide contact lists to help users. Using Evolution Data Server, applications can store contact information in a single location, allowing all applications to see all the pertinent data about users' contacts.

Applications can also use Evolution Data Server to store and retrieve appointments on the user's calendar. For example, the clock on the panel shows a simple calendar when clicked. If the user has any appointments scheduled, they are shown alongside the calendar. This makes it easy to see upcoming appointments without opening a full calendar application.

For more information on the address book, see Evolution API Reference: libebook. For more information on the calendar, see Evolution API Reference: libecal.

## Usability

The GNOME desktop is designed around usability, and it aims to provide a consistent and simple user experience. People use computers to get work done (or to play!), not to figure out complicated user interface puzzles. When designing your application, you should consider how well users can recognize common user interface paradigms, how quickly they can learn the elements that are unique to your application, and how efficiently they can execute tasks once they've learned them.

GNOME provides comprehensive Human Interface Guidelines to help you write applications that are attractive and usable. While no guidelines can provide a single answer for all usability concerns, understanding the GNOME Human Interface Guidelines can make it easier to create a usable application. For more information, please see the GNOME Human Interface Guidelines.

## Documentacion

All applications should provide documentation to help their users understand the application and troubleshoot problems that may arise. While a well-designed application should not require reading the documentation before use, documentation can nonetheless be an important tool for users, particularly for complex applications.

GNOME provides a unified framework for providing user documentation. You can provide documentation in the industry-standard DocBook format. Using DocBook means that you don't have to worry about formatting details. Instead, your documentation will be automatically formatted with the same consistent conventions as the rest of the system documentation.

GNOME's help viewer, Yelp, displays and prints documentation, provides a listing of all documentation on the system, and allows the user to search the full text of all documentation. Using the GNOME help system gives you all these features for free.

For more information on writing documentation for your application, see the GNOME Handbook of Writing Software Documentation, DocBook: The Definitive Guide, and the GNOME Documentation Style Guide.