Add libwx-perl
[pkg-perl] / deb-src / libwx-perl / libwx-perl-0.96 / XS / BitmapComboBox.xsp
1 #############################################################################
2 ## Name:        XS/BitmapComboBox.xsp
3 ## Purpose:     XS++ for Wx::BitmapComboBox
4 ## Author:      Mattia Barbon
5 ## Modified by:
6 ## Created:     18/08/2007
7 ## RCS-ID:      $Id: BitmapComboBox.xsp 2406 2008-06-29 18:47:50Z mbarbon $
8 ## Copyright:   (c) 2007-2008 Mattia Barbon
9 ## Licence:     This program is free software; you can redistribute it and/or
10 ##              modify it under the same terms as Perl itself
11 #############################################################################
12
13 %module{Wx};
14
15 #if WXPERL_W_VERSION_GE( 2, 7, 2 )
16
17 #include <wx/bmpcbox.h>
18
19 %typemap{wxBitmapComboBox*}{simple};
20
21 %name{Wx::BitmapComboBox} class wxBitmapComboBox
22 {
23 %{
24 void
25 new( ... )
26   PPCODE:
27     BEGIN_OVERLOAD()
28         MATCH_VOIDM_REDISP( newDefault )
29         MATCH_ANY_REDISP( newFull )
30     END_OVERLOAD( "Wx::BitmapComboBox::new" )
31 %}
32
33     %name{newDefault} wxBitmapComboBox()
34         %code{% RETVAL = new wxBitmapComboBox();
35                 wxPli_create_evthandler( aTHX_ RETVAL, CLASS );
36              %};
37     %name{newFull} wxBitmapComboBox( wxWindow *parent,
38                                      wxWindowID id,
39                                      const wxString& value,
40                                      const wxPoint& pos = wxDefaultPosition,
41                                      const wxSize& size = wxDefaultSize,
42                                      const wxArrayString& choices,
43                                      long style = 0,
44                                      const wxValidator& val = wxDefaultValidatorPtr,
45                                      const wxString& name = wxBitmapComboBoxNameStr )
46         %code{% RETVAL = new wxBitmapComboBox( parent, id, value, pos, size,
47                                                 choices, style, *val, name );
48                 wxPli_create_evthandler( aTHX_ RETVAL, CLASS );
49              %};
50
51     bool Create( wxWindow *parent,
52                  wxWindowID id,
53                  const wxString& value,
54                  const wxPoint& pos = wxDefaultPosition,
55                  const wxSize& size = wxDefaultSize,
56                  const wxArrayString& choices,
57                  long style = 0,
58                  const wxValidator& val = wxDefaultValidatorPtr,
59                  const wxString& name = wxBitmapComboBoxNameStr );
60
61 %{
62 void
63 wxBitmapComboBox::Append( ... )
64   PPCODE:
65     BEGIN_OVERLOAD()
66         MATCH_REDISP( wxPliOvl_s_wbmp_s, AppendData )
67         MATCH_REDISP( wxPliOvl_s_wbmp, AppendString )
68     END_OVERLOAD( Wx::BitmapComboBox::Append )
69 %}
70
71     %name{AppendString} void Append( const wxString& item,
72                                      const wxBitmap& bitmap = wxNullBitmapPtr );
73     %name{AppendData} void Append( const wxString& item,
74                                    const wxBitmap& bitmap,
75                                    wxPliUserDataCD* data );
76 %{
77 void
78 wxBitmapComboBox::Insert( ... )
79   PPCODE:
80     BEGIN_OVERLOAD()
81         MATCH_REDISP( wxPliOvl_s_wbmp_n_s, InsertData )
82         MATCH_REDISP( wxPliOvl_s_wbmp_n, InsertString )
83     END_OVERLOAD( Wx::BitmapComboBox::Insert )
84 %}
85
86     %name{InsertString} void Insert( const wxString& item,
87                                      const wxBitmap& bitmap,
88                                      unsigned int pos );
89     %name{InsertData} void Insert( const wxString& item,
90                                    const wxBitmap& bitmap,
91                                    unsigned int pos,
92                                    wxPliUserDataCD* data );
93
94     wxBitmap GetItemBitmap( unsigned int n ) const;
95     void SetItemBitmap( unsigned int n, const wxBitmap& bitmap );
96     wxSize GetBitmapSize() const;
97 };
98
99 #endif