This source file includes following definitions.
- main
 
#include <Magick++.h>
#include <string>
#include <iostream>
using namespace std;
using namespace Magick;
int main( int , char ** argv)
{
  
  InitializeMagick(*argv);
  try {
    string srcdir("");
    if(getenv("SRCDIR") != 0)
      srcdir = getenv("SRCDIR");
    
    
    
    string backGround = "xc:#CCCCCC"; 
    
    Color border = "#D4DCF3";
    
    string buttonSize = "120x20";
    
    string buttonTexture = "granite:";
    
    string text = "Button Text";
    
    string textColor = "red";
    
    int fontPointSize = 16;
    
    
    
    Image button;
    
    button.size( buttonSize );
    
    button.read( backGround );
    
    Image backgroundTexture( buttonTexture );
    button.texture( backgroundTexture );
    
    button.fillColor( textColor );
    button.fontPointsize( fontPointSize );
    button.annotate( text, CenterGravity );
    
    button.borderColor( border );
    button.frame( "6x6+3+3" );
    button.depth( 8 );
    
    
    button.quantizeDither(false);
    button.quantizeColors(64);
    button.quantize();
    
    cout << "Writing to \"button_out.miff\" ..." << endl;
    button.compressType( RLECompression );
    button.write("button_out.miff");
    
    
  }
  catch( exception &error_ )
    {
      cout << "Caught exception: " << error_.what() << endl;
      return 1;
    }
  return 0;
}