## Gettings Started with GOffice

Gettings Started with GOffice

## Functions

void | libgoffice_init ()
void | libgoffice_shutdown ()

## Types and Values

#define | GO_VAR_DECL

## Description

GOffice is a GObject based C library. It provides easy API access to creating and manipulating graphs and canvases. See GogGraph and GocCanvas. It also includes a number of utilities and widgets that might be useful in office productivity software and similar.

The GOffice code was originally a part of Gnumeric, but was split into a separate library in 2005. Today it is being used by projects such as Gnumeric, Gnucash, Abiword (optional), GChemUtils and more.

GOffice is cross platform, with support for Windows, OSX, GNU/Linux, and other Unix-like systems. It can be built with or without GTK+ integration support.

To include GOffice use:

    1

    #include <goffice/goffice.h>

GOffice provides a pkg-config metadata file named "libgoffice-$major.$minor.pc", where $major and $minor denote which version GOffice is. So to link against GOffice 0.10 series, use:

    1

    pkg-config --libs libgoffice-0.10

API and ABI compatability is maintained per minor release series, e.g: all 0.8.x releases are ABI/API compatible with previous 0.8.x releases.

Bindings for other languages than C and C++ are available through GObject Introspection. To start using GOffice from Python:

    1
    2

    from gi.repository import GOffice
    GOffice.init()

## Functions

### libgoffice_init ()

    void
    libgoffice_init (void);

Initialize GOffice.

This function can be called several times; each call will increment a reference counter. Code that calls this function should call `libgoffice_shutdown()` when done to decrement the counter.

### libgoffice_shutdown ()

    void
    libgoffice_shutdown (void);

Decrements the counter for data initialized by `libgoffice_init()`. When the counter reaches 0, the data is freed/cleaned up as appropriate.

## Types and Values

### GO_VAR_DECL

    #      define GO_VAR_DECL __declspec(dllexport)