Add libwx-perl
[pkg-perl] / deb-src / libwx-perl / libwx-perl-0.96 / ext / grid / XS / GridCellAttr.xs
1 #############################################################################
2 ## Name:        ext/grid/XS/GridCellAttr.xs
3 ## Purpose:     XS for Wx::GridCellAttr
4 ## Author:      Mattia Barbon
5 ## Modified by:
6 ## Created:     05/12/2001
7 ## RCS-ID:      $Id: GridCellAttr.xs 2402 2008-05-19 21:43:32Z mbarbon $
8 ## Copyright:   (c) 2001-2002, 2004, 2006-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 PACKAGE=Wx::GridCellAttr
14
15 wxGridCellAttr*
16 wxGridCellAttr::new()
17
18 static void
19 wxGridCellAttr::CLONE()
20   CODE:
21     wxPli_thread_sv_clone( aTHX_ CLASS, (wxPliCloneSV)wxPli_detach_object );
22
23 ## // thread OK
24 void
25 wxGridCellAttr::DESTROY()
26   CODE:
27     wxPli_thread_sv_unregister( aTHX_ wxPli_get_class( aTHX_ ST(0) ),
28                                 SvRV( ST(0) ), ST(0) );
29     if( THIS )
30         THIS->DecRef();
31
32 void
33 wxGridCellAttr::IncRef()
34
35 void
36 wxGridCellAttr::DecRef()
37
38 void
39 wxGridCellAttr::SetTextColour( colour )
40     wxColour colour
41
42 void
43 wxGridCellAttr::SetBackgroundColour( colour )
44     wxColour colour
45
46 void
47 wxGridCellAttr::SetFont( font )
48     wxFont* font
49   CODE:
50     THIS->SetFont( *font );
51
52 void
53 wxGridCellAttr::SetAlignment( hAlign, vAlign )
54     int hAlign
55     int vAlign
56
57 void
58 wxGridCellAttr::SetReadOnly( isReadOnly = true )
59     bool isReadOnly
60
61 bool
62 wxGridCellAttr::HasTextColour()
63
64 bool
65 wxGridCellAttr::HasBackgroundColour()
66
67 bool
68 wxGridCellAttr::HasFont()
69
70 bool
71 wxGridCellAttr::HasAlignment()
72
73 bool
74 wxGridCellAttr::HasRenderer()
75
76 bool
77 wxGridCellAttr::HasEditor()
78
79 wxColour*
80 wxGridCellAttr::GetTextColour()
81   CODE:
82     RETVAL = new wxColour( THIS->GetTextColour() );
83   OUTPUT:
84     RETVAL
85
86 wxColour*
87 wxGridCellAttr::GetBackgroundColour()
88   CODE:
89     RETVAL = new wxColour( THIS->GetBackgroundColour() );
90   OUTPUT:
91     RETVAL
92
93 wxGridCellEditor*
94 wxGridCellAttr::GetEditor( grid, row, col )
95     wxGrid* grid
96     int row
97     int col
98   CODE:
99     RETVAL = THIS->GetEditor( grid, row, col );
100   OUTPUT:
101     RETVAL
102
103 wxGridCellRenderer*
104 wxGridCellAttr::GetRenderer( grid, row, col )
105     wxGrid* grid
106     int row
107     int col
108   CODE:
109     RETVAL = THIS->GetRenderer( grid, row, col );
110   OUTPUT:
111     RETVAL
112
113 wxFont*
114 wxGridCellAttr::GetFont()
115   CODE:
116     RETVAL = new wxFont( THIS->GetFont() );
117   OUTPUT:
118     RETVAL
119
120 void
121 wxGridCellAttr::GetAlignment()
122   PREINIT:
123     int x, y;
124   PPCODE:
125     THIS->GetAlignment( &x, &y );
126     EXTEND( SP, 2 );
127     PUSHs( sv_2mortal( newSViv( x ) ) );
128     PUSHs( sv_2mortal( newSViv( y ) ) );
129
130 bool
131 wxGridCellAttr::IsReadOnly()
132
133 void
134 wxGridCellAttr::SetDefAttr( defAttr )
135     wxGridCellAttr* defAttr
136
137 void
138 wxGridCellAttr::SetEditor( editor )
139     wxGridCellEditor* editor
140   CODE:
141     editor->IncRef();
142     THIS->SetEditor( editor );
143
144 void
145 wxGridCellAttr::SetRenderer( renderer )
146     wxGridCellRenderer* renderer
147   CODE:
148     renderer->IncRef();
149     THIS->SetRenderer( renderer );
150     
151 bool
152 wxGridCellAttr::GetOverflow()
153
154 void
155 wxGridCellAttr::SetOverflow( allow = true )
156     bool allow
157