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

void wxPdfDocument::RadioButton ( const wxString &  group,
const wxString &  name,
double  x,
double  y,
double  width 

Adds a radio button.

Adds a radio button to the list of form fields

groupname of the radio button group this radio button belongs to
namefield name of the radio button
xabscissa of the radio button position
yordinate of the radio button position
widthwidth of the radio button

Definition at line 502 of file pdfform.cpp.

References wxPdfRadioGroup::Add(), AddFormField(), wxPdfRadioGroup::GetCount(), GetNewObjId(), wxPdfAnnotationWidget::SetName(), and wxPdfAnnotationObject::SetRectangle().

  wxPdfRadioGroup* currentGroup;
  wxPdfRadioGroupMap::iterator radioGroup = (*m_radioGroups).find(group);
  if (radioGroup != (*m_radioGroups).end())
    currentGroup = static_cast<wxPdfRadioGroup*>(radioGroup->second);
//    currentGroup = new wxPdfRadioGroup(GetNewObjId(), group);
    currentGroup = new wxPdfRadioGroup(0, group);
    (*m_radioGroups)[group] = currentGroup;
#if 0
// TODO: integrate radio button groups into PDF document
    int n = (*m_formFields).size()+1;
    (*m_formFields)[n] = currentGroup;

  wxPdfRadioButton* field = new wxPdfRadioButton(GetNewObjId(), currentGroup->GetCount()+1);
  field->SetRectangle(x, y, width, width);
// TODO: integrate radio button groups into PDF document
  AddFormField(field /*, false*/);

Here is the call graph for this function:

Generated by  Doxygen 1.6.0   Back to index