Im happy to open my siggy's souce code. I think this may help some learn.
Code:
<?php
class ChipSiggy
{
  var $title,$size,$font,$ref,$im,$color;
  function __construct()
  {
    $this->im= imagecreatefromjpeg("back.jpg");
    $this->ref=$_SERVER['HTTP_REFERER'];
    $this->title=$this->getTitle();
    $this->size=imagesx($this->im)/strlen($this->title)-1;
    if(($this->size)>18)
    $this->size=18;
    $this->font="";
  }
  function getTitle()
  {
    $title=file_get_contents($this->ref);
    $title=explode("<title>",$title);
    $title=explode("</title>",$title[1]);
    $title=explode("View topic - ",$title[0]);
    return $title[1];
  }
  function setFont($font)
  {
    $this->font=$font;
  }
  function setColor($r,$b,$g)
  {
    $this->color=imagecolorallocate($this->im, $r,$b,$g);
  }
  function generateImage()
  {
    if($this->title==NULL)
    {
      imagettftext($this->im,14,0,5,30,$this->color,$this->font,"You Are Watchin My Profile!");
      imagettftext($this->im, 14, 0, 5, 50, $this->color, $this->font, "Yes I Spy On You!");
    }
    else
    {
      imagettftext($this->im,$this->size,0,5,20,$this->color,$this->font,"You Are Watching ");
      imagettftext($this->im,$this->size,0,5,40,$this->color,$this->font,$this->title);
      imagettftext($this->im, $this->size, 0, 5, 65, $this->color, $this->font, "Yes I Spy On You!");
    }
    imagettftext($this->im, 12, 0, 300, 65, $this->color,"kinkimono.ttf" , "*Ksg91*");
    imagejpeg($this->im);
    imagedestroy($this->im);
  }
}
header("Content-type: image/jpeg");
$sig=new ChipSiggy();
$sig->setColor(0,0,0);
$sig->setFont("kinkimono.ttf");
$sig->generateImage();
?>
Siggy will look like below(in case i change my siggy and no demo):