title ) ) { return $boundings; } $this->renderBorder( $renderer ); $this->renderBackground( $renderer ); $height = (int) min( round( $this->maxHeight * ( $boundings->y1 - $boundings->y0 ) ), $this->font->maxFontSize + $this->padding * 2 ); switch ( $this->position ) { case ezcGraph::TOP: $renderer->drawTextBox( new ezcGraphCoordinate( $boundings->x0 + $this->padding, $boundings->y0 + $this->padding ), $this->title, $boundings->x1 - $boundings->x0 - $this->padding * 2, $height - $this->padding * 2, ezcGraph::CENTER | ezcGraph::MIDDLE ); $boundings->y0 += $height + $this->margin; break; case ezcGraph::BOTTOM: $renderer->drawTextBox( new ezcGraphCoordinate( $boundings->x0 + $this->padding, $boundings->y1 - $height + $this->padding ), $this->title, $boundings->x1 - $boundings->x0 - $this->padding * 2, $height - $this->padding * 2, ezcGraph::CENTER | ezcGraph::MIDDLE ); $boundings->y1 -= $height + $this->margin; break; } return $boundings; } } ?>