Logo Search packages:      
Sourcecode: codeblocks version File versions  Download package

void wxPdfDocument::Rect ( double  x,
double  y,
double  w,
double  h,
int  style = wxPDF_STYLE_DRAW 
) [virtual]

Outputs a rectangle.

It can be drawn (border only), filled (with no border) or both.

xAbscissa of upper-left corner
yOrdinate of upper-left corner
styleStyle of rendering. Possible values are:

  • wxPDF_STYLE_DRAW (default)
  • wxPDF_STYLE_FILL: fill
  • wxPDF_STYLE_FILLDRAW: draw and fill
See also:
SetLineWidth(), SetDrawColor(), SetFillColor()

Definition at line 883 of file pdfgraphics.cpp.

References Double2String(), m_h, m_k, and OutAscii().

Referenced by wxPdfBarCodeCreator::Barcode(), wxPdfBarCodeCreator::DrawCode39(), wxPdfBarCodeCreator::I25(), Marker(), RoundedRect(), TextBox(), and wxPdfTable::WriteRow().

  wxString op;
  // Draw a rectangle
  if ((style & wxPDF_STYLE_FILLDRAW) == wxPDF_STYLE_FILL)
    op = _T("f");
  else if ((style & wxPDF_STYLE_FILLDRAW) == wxPDF_STYLE_FILLDRAW)
    op = _T("B");
    op = _T("S");
  OutAscii(Double2String(x*m_k,2) + wxString(_T(" ")) +
           Double2String((m_h-y)*m_k,2) + wxString(_T(" ")) +
           Double2String(w*m_k,2) + wxString(_T(" ")) +
           Double2String(-h*m_k,2) + wxString(_T(" re ")) + op);

Here is the call graph for this function:

Here is the caller graph for this function:

Generated by  Doxygen 1.6.0   Back to index