Remove tests
[pkg-perl] / deb-src / libwx-perl / libwx-perl-0.96 / ext / html / XS / HtmlCell.xsp
1 #############################################################################
2 ## Name:        ext/html/XS/HtmlCell.xsp
3 ## Purpose:     XS++ for Wx::HtmlCell and derived classes
4 ## Author:      Mattia Barbon
5 ## Modified by:
6 ## Created:     13/12/2003
7 ## RCS-ID:      $Id: HtmlCell.xsp 2079 2007-07-08 21:18:04Z mbarbon $
8 ## Copyright:   (c) 2003-2004, 2006 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 %{
16 #include <wx/html/htmlcell.h>
17 %}
18
19 %name{Wx::HtmlCell} class wxHtmlCell
20 {
21     wxHtmlCell();
22     void Destroy() %code{%  delete THIS; %};
23
24     void SetParent(wxHtmlContainerCell *p);
25     wxHtmlContainerCell *GetParent() const;
26
27     int GetPosX() const;
28     int GetPosY() const;
29     int GetWidth() const;
30     int GetHeight() const;
31     int GetDescent() const;
32
33 #if WXPERL_W_VERSION_GE( 2, 5, 1 )
34     bool IsFormattingCell() const;
35 #endif
36
37     const wxString& GetId() const;
38     void SetId(const wxString& id);
39
40     wxHtmlLinkInfo* GetLink(int x = 0, int y = 0) const;
41 #if WXPERL_W_VERSION_GE( 2, 5, 1 ) && WXPERL_W_VERSION_LT( 2, 7, 0 )
42     wxCursor GetCursor() const;
43 #endif
44     wxHtmlCell *GetNext() const;
45 #if WXPERL_W_VERSION_GE( 2, 5, 1 )
46     wxHtmlCell* GetFirstChild() const;
47 #endif
48     void SetPos(int x, int y);
49     void SetLink(const wxHtmlLinkInfo& link);
50     void SetNext(wxHtmlCell *cell);
51
52     void Layout(int w);
53 ##    void Draw(wxDC& dc, int x, int y, int view_y1, int view_y2,
54 ##              wxHtmlRenderingInfo& info);
55 ##    void DrawInvisible(wxDC& dc, int x, int y, wxHtmlRenderingInfo& info);
56
57 ##    const wxHtmlCell* Find(int condition, const void* param) const;
58 ##    void OnMouseClick(wxWindow *parent, int x, int y,
59 ##                      const wxMouseEvent& event);
60 ##    bool AdjustPagebreak(int *pagebreak, int *known_pagebreaks = NULL,
61 ##                         int number_of_pages = 0) const;
62     void SetCanLiveOnPagebreak(bool can);
63
64 #if WXPERL_W_VERSION_GE( 2, 5, 1 )
65     bool IsLinebreakAllowed() const;
66 #endif
67     bool IsTerminalCell() const;
68
69 #if WXPERL_W_VERSION_GE( 2, 5, 1 )
70     wxHtmlCell *FindCellByPos(wxCoord x, wxCoord y,
71                               unsigned flags = wxHTML_FIND_EXACT) const;
72     wxPoint GetAbsPos() const;
73
74     wxHtmlCell *GetFirstTerminal() const;
75     wxHtmlCell *GetLastTerminal() const;
76
77     unsigned GetDepth() const;
78     bool IsBefore(wxHtmlCell *cell) const;
79
80     wxString ConvertToText(wxHtmlSelection *sel) const;
81 #else
82     wxHtmlCell *FindCellByPos(wxCoord x, wxCoord y) const;
83 #endif
84 };
85
86 %name{Wx::HtmlWordCell} class wxHtmlWordCell
87 {
88 ##    wxHtmlWordCell(const wxString& word, wxDC& dc);
89
90 #if WXPERL_W_VERSION_GE( 2, 5, 1 )
91     void SetPreviousWord(wxHtmlWordCell *cell);
92 #endif
93 };
94
95 %name{Wx::HtmlContainerCell} class wxHtmlContainerCell
96 {
97     wxHtmlContainerCell(wxHtmlContainerCell *parent);
98
99     void InsertCell(wxHtmlCell *cell);
100
101     void SetAlignHor(int al);
102     int GetAlignHor() const;
103     void SetAlignVer(int al);
104     int GetAlignVer() const;
105
106     void SetIndent(int i, int what, int units = wxHTML_UNITS_PIXELS);
107     int GetIndent(int ind) const;
108     int GetIndentUnits(int ind) const;
109
110     void SetAlign(const wxHtmlTag& tag);
111     void SetWidthFloat(int w, int units);
112     %name{SetWidthFloatTag} void SetWidthFloat(const wxHtmlTag& tag,
113                                                double pixel_scale = 1.0);
114     void SetMinHeight(int h, int align = wxHTML_ALIGN_TOP);
115
116     void SetBackgroundColour(const wxColour& clr);
117     wxColour GetBackgroundColour();
118     void SetBorder(const wxColour& clr1, const wxColour& clr2);
119
120 #if WXPERL_W_VERSION_GE( 2, 5, 1 )
121     void RemoveExtraSpacing(bool top, bool bottom);
122 #endif
123 };
124
125 %name{Wx::HtmlColourCell} class wxHtmlColourCell
126 {
127     wxHtmlColourCell(const wxColour& clr, int flags = wxHTML_CLR_FOREGROUND);
128 };
129
130 %name{Wx::HtmlFontCell} class wxHtmlFontCell
131 {
132     wxHtmlFontCell(wxFont *font);
133 };
134
135 %name{Wx::HtmlWidgetCell} class wxHtmlWidgetCell
136 {
137     wxHtmlWidgetCell(wxWindow* window, int w = 0);
138 };