Cairo/pango

From PLplotWiki
Revision as of 05:04, 8 April 2010 by Smekal (Talk | contribs)

Jump to: navigation, search

Description

Cairo is a 2D graphics library with support for multiple output devices. Currently supported output targets include the X Window System, Quartz, Win32, image buffers, PostScript, PDF, and SVG file output. Experimental backends include OpenGL (through glitz), XCB, BeOS, OS/2, and DirectFB.

Pango is a library for laying out and rendering of text, with an emphasis on internationalization. Pango can be used anywhere that text layout is needed, though most of the work on Pango so far has been done in the context of the GTK+ widget toolkit.

Instructions for Windows

MinGW

For the MinGW toolset it's best to download the provided Windows binaries form the GTK+ project.

  • Download the all-in-one bundle of the Windows GTK+ stack including 3rd-party dependencies for windows: GTK+ 2.20 or GTK+ 2.16
  • Unzip the package to a directory, e.g. C:\Development\gtk
  • Set environment variables so that CMake can find pkf-config
  set PKG_CONFIG_PATH=C:\Development\gtk\lib\pkgconfig
  set PATH=C:\Development\gtk\bin;%PATH%

CMake will find pkg-config and all the libraries necessary to build the pdfcairo, pscairo, pngcairo, svgcairo and wincairo devices. xcairo will not be built since the X-Headers are not present on Windows.

Visual C++

N/A

Instructions for Linux

Usually the cairo/pango libraries are already installed on your Linux distribution, but the developer packages might be missing. E.g. for Ubuntu Linux just install the pango developer package:

 sudo apt-get install libpango1.0-dev

Since pango depends on cairo all the necessary developer packages are installed with this command. Similar instructions apply to other Linux distributions.

Instructions for Mac OS X

export PATH=/Library/Frameworks/GTK+.framework/Resources/bin:$PATH

cmake is now able to find the cairo/pango libraries via pkg-config.