~laney/ubuntu/quantal/swig2.0/guile-2.0

« back to all changes in this revision

Viewing changes to Examples/test-suite/rename_pcre_encoder.i

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Landschoff
  • Date: 2010-12-19 18:25:59 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20101219182559-8lh77o66bo890jwo
Tags: 2.0.1-1
* Merge new upstream release 2.0.1.
* Remove dependency on quilt and usage in debian/rules, the new source
  format will take care of that.
* Remove patch fix-cleaning.diff (applied upstream).
* Remove patch keep_docs.diff (applied upstream).

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
%module rename_pcre_encoder
 
2
 
 
3
// strip the wx prefix from all identifiers except those starting with wxEVT
 
4
%rename("%(regex:/wx(?!EVT)(.*)/\\1/)s") "";
 
5
 
 
6
// Replace "Set" prefix with "put" in all functions
 
7
%rename("%(regex:/^Set(.*)/put\\1/)s", %$isfunction) "";
 
8
 
 
9
%inline %{
 
10
 
 
11
struct wxSomeWidget {
 
12
    void SetBorderWidth(int) {}
 
13
    void SetSize(int, int) {}
 
14
};
 
15
 
 
16
struct wxAnotherWidget {
 
17
    void DoSomething() {}
 
18
};
 
19
 
 
20
class wxEVTSomeEvent {
 
21
};
 
22
 
 
23
class xUnchangedName {
 
24
};
 
25
 
 
26
%}