# Exo Reference Manual

Version
September 2009
2004
2005
2006
2007
os-cillation e.K.
2009
Xfce Development Team

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. The complete license text is available from the Free Software Foundation.

Benedikt
Meurer

    benny@xfce.org

os-cillation
System development
Software developer
Jannis
Pohlmann

    jannis@xfce.org

## Overview

libexo is an extension library for Xfce, developed by os-cillation. While Xfce comes with quite a few libraries that are targeted at desktop development, libexo is targeted at application developement - in particular, developing applications for the Xfce Desktop Environment.

The exo library depends on the following libraries:

GLib

  A general-purpose utility library, not specific to graphical user interfaces. GLib provides many useful data types, macros, type conversions, string utilities, file utilities, a main loop abstraction, and so on.

Pango

  Pango is a library for internationalized text handling. It centers around the PangoLayout object, representing a paragraph of text. Pango provides the engine for GtkTextView, GtkLabel, GtkEntry, and other widgets that display text.

ATK

  ATK is the Accessibility Toolkit. It provides a set of generic interfaces allowing accessibility technologies to interact with a graphical user interface. For example, a screen reader uses ATK to discover the text in an interface and read it to blind users. GTK+ widgets have built-in support for accessibility using the ATK framework.

GdkPixbuf

  This is a small library which allows you to create GdkPixbuf ("pixel buffer") objects from image data or image files. Use a GdkPixbuf in combination with GtkImage to display images.

GDK

  GDK is the abstraction layer that allows GTK+ to support multiple windowing systems. GDK provides drawing and window system facilities on X11, Windows, and the Linux framebuffer device.

GTK+

  The GTK+ library contains widgets, that is, GUI components such as GtkButton or GtkTextView.

libxfce4util

  The Xfce utility library provides various helper functions and classes for C programmers, that aren't directly related to GUI tasks.

## Editable Toolbars

These classes together provide a framework for editable toolbars based on the GtkAction facility introduced with Gtk+ 2.4. To create editable toolbars with exo, use the ExoToolbarsModel class with the ExoToolbarsView widget. This widget is designed around a Model/View/Controller design and consists of three parts:

- The toolbars widget (ExoToolbarsView)
- The toolbars model (ExoToolbarsModel)
- The toolbars editor widget (ExoToolbarsEditor)

The ExoToolbarsEditorDialog widget is provided for convenience, it simply wraps the ExoToolbarsEditor component into a GtkDialog.

## Additional widgets

This section describes the additional widgets provided by the exo library. The ExoIconBar, ExoIconView and ExoTreeView are views that display data from a GtkTreeModel, and can be seen as extensions to the basic widgets in Gtk+. For example, both ExoIconView and ExoTreeView offer support for single-click mode, which is not provided by their Gtk+ counterparts.

The ExoIconChooserDialog is a special widget, that presents a dialog to let the user select an icon from the current icon theme or from an image file in the file system. You should use this dialog whenever you want the user to select an icon, instead of just displaying a GtkFileChooserDialog.

## Additional cell renderers

Gtk+ contains various cell renderers that are intended to be used with GtkTreeView and GtkComboBox, but are difficult to use with ExoIconView (or even GtkIconView), mainly because the renderers do not follow the state of the view and render appropriate indicators.

Because of these issues, the ExoCellRendererEllipsizedText (the name of the class is rather confusing) and the ExoCellRendererIcon classes are provided, which both include a `follow-state` property that tells whether the renderer should follow the state of the view and draw appropriate indicators.

The ExoCellRendererIcon class should also be preferred over the the GtkCellRendererPixbuf class when using named icons or image files because it uses a fixed size for layouting and loads the icons only on-demand (utilizing the thumbnail database whenever possible).

## Framework for threaded/asynchronous jobs

ExoJob provides a simple way to deal with threaded/asynchronous operations (called jobs here). It can be used to wrap any kind of blocking function calls like file operations or web service communication. It can be subclassed to add additional signals for progress information or password requests. ExoSimpleJob is useful in situations where you don't need additional signals. It takes a ExoSimpleJobFunc callback and creates a job so one doesn't have to subclass ExoJob just to execute a single function asynchronously.

## Extensions to existing frameworks

This section describes extensions to existing frameworks provided by the exo, that range from additional methods for certain classes to specialized functions dealing with GdkPixbufs.

## Miscelleanous

## Tools

This part presents the tools which are shipped with the exo library.

## Visual Index

## Index