Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Scotch/Scotch.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Scotch/Scotch.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Scotch/Scotch.cpp	(revision 13236)
@@ -7,23 +7,17 @@
 #else
 #error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
 #endif
-
-
 #include "./Scotch.h"
 
-/******************************/
-/*                            */
-/* This is the main function. */
-/*                            */
-/******************************/
+void GmapUsage(void){/*{{{*/
+	mexPrintf("\n");
+	mexPrintf("Usage: [maptab]=Scotch(adjmat,vertlb,vertwt,edgewt,archtyp,archpar,\n");
+	mexPrintf("                         Scotch-specific parameters);\n");
+	mexPrintf("\n");
+}/*}}}*/
+void mexFunction( int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[]){
 
-void mexFunction( int nlhs,
-				  mxArray *plhs[],
-				  int nrhs,
-				  const mxArray *prhs[] )
-{
-
-#ifndef _HAVE_SCOTCH_ //only works if scotch library has been compiled in.
+	#ifndef _HAVE_SCOTCH_ //only works if scotch library has been compiled in.
 	_error_("Scotch not available! Cannot carry out Scotch partitioning!");
 	#else
 
@@ -41,7 +35,7 @@
 
 	/* Check for proper number of arguments */
    
-	if      (nrhs == 0 && nlhs == 0) {
+	if (nrhs == 0 && nlhs == 0) {
 		GmapUsage();
 		return;
 	}
@@ -253,15 +247,3 @@
 	return;
 #endif //#ifndef _HAVE_SCOTCH_
 }
-
-void GmapUsage( void )
-{
-
-    mexPrintf("\n");
-    mexPrintf("Usage: [maptab]=Scotch(adjmat,vertlb,vertwt,edgewt,archtyp,archpar,\n");
-    mexPrintf("                         Scotch-specific parameters);\n");
-    mexPrintf("\n");
-
-    return;
-}
-
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Scotch/Scotch.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Scotch/Scotch.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Scotch/Scotch.h	(revision 13236)
@@ -5,13 +5,9 @@
 #ifndef _SCOTCH_H
 #define _SCOTCH_H
 
-/* local prototypes: */
-void GmapUsage(void);
-
 #include <stdio.h>
 #include <string.h>    /*  strcasecmp  */
 #include <time.h>      /*  clock,time,difftime  */
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/NodeConnectivity/NodeConnectivity.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/NodeConnectivity/NodeConnectivity.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/NodeConnectivity/NodeConnectivity.cpp	(revision 13236)
@@ -4,6 +4,11 @@
 
 #include "./NodeConnectivity.h"
 
+void NodeConnectivityUsage(void){/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("   usage: connectivity = " << __FUNCT__ << "(elements, numnodes);");
+	_pprintLine_("");
+}/*}}}*/
 WRAPPER(NodeConnectivity){
 
 	/*inputs: */
@@ -34,9 +39,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void NodeConnectivityUsage(void) {
-	_pprintLine_("");
-	_pprintLine_("   usage: connectivity = " << __FUNCT__ << "(elements, numnodes);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/NodeConnectivity/NodeConnectivity.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/NodeConnectivity/NodeConnectivity.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/NodeConnectivity/NodeConnectivity.h	(revision 13236)
@@ -16,6 +16,9 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
+#undef __FUNCT__ 
+#define __FUNCT__  "NodeConnectivity"
+
 /*Header files: */
 #include "../../c/include/globals.h"
 #include "../../c/toolkits/toolkits.h"
@@ -43,16 +46,10 @@
 #define CONNECTIVITY output,0
 #endif
 
-#undef __FUNCT__ 
-#define __FUNCT__  "NodeConnectivity"
-
 /* serial arg counts: */
 #undef NLHS
 #define NLHS  1
 #undef NRHS
 #define NRHS  2
 
-/* local prototypes: */
-void NodeConnectivityUsage(void);
-
 #endif  /* _NODECONNECTIVITY_H */
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgConvertMesh/BamgConvertMesh.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgConvertMesh/BamgConvertMesh.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgConvertMesh/BamgConvertMesh.cpp	(revision 13236)
@@ -3,7 +3,16 @@
  */
 #include "./BamgConvertMesh.h"
 
-void mexFunction(int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void BamgConvertMeshUsage(void){/*{{{*/
+	_pprintString_("BAMGCONVERTMESH - convert [x y index] to a bamg geom and mesh geom");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [bamggeom bamgmesh]=BamgConvertMesh(index,x,y);");
+	_pprintLine_("      index: index of the mesh");
+	_pprintLine_("      x,y: coordinates of the nodes");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(BamgConvertMesh){
 
 	/*input: */
 	int    *index      = NULL;
@@ -52,13 +61,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void BamgConvertMeshUsage(void){
-	_pprintString_("BAMGCONVERTMESH - convert [x y index] to a bamg geom and mesh geom");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [bamggeom bamgmesh]=BamgConvertMesh(index,x,y);");
-	_pprintLine_("      index: index of the mesh");
-	_pprintLine_("      x,y: coordinates of the nodes");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgConvertMesh/BamgConvertMesh.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgConvertMesh/BamgConvertMesh.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgConvertMesh/BamgConvertMesh.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void BamgConvertMeshUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLOverlay/KMLOverlay.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLOverlay/KMLOverlay.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLOverlay/KMLOverlay.cpp	(revision 13236)
@@ -3,7 +3,28 @@
  */
 #include "./KMLOverlay.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void KMLOverlayUsage(void){/*{{{*/
+	_pprintLine_("KMLOverlay - KML file overlay module:");
+	_pprintLine_("");
+	_pprintLine_("   This module reads a list of image files and writes a KML or KMZ overlay file.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      ierror=KMLOverlay(kmlfile,'param name',param,...);");
+	_pprintLine_("");
+	_pprintLine_("      kmlfile     KML or KMZ file name (string)");
+	_pprintLine_("");
+	_pprintLine_("      lataxis     latitude axis (double vector [south north], required)");
+	_pprintLine_("      longaxis    longitude axis (double vector [west east], required)");
+	_pprintLine_("      images      relative or http image file names (string or array of strings or cell array of strings, required)");
+	_pprintLine_("      zip         flag to zip the doc.kml and image files into kmzfile (double, non-zero for kmz)");
+	_pprintLine_("");
+	_pprintLine_("      ierror     error flag (double, non-zero for error)");
+	_pprintLine_("");
+	_pprintLine_("   Example:");
+	_pprintLine_("      KMLOverlay(kmlfile,'lataxis',[south north],'longaxis',[west east],'images',{'file1.png','http://issm/file2.png'},'zip',1);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(KMLOverlay){
 
 	int i,verbose=1;
 
@@ -110,25 +131,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void KMLOverlayUsage(void){
-	_pprintLine_("KMLOverlay - KML file overlay module:");
-	_pprintLine_("");
-	_pprintLine_("   This module reads a list of image files and writes a KML or KMZ overlay file.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      ierror=KMLOverlay(kmlfile,'param name',param,...);");
-	_pprintLine_("");
-	_pprintLine_("      kmlfile     KML or KMZ file name (string)");
-	_pprintLine_("");
-	_pprintLine_("      lataxis     latitude axis (double vector [south north], required)");
-	_pprintLine_("      longaxis    longitude axis (double vector [west east], required)");
-	_pprintLine_("      images      relative or http image file names (string or array of strings or cell array of strings, required)");
-	_pprintLine_("      zip         flag to zip the doc.kml and image files into kmzfile (double, non-zero for kmz)");
-	_pprintLine_("");
-	_pprintLine_("      ierror     error flag (double, non-zero for error)");
-	_pprintLine_("");
-	_pprintLine_("   Example:");
-	_pprintLine_("      KMLOverlay(kmlfile,'lataxis',[south north],'longaxis',[west east],'images',{'file1.png','http://issm/file2.png'},'zip',1);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLOverlay/KMLOverlay.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLOverlay/KMLOverlay.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLOverlay/KMLOverlay.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void KMLOverlayUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToNodes/ContourToNodes.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToNodes/ContourToNodes.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToNodes/ContourToNodes.cpp	(revision 13236)
@@ -1,29 +1,21 @@
 /*! \file  ContourtoNodes
     \brief: takes a  contour file, and figures out which nodes  (x,y list)
-    are inside this contour. 
-
-	usage:
-	[flags]=ContourToNodes(x,y,contours,interptype,edgevalue);
-	
-	where:
-
-	input:
-
-		x,y: node cooredinates
-		
-		contours: structure holding sets of vertices making open contours. 
-		
-		interptype: string definining type of interpolation ('element', or 'node', or 'element and node');
-
-		edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons
-
-	output:
-		flags: vector of flags (0 or 1), of size nods 
 */
 	
 #include "./ContourToNodes.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) {
+void ContourToNodesUsage(void){/*{{{*/
+	_printLine_("   usage:");
+	_printLine_("   [flags]=ContourToNodes(x,y,contourname,edgevalue);\n");
+	_printLine_("   where:");
+	_printLine_("      x,y: list of nodes.");
+	_printLine_("      contourname: name of .exp file containing the contours, or resulting structure from call to expread.");
+	_printLine_("      interptype: string definining type of interpolation ('element', or 'node').");
+	_printLine_("      edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons.");
+	_printLine_("      flags: vector of flags (0 or 1), of size nods.");
+	_printLine_("");
+}/*}}}*/
+WRAPPER(ContourToNodes){
 
 	int i,j;
 
@@ -86,15 +78,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void ContourToNodesUsage(void){
-	_printLine_("   usage:");
-	_printLine_("   [flags]=ContourToNodes(x,y,contourname,edgevalue);\n");
-	_printLine_("   where:");
-	_printLine_("      x,y: list of nodes.");
-	_printLine_("      contourname: name of .exp file containing the contours, or resulting structure from call to expread.");
-	_printLine_("      interptype: string definining type of interpolation ('element', or 'node').");
-	_printLine_("      edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons.");
-	_printLine_("      flags: vector of flags (0 or 1), of size nods.");
-	_printLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToNodes/ContourToNodes.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToNodes/ContourToNodes.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToNodes/ContourToNodes.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void ContourToNodesUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/HoleFiller/HoleFiller.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/HoleFiller/HoleFiller.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/HoleFiller/HoleFiller.cpp	(revision 13236)
@@ -9,12 +9,18 @@
 	using double arrays found in the workspace, and loaded directly into memory.
 */
 
-
 #include "./HoleFiller.h"
 
-void mexFunction( int nlhs, mxArray* plhs[],
-				  int nrhs, const mxArray* prhs[])
-{
+void HoleFillerUsage(void){/*{{{*/
+	_printLine_("   HoleFiller usage:");
+	_printLine_("   [image_out]=HoleFiller(image_in,smooth);\n");
+	_printLine_("   where:");
+	_printLine_("      image_in in double format");
+	_printLine_("      smooth: 1 to smooth with a box filer, 0 to leave data raw");
+	_printLine_("      image_out in double format");
+	_printLine_("");
+}/*}}}*/
+WRAPPER(HoleFiller){
 
 	int i,j;
 
@@ -55,15 +61,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-
-void HoleFillerUsage(void)
-{
-	_printLine_("   HoleFiller usage:");
-	_printLine_("   [image_out]=HoleFiller(image_in,smooth);\n");
-	_printLine_("   where:");
-	_printLine_("      image_in in double format");
-	_printLine_("      smooth: 1 to smooth with a box filer, 0 to leave data raw");
-	_printLine_("      image_out in double format");
-	_printLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/HoleFiller/HoleFiller.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/HoleFiller/HoleFiller.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/HoleFiller/HoleFiller.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void HoleFillerUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshProfileIntersection/MeshProfileIntersection.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshProfileIntersection/MeshProfileIntersection.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshProfileIntersection/MeshProfileIntersection.cpp	(revision 13236)
@@ -17,7 +17,19 @@
 	
 #include "./MeshProfileIntersection.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) {
+void MeshProfileIntersectionUsage(void){/*{{{*/
+	_printLine_("   usage:");
+	_printLine_("   [segments]=MeshProfileIntersection(index,x,y,filename);");
+	_printLine_("   where:");
+	_printLine_("   input:");
+	_printLine_("        index,x,y is a triangulation");
+	_printLine_("        filename: name of Argus style .exp file containing the segments (can be groups of disconnected segments)");
+	_printLine_("   output:");
+	_printLine_("        segments: array made of x1,y1,x2,y2,element_id lines (x1,y1) and (x2,y2) are segment extremitis for a segment ");
+	_printLine_("        belonging to the elemnt_id element. there are as many lines in segments as there are segments intersecting the ");
+	_printLine_("        mesh.");
+}/*}}}*/
+WRAPPER(MeshProfileIntersection){
 
 	int i,j;
 
@@ -99,16 +111,3 @@
 	MODULEEND();
 
 }
-
-void MeshProfileIntersectionUsage(void){
-	_printLine_("   usage:");
-	_printLine_("   [segments]=MeshProfileIntersection(index,x,y,filename);");
-	_printLine_("   where:");
-	_printLine_("   input:");
-	_printLine_("        index,x,y is a triangulation");
-	_printLine_("        filename: name of Argus style .exp file containing the segments (can be groups of disconnected segments)");
-	_printLine_("   output:");
-	_printLine_("        segments: array made of x1,y1,x2,y2,element_id lines (x1,y1) and (x2,y2) are segment extremitis for a segment ");
-	_printLine_("        belonging to the elemnt_id element. there are as many lines in segments as there are segments intersecting the ");
-	_printLine_("        mesh.");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshProfileIntersection/MeshProfileIntersection.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshProfileIntersection/MeshProfileIntersection.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshProfileIntersection/MeshProfileIntersection.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void MeshProfileIntersectionUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void InterpFromMeshToMesh3dUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.cpp	(revision 13236)
@@ -1,26 +1,31 @@
 /*!\file InterpFromMeshToMesh3d.c
  * \brief: data interpolation from a list of (x,y,values) into mesh vertices
- 
-	InterpFromMeshToMesh3d.c
-
-	usage:
-	data_mesh=InterpFromMeshToMesh3d(index,x,y,z,data,x_mesh,y_mesh,z_mesh);
-	
-	where:
-
-		input:
-		x,y,z: coordinates of matrix data
-		data - matrix holding the data to be interpolated onto the mesh.
-		x_mesh,y_mesh,z_mesh: coordinates of the mesh vertices onto which we interpolate.
-		
-		output: 
-		data_mesh:  vector of mesh interpolated data.
-
 */
 	
 #include "./InterpFromMeshToMesh3d.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) {
+void InterpFromMeshToMesh3dUsage(void){/*{{{*/
+	_pprintLine_("INTERPFROMMESHTOMESH3D - interpolation from a 3d hexahedron mesh onto a list of point");
+	_pprintLine_("");
+	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
+	_pprintLine_("   defined on a triangular mesh onto a list of point");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      data_prime=InterpFromMeshToMesh3d(index,x,y,z,data,x_prime,y_prime,z_prime,default_value);");
+	_pprintLine_("");
+	_pprintLine_("      index: index of the mesh where data is defined");
+	_pprintLine_("      x,y,z: coordinates of the nodes where data is defined");
+	_pprintLine_("      data: matrix holding the data to be interpolated onto the mesh.");
+	_pprintLine_("      x_prime,y_prime,z_prime: coordinates of the points onto which we interpolate.");
+	_pprintLine_("      default_value: default value if no data is found (holes).");
+	_pprintLine_("      data_prime: vector of mesh interpolated data.");
+	_pprintLine_("");
+	_pprintLine_("   Example:");
+	_pprintLine_("      load('temperature.mat');");
+	_pprintLine_("      md.initialization.temperature=InterpFromMeshToMesh3d(index,x,y,z,temperature,md.mesh.x,md.mesh.y,md.mesh.z,253);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(InterpFromMeshToMesh3d){
 
 	/*input: */
 	double* index_data=NULL;
@@ -94,25 +99,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void InterpFromMeshToMesh3dUsage(void){
-	_pprintLine_("INTERPFROMMESHTOMESH3D - interpolation from a 3d hexahedron mesh onto a list of point");
-	_pprintLine_("");
-	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
-	_pprintLine_("   defined on a triangular mesh onto a list of point");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      data_prime=InterpFromMeshToMesh3d(index,x,y,z,data,x_prime,y_prime,z_prime,default_value);");
-	_pprintLine_("");
-	_pprintLine_("      index: index of the mesh where data is defined");
-	_pprintLine_("      x,y,z: coordinates of the nodes where data is defined");
-	_pprintLine_("      data: matrix holding the data to be interpolated onto the mesh.");
-	_pprintLine_("      x_prime,y_prime,z_prime: coordinates of the points onto which we interpolate.");
-	_pprintLine_("      default_value: default value if no data is found (holes).");
-	_pprintLine_("      data_prime: vector of mesh interpolated data.");
-	_pprintLine_("");
-	_pprintLine_("   Example:");
-	_pprintLine_("      load('temperature.mat');");
-	_pprintLine_("      md.initialization.temperature=InterpFromMeshToMesh3d(index,x,y,z,temperature,md.mesh.x,md.mesh.y,md.mesh.z,253);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Ll2xy/Ll2xy.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Ll2xy/Ll2xy.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Ll2xy/Ll2xy.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void Ll2xyUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Ll2xy/Ll2xy.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Ll2xy/Ll2xy.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Ll2xy/Ll2xy.cpp	(revision 13236)
@@ -3,7 +3,31 @@
  */
 #include "./Ll2xy.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void Ll2xyUsage(void){/*{{{*/
+	_pprintLine_("Ll2xy - lat/long to x/y coordinate transformation module:");
+	_pprintLine_("");
+	_pprintLine_("   This module transforms lat/long to x/y coordinates.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [x,y]=Ll2xy(lat,lon,sgn,'param name',param,...);");
+	_pprintLine_("");
+	_pprintLine_("      lat         latitude coordinates (double vector)");
+	_pprintLine_("      lon         longitude coordinates (double vector)");
+	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
+	_pprintLine_("");
+	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
+	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
+	_pprintLine_("");
+	_pprintLine_("      x           x coordinates (double vector)");
+	_pprintLine_("      y           y coordinates (double vector)");
+	_pprintLine_("");
+	_pprintLine_("   Examples:");
+	_pprintLine_("      [x,y]=Ll2xy(lat,lon, 1);");
+	_pprintLine_("      [x,y]=Ll2xy(lat,lon, 1,'central_meridian',45,'standard_parallel',70);");
+	_pprintLine_("      [x,y]=Ll2xy(lat,lon,-1,'central_meridian', 0,'standard_parallel',71);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(Ll2xy){
 
 	int i,verbose=1;
 
@@ -71,28 +95,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void Ll2xyUsage(void){
-	_pprintLine_("Ll2xy - lat/long to x/y coordinate transformation module:");
-	_pprintLine_("");
-	_pprintLine_("   This module transforms lat/long to x/y coordinates.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [x,y]=Ll2xy(lat,lon,sgn,'param name',param,...);");
-	_pprintLine_("");
-	_pprintLine_("      lat         latitude coordinates (double vector)");
-	_pprintLine_("      lon         longitude coordinates (double vector)");
-	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
-	_pprintLine_("");
-	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
-	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
-	_pprintLine_("");
-	_pprintLine_("      x           x coordinates (double vector)");
-	_pprintLine_("      y           y coordinates (double vector)");
-	_pprintLine_("");
-	_pprintLine_("   Examples:");
-	_pprintLine_("      [x,y]=Ll2xy(lat,lon, 1);");
-	_pprintLine_("      [x,y]=Ll2xy(lat,lon, 1,'central_meridian',45,'standard_parallel',70);");
-	_pprintLine_("      [x,y]=Ll2xy(lat,lon,-1,'central_meridian', 0,'standard_parallel',71);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgMesher/BamgMesher.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgMesher/BamgMesher.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgMesher/BamgMesher.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void BamgMesherUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgMesher/BamgMesher.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgMesher/BamgMesher.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgMesher/BamgMesher.cpp	(revision 13236)
@@ -3,7 +3,12 @@
  */
 #include "./BamgMesher.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void BamgMesherUsage(void){/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("   usage: [bamgmesh,bamggeom]=" << __FUNCT__ << "(bamgmesh,bamggeom,bamgoptions);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(BamgMesher){
 
 	/*Outputs*/
 	mxArray* bamgmesh_mat=NULL;
@@ -48,9 +53,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void BamgMesherUsage(void){
-	_pprintLine_("");
-	_pprintLine_("   usage: [bamgmesh,bamggeom]=" << __FUNCT__ << "(bamgmesh,bamggeom,bamgoptions);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromGridToMesh/InterpFromGridToMesh.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromGridToMesh/InterpFromGridToMesh.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromGridToMesh/InterpFromGridToMesh.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void InterpFromGridToMeshUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromGridToMesh/InterpFromGridToMesh.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromGridToMesh/InterpFromGridToMesh.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromGridToMesh/InterpFromGridToMesh.cpp	(revision 13236)
@@ -1,25 +1,30 @@
 /*!\file InterpFromGridToMesh.c
  * \brief: data interpolation from a list of (x,y,values) into mesh vertices
- 
-	InterpFromGridToMesh.c
-
-	usage:
-	data_mesh=InterpFromGridToMesh(x,y,data,x_mesh,y_mesh);
-	
-	where:
-
-		input:
-		x,y: coordinates of matrix data
-		data - matrix holding the data to be interpolated onto the mesh.
-		x_mesh,y_mesh: coordinates of the mesh vertices onto which we interpolate.
-		
-		output: 
-		data_mesh:  vector of mesh interpolated data.
 */
 	
 #include "./InterpFromGridToMesh.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) {
+void InterpFromGridToMeshUsage(void){/*{{{*/
+	_pprintLine_("INTERPFROMGRIDTOMESH - interpolation from a grid onto a list of points");
+	_pprintLine_("");
+	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
+	_pprintLine_("   defined on a grid onto a list of points");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      data_mesh=InterpFromGridToMesh(x,y,data,x_mesh,y_mesh,default_value);");
+	_pprintLine_("");
+	_pprintLine_("      data: matrix holding the data to be interpolated onto the mesh.");
+	_pprintLine_("      x,y: coordinates of matrix data. (x and y must be in increasing order)");
+	_pprintLine_("      x_mesh,y_mesh: coordinates of the points onto which we interpolate.");
+	_pprintLine_("      default_value: default value if no data is found (holes).");
+	_pprintLine_("      data_mesh: vector of mesh interpolated data.");
+	_pprintLine_("");
+	_pprintLine_("   Example:");
+	_pprintLine_("      load('velocities.mat');");
+	_pprintLine_("      md.inversion.vx_obs=InterpFromGridToMesh(x_n,y_m,vx,md.mesh.x,md.mesh.y,0);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(InterpFromGridToMesh){
 
 	int i,j;
 
@@ -70,25 +75,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void InterpFromGridToMeshUsage(void)
-{
-	_pprintLine_("INTERPFROMGRIDTOMESH - interpolation from a grid onto a list of points");
-	_pprintLine_("");
-	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
-	_pprintLine_("   defined on a grid onto a list of points");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      data_mesh=InterpFromGridToMesh(x,y,data,x_mesh,y_mesh,default_value);");
-	_pprintLine_("");
-	_pprintLine_("      data: matrix holding the data to be interpolated onto the mesh.");
-	_pprintLine_("      x,y: coordinates of matrix data. (x and y must be in increasing order)");
-	_pprintLine_("      x_mesh,y_mesh: coordinates of the points onto which we interpolate.");
-	_pprintLine_("      default_value: default value if no data is found (holes).");
-	_pprintLine_("      data_mesh: vector of mesh interpolated data.");
-	_pprintLine_("");
-	_pprintLine_("   Example:");
-	_pprintLine_("      load('velocities.mat');");
-	_pprintLine_("      md.inversion.vx_obs=InterpFromGridToMesh(x_n,y_m,vx,md.mesh.x,md.mesh.y,0);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToGrid/InterpFromMeshToGrid.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToGrid/InterpFromMeshToGrid.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToGrid/InterpFromMeshToGrid.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void InterpFromMeshToGridUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToGrid/InterpFromMeshToGrid.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToGrid/InterpFromMeshToGrid.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToGrid/InterpFromMeshToGrid.cpp	(revision 13236)
@@ -4,7 +4,22 @@
 
 #include "./InterpFromMeshToGrid.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void InterpFromMeshToGridUsage(void){/*{{{*/
+	_pprintLine_("INTERPFROMMESHTOGRID - interpolation of a data defined on a mesh onto a grid");
+	_pprintLine_("");
+	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
+	_pprintLine_("   defined on a triangular mesh onto a regular grid");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [x_m,y_m,griddata]=InterpFromMeshToGrid(index,x,y,data,xmin,ymax,xposting,yposting,nlines,ncols,default_value)");
+	_pprintLine_("");
+	_pprintLine_("      index,x,y: delaunay triangulation defining the mesh.");
+	_pprintLine_("      meshdata: vertex values of data to be interpolated.");
+	_pprintLine_("      xmin,ymax,posting,nlines,ncols: parameters that define the grid");
+	_pprintLine_("      default_value: value of points located out of the mesh.");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(InterpFromMeshToGrid){
 
 	/*input datasets: */
 	double* index=NULL;
@@ -60,20 +75,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void InterpFromMeshToGridUsage(void)
-{
-	_pprintLine_("INTERPFROMMESHTOGRID - interpolation of a data defined on a mesh onto a grid");
-	_pprintLine_("");
-	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
-	_pprintLine_("   defined on a triangular mesh onto a regular grid");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [x_m,y_m,griddata]=InterpFromMeshToGrid(index,x,y,data,xmin,ymax,xposting,yposting,nlines,ncols,default_value)");
-	_pprintLine_("");
-	_pprintLine_("      index,x,y: delaunay triangulation defining the mesh.");
-	_pprintLine_("      meshdata: vertex values of data to be interpolated.");
-	_pprintLine_("      xmin,ymax,posting,nlines,ncols: parameters that define the grid");
-	_pprintLine_("      default_value: value of points located out of the mesh.");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLFileRead/KMLFileRead.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLFileRead/KMLFileRead.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLFileRead/KMLFileRead.cpp	(revision 13236)
@@ -3,7 +3,28 @@
  */
 #include "./KMLFileRead.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void KMLFileReadUsage(void){/*{{{*/
+	_pprintLine_("KMLFileRead - KML file reader module:");
+	_pprintLine_("");
+	_pprintLine_("   This module reads a KML file.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [ierror]=KMLFileRead(kmlfile,'param name',param,...);");
+	_pprintLine_("");
+	_pprintLine_("      kmlfile      file name of kml file to be read (char)");
+	_pprintLine_("");
+	_pprintLine_("      echo         echo command (char, optional, 'off'/'on')");
+	_pprintLine_("      deepecho     deep echo command (char, optional, 'off'/'on')");
+	_pprintLine_("      write        write command (char, optional, 'off'/'stdout'/kmlfile)");
+	_pprintLine_("");
+	_pprintLine_("      ierror       return code (non-zero for error)");
+	_pprintLine_("");
+	_pprintLine_("   Examples:");
+	_pprintLine_("      [ierror]=KMLFileRead('file.kml','deepecho','on');");
+	_pprintLine_("      [ierror]=KMLFileRead('filin.kml','echo','on','write','filout.kml');");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(KMLFileRead){
 
 	int i,j,nnodes=0,verbose=1;
 	KML_Object* kobj;
@@ -104,26 +125,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void KMLFileReadUsage(void){
-	_pprintLine_("KMLFileRead - KML file reader module:");
-	_pprintLine_("");
-	_pprintLine_("   This module reads a KML file.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [ierror]=KMLFileRead(kmlfile,'param name',param,...);");
-	_pprintLine_("");
-	_pprintLine_("      kmlfile      file name of kml file to be read (char)");
-	_pprintLine_("");
-	_pprintLine_("      echo         echo command (char, optional, 'off'/'on')");
-	_pprintLine_("      deepecho     deep echo command (char, optional, 'off'/'on')");
-	_pprintLine_("      write        write command (char, optional, 'off'/'stdout'/kmlfile)");
-	_pprintLine_("");
-	_pprintLine_("      ierror       return code (non-zero for error)");
-	_pprintLine_("");
-	_pprintLine_("   Examples:");
-	_pprintLine_("      [ierror]=KMLFileRead('file.kml','deepecho','on');");
-	_pprintLine_("      [ierror]=KMLFileRead('filin.kml','echo','on','write','filout.kml');");
-	_pprintLine_("");
-}
-
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLFileRead/KMLFileRead.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLFileRead/KMLFileRead.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLFileRead/KMLFileRead.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void KMLFileReadUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Shp2Kml/Shp2Kml.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Shp2Kml/Shp2Kml.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Shp2Kml/Shp2Kml.cpp	(revision 13236)
@@ -10,7 +10,30 @@
 
 #include "./Shp2Kml.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void Shp2KmlUsage(void){/*{{{*/
+	_pprintLine_("Shp2Kml - shp to kml file conversion module:");
+	_pprintLine_("");
+	_pprintLine_("   This module converts a file from shp to kml format.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [ret]=Shp2Kml(filshp,filkml,sgn,'param name',param,...);");
+	_pprintLine_("");
+	_pprintLine_("      filshp      file name of shp file to be read (char, extension optional)");
+	_pprintLine_("      filkml      file name of kml file to be written (char)");
+	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north); -1 (south); or 0 (no translation))");
+	_pprintLine_("");
+	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
+	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
+	_pprintLine_("");
+	_pprintLine_("      ret         return code (non-zero for warning)");
+	_pprintLine_("");
+	_pprintLine_("   Examples:");
+	_pprintLine_("      [ret]=Shp2Kml('file.shp','file.kml', 0);");
+	_pprintLine_("      [ret]=Shp2Kml('file.shp','file.kml', 1,'central_meridian',45,'standard_parallel',70);");
+	_pprintLine_("      [ret]=Shp2Kml('file.shp','file.kml',-1,'central_meridian', 0,'standard_parallel',71);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(Shp2Kml){
 
 	int i,verbose=1;
 
@@ -74,27 +97,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void Shp2KmlUsage(void){
-	_pprintLine_("Shp2Kml - shp to kml file conversion module:");
-	_pprintLine_("");
-	_pprintLine_("   This module converts a file from shp to kml format.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [ret]=Shp2Kml(filshp,filkml,sgn,'param name',param,...);");
-	_pprintLine_("");
-	_pprintLine_("      filshp      file name of shp file to be read (char, extension optional)");
-	_pprintLine_("      filkml      file name of kml file to be written (char)");
-	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north); -1 (south); or 0 (no translation))");
-	_pprintLine_("");
-	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
-	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
-	_pprintLine_("");
-	_pprintLine_("      ret         return code (non-zero for warning)");
-	_pprintLine_("");
-	_pprintLine_("   Examples:");
-	_pprintLine_("      [ret]=Shp2Kml('file.shp','file.kml', 0);");
-	_pprintLine_("      [ret]=Shp2Kml('file.shp','file.kml', 1,'central_meridian',45,'standard_parallel',70);");
-	_pprintLine_("      [ret]=Shp2Kml('file.shp','file.kml',-1,'central_meridian', 0,'standard_parallel',71);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Shp2Kml/Shp2Kml.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Shp2Kml/Shp2Kml.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Shp2Kml/Shp2Kml.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void Shp2KmlUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/AverageFilter/AverageFilter.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/AverageFilter/AverageFilter.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/AverageFilter/AverageFilter.cpp	(revision 13236)
@@ -9,12 +9,18 @@
 	using double arrays found in the workspace, and loaded directly into memory.
 */
 
-
 #include "./AverageFilter.h"
 
-void mexFunction( int nlhs, mxArray* plhs[],
-				  int nrhs, const mxArray* prhs[])
-{
+void AverageFilterUsage(void){/*{{{*/
+	_printLine_("   AverageFilter usage:");
+	_printLine_("   [image_out]=AverageFilter(image_in,pixels);\n");
+	_printLine_("   where:");
+	_printLine_("      image_in in double format");
+	_printLine_("      pixels: characteristic size of smoothing");
+	_printLine_("      image_out in double format");
+	_printLine_("");
+}/*}}}*/
+WRAPPER(AverageFilter){
 
 	int i,j;
 
@@ -48,15 +54,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-
-void AverageFilterUsage(void)
-{
-	_printLine_("   AverageFilter usage:");
-	_printLine_("   [image_out]=AverageFilter(image_in,pixels);\n");
-	_printLine_("   where:");
-	_printLine_("      image_in in double format");
-	_printLine_("      pixels: characteristic size of smoothing");
-	_printLine_("      image_out in double format");
-	_printLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/AverageFilter/AverageFilter.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/AverageFilter/AverageFilter.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/AverageFilter/AverageFilter.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void AverageFilterUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMeshProcessRifts/TriMeshProcessRifts.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMeshProcessRifts/TriMeshProcessRifts.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMeshProcessRifts/TriMeshProcessRifts.cpp	(revision 13236)
@@ -4,7 +4,13 @@
 
 #include "./TriMeshProcessRifts.h"
 
-void mexFunction(	int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[] ){
+void TriMeshProcessRiftsUsage(void){/*{{{*/
+	_printLine_("");
+	_printLine_("   usage: [index2,x2,y2,segments2,segmentmarkers2,rifts2]=TriMeshProcessrifts(index1,x1,y1,segments1,segmentmarkers1) ");
+	_printLine_("      where: (index1,x1,y1,segments1,segmentmarkers1) is an initial triangulation.");
+	_printLine_("      index2,x2,y2,segments2,segmentmarkers2,rifts2 is the resulting triangulation where rifts have been processed.");
+}/*}}}*/
+WRAPPER(TriMeshProcessRifts){
 
 	/*Matlab arrays: */
 	mxArray *pmxa_array  = NULL;
@@ -244,10 +250,3 @@
 
 	return;
 }
-
-void TriMeshProcessRiftsUsage(void){
-	_printLine_("");
-	_printLine_("   usage: [index2,x2,y2,segments2,segmentmarkers2,rifts2]=TriMeshProcessrifts(index1,x1,y1,segments1,segmentmarkers1) ");
-	_printLine_("      where: (index1,x1,y1,segments1,segmentmarkers1) is an initial triangulation.");
-	_printLine_("      index2,x2,y2,segments2,segmentmarkers2,rifts2 is the resulting triangulation where rifts have been processed.");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMeshProcessRifts/TriMeshProcessRifts.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMeshProcessRifts/TriMeshProcessRifts.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMeshProcessRifts/TriMeshProcessRifts.h	(revision 13236)
@@ -8,7 +8,6 @@
 #include "mex.h"
 #include "triangle.h"
 #include "string.h"
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
@@ -16,7 +15,6 @@
 #include "../../c/issm-binding.h"
 #include "../../c/EnumDefinitions/EnumDefinitions.h"
 
-void TriMeshProcessRiftsUsage(void);
 #undef __FUNCT__ 
 #define __FUNCT__ "TriMeshProcessRifts"
 
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Exp2Kml/Exp2Kml.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Exp2Kml/Exp2Kml.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Exp2Kml/Exp2Kml.cpp	(revision 13236)
@@ -3,7 +3,31 @@
  */
 #include "./Exp2Kml.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void Exp2KmlUsage(void){/*{{{*/
+	_pprintLine_("Exp2Kml - exp to kml file conversion module:");
+	_pprintLine_("");
+	_pprintLine_("   This module converts a file from exp to kml format.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [ret]=Exp2Kml(filexp,filkml,sgn,'param name',param,...);");
+	_pprintLine_("");
+	_pprintLine_("      filexp      file name of exp file to be read (char)");
+	_pprintLine_("      filkml      file name of kml file to be written (char)");
+	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
+	_pprintLine_("");
+	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
+	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
+	_pprintLine_("      holes       flag for treatment of multiple profiles (char, optional, 'yes' for holes))");
+	_pprintLine_("");
+	_pprintLine_("      ret         return code (non-zero for warning)");
+	_pprintLine_("");
+	_pprintLine_("   Examples:");
+	_pprintLine_("      [ret]=Exp2Kml('file.exp','file.kml', 1);");
+	_pprintLine_("      [ret]=Exp2Kml('file.exp','file.kml', 1,'central_meridian',45,'standard_parallel',70,'holes','yes');");
+	_pprintLine_("      [ret]=Exp2Kml('file.exp','file.kml',-1,'central_meridian', 0,'standard_parallel',71,'holes','yes');");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(Exp2Kml){
 
 	int i,verbose=1;
 
@@ -70,29 +94,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void Exp2KmlUsage(void){
-	_pprintLine_("Exp2Kml - exp to kml file conversion module:");
-	_pprintLine_("");
-	_pprintLine_("   This module converts a file from exp to kml format.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [ret]=Exp2Kml(filexp,filkml,sgn,'param name',param,...);");
-	_pprintLine_("");
-	_pprintLine_("      filexp      file name of exp file to be read (char)");
-	_pprintLine_("      filkml      file name of kml file to be written (char)");
-	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
-	_pprintLine_("");
-	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
-	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
-	_pprintLine_("      holes       flag for treatment of multiple profiles (char, optional, 'yes' for holes))");
-	_pprintLine_("");
-	_pprintLine_("      ret         return code (non-zero for warning)");
-	_pprintLine_("");
-	_pprintLine_("   Examples:");
-	_pprintLine_("      [ret]=Exp2Kml('file.exp','file.kml', 1);");
-	_pprintLine_("      [ret]=Exp2Kml('file.exp','file.kml', 1,'central_meridian',45,'standard_parallel',70,'holes','yes');");
-	_pprintLine_("      [ret]=Exp2Kml('file.exp','file.kml',-1,'central_meridian', 0,'standard_parallel',71,'holes','yes');");
-	_pprintLine_("");
-}
-
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Exp2Kml/Exp2Kml.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Exp2Kml/Exp2Kml.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Exp2Kml/Exp2Kml.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void Exp2KmlUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kml2Exp/Kml2Exp.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kml2Exp/Kml2Exp.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kml2Exp/Kml2Exp.cpp	(revision 13236)
@@ -3,7 +3,30 @@
  */
 #include "./Kml2Exp.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void Kml2ExpUsage(void){/*{{{*/
+	_pprintLine_("Kml2Exp - kml to exp file conversion module:");
+	_pprintLine_("");
+	_pprintLine_("   This module converts a file from kml to exp format.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [ret]=Kml2Exp(filexp,filkml,sgn,'param name',param,...);");
+	_pprintLine_("");
+	_pprintLine_("      filkml      file name of kml file to be read (char)");
+	_pprintLine_("      filexp      file name of exp file to be written (char)");
+	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
+	_pprintLine_("");
+	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
+	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
+	_pprintLine_("");
+	_pprintLine_("      ret         return code (non-zero for warning)");
+	_pprintLine_("");
+	_pprintLine_("   Examples:");
+	_pprintLine_("      [ret]=Kml2Exp('file.kml','file.exp', 1);");
+	_pprintLine_("      [ret]=Kml2Exp('file.kml','file.exp', 1,'central_meridian',45,'standard_parallel',70);");
+	_pprintLine_("      [ret]=Kml2Exp('file.kml','file.exp',-1,'central_meridian', 0,'standard_parallel',71);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(Kml2Exp){
 
 	int i,verbose=1;
 
@@ -63,28 +86,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void Kml2ExpUsage(void){
-	_pprintLine_("Kml2Exp - kml to exp file conversion module:");
-	_pprintLine_("");
-	_pprintLine_("   This module converts a file from kml to exp format.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [ret]=Kml2Exp(filexp,filkml,sgn,'param name',param,...);");
-	_pprintLine_("");
-	_pprintLine_("      filkml      file name of kml file to be read (char)");
-	_pprintLine_("      filexp      file name of exp file to be written (char)");
-	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
-	_pprintLine_("");
-	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
-	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
-	_pprintLine_("");
-	_pprintLine_("      ret         return code (non-zero for warning)");
-	_pprintLine_("");
-	_pprintLine_("   Examples:");
-	_pprintLine_("      [ret]=Kml2Exp('file.kml','file.exp', 1);");
-	_pprintLine_("      [ret]=Kml2Exp('file.kml','file.exp', 1,'central_meridian',45,'standard_parallel',70);");
-	_pprintLine_("      [ret]=Kml2Exp('file.kml','file.exp',-1,'central_meridian', 0,'standard_parallel',71);");
-	_pprintLine_("");
-}
-
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kml2Exp/Kml2Exp.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kml2Exp/Kml2Exp.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kml2Exp/Kml2Exp.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void Kml2ExpUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PointCloudFindNeighbors/PointCloudFindNeighbors.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PointCloudFindNeighbors/PointCloudFindNeighbors.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PointCloudFindNeighbors/PointCloudFindNeighbors.cpp	(revision 13236)
@@ -4,7 +4,17 @@
 	
 #include "./PointCloudFindNeighbors.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) {
+void PointCloudFindNeighborsUsage(void){/*{{{*/
+	_printLine_("   usage:");
+	_printLine_("   [flags]=PointCloudFindNeighbors(x,y,mindistance,multithread);\n");
+	_printLine_("   where:");
+	_printLine_("      x,y: list of points.");
+	_printLine_("      mindistance: minimum distance that should exist between points in the cloud.");
+	_printLine_("      multithread: run multithreaded or not. with multithreads, flags can get 1 and 2 values in duplicates.");
+	_printLine_("      flags: array of flags (flag==1 means point is within mindistance of another point)");
+	_printLine_("");
+}/*}}}*/
+WRAPPER(PointCloudFindNeighbors){
 
 	int i,j;
 
@@ -39,14 +49,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void PointCloudFindNeighborsUsage(void){
-	_printLine_("   usage:");
-	_printLine_("   [flags]=PointCloudFindNeighbors(x,y,mindistance,multithread);\n");
-	_printLine_("   where:");
-	_printLine_("      x,y: list of points.");
-	_printLine_("      mindistance: minimum distance that should exist between points in the cloud.");
-	_printLine_("      multithread: run multithreaded or not. with multithreads, flags can get 1 and 2 values in duplicates.");
-	_printLine_("      flags: array of flags (flag==1 means point is within mindistance of another point)");
-	_printLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PointCloudFindNeighbors/PointCloudFindNeighbors.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PointCloudFindNeighbors/PointCloudFindNeighbors.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PointCloudFindNeighbors/PointCloudFindNeighbors.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void PointCloudFindNeighborsUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.cpp	(revision 13236)
@@ -4,7 +4,12 @@
 
 #include "./PropagateFlagsFromConnectivity.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void PropagateFlagsFromConnectivityUsage(void) {/*{{{*/
+	_printLine_("");
+	_printLine_("   usage: [pool] = " << __FUNCT__ << "(connectivity,pool,index,flags);");;
+	_printLine_("");
+}/*}}}*/
+WRAPPER(PropagateFlagsFromConnectivity){
 
 	/*input/output datasets: */
 	double* connectivity=NULL;
@@ -39,9 +44,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void PropagateFlagsFromConnectivityUsage(void) {
-	_printLine_("");
-	_printLine_("   usage: [pool] = " << __FUNCT__ << "(connectivity,pool,index,flags);");;
-	_printLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void PropagateFlagsFromConnectivityUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriaSearch/TriaSearch.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriaSearch/TriaSearch.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriaSearch/TriaSearch.cpp	(revision 13236)
@@ -3,7 +3,17 @@
  */
 #include "./TriaSearch.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void TriaSearchUsage(void){/*{{{*/
+	_pprintLine_("TriaSearch- find triangle holding a point (x0,y0) in a mesh");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("         tria=TriaSearch(index,x,y,x0,y0);");
+	_pprintLine_("      index,x,y: mesh triangulatrion");
+	_pprintLine_("      x0,y0: coordinates of the point for which we are trying to find a triangle");
+	_pprintLine_("      x0,y0 can be an array of points");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(TriaSearch){
 
 	int i;
 
@@ -48,14 +58,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void TriaSearchUsage(void){
-	_pprintLine_("TriaSearch- find triangle holding a point (x0,y0) in a mesh");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("         tria=TriaSearch(index,x,y,x0,y0);");
-	_pprintLine_("      index,x,y: mesh triangulatrion");
-	_pprintLine_("      x0,y0: coordinates of the point for which we are trying to find a triangle");
-	_pprintLine_("      x0,y0 can be an array of points");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriaSearch/TriaSearch.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriaSearch/TriaSearch.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriaSearch/TriaSearch.h	(revision 13236)
@@ -15,9 +15,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void TriaSearchUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InternalFront/InternalFront.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InternalFront/InternalFront.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InternalFront/InternalFront.cpp	(revision 13236)
@@ -4,7 +4,12 @@
 
 #include "./InternalFront.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void InternalFrontUsage(void) {/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("   usage: icefront = " << __FUNCT__ << "(md);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(InternalFront){
 
 	bool*   elementonwater=NULL;
 	int*    elements=NULL;
@@ -91,9 +96,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void InternalFrontUsage(void) {
-	_pprintLine_("");
-	_pprintLine_("   usage: icefront = " << __FUNCT__ << "(md);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InternalFront/InternalFront.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InternalFront/InternalFront.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InternalFront/InternalFront.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void InternalFrontUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/shared/shared.h"
 #include "../../c/issm-binding.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshPartition/MeshPartition.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshPartition/MeshPartition.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshPartition/MeshPartition.cpp	(revision 13236)
@@ -1,30 +1,19 @@
 /*!\file:  MeshPartition.cpp
  * \brief: partition mesh according to number of areas, using Metis library.
-
-	usage:
-	[element_partitioning,node_partitioning]=MeshPartition(model,numareas)
-	
-	%Info needed from model are the following: 
-	%mesh info: 
-	numberofelements,numberofvertices,elements,elements_width
-	%Non-extruded 2d mesh info
-	nel2d,nods2d,elements2d,
-	%Extruded 2d mesh info
-	nel2d_ext,nods2d_ext,elements2d_ext,
-	%Diverse
-	numberoflayers,dim)
-
-	output:
-	vector of partitioning area numbers, for every element.
-	vector of partitioning area numbers, for every node.
 */
 	
 #include "./MeshPartition.h"
 
+void MeshPartitionUsage(void){/*{{{*/
+	_printLine_("   usage:");
+	_printString_("   [element_partitioning,node_partitioning]=MeshPartition(md.mesh,numpartitions)");
+	_printLine_("   where:");
+	_printLine_("      element_partitioning is a vector of partitioning area numbers, for every element.");
+	_printLine_("      node_partitioning is a vector of partitioning area numbers, for every node.");
+	_printLine_("");
+}/*}}}*/
+WRAPPER(MeshPartition){
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) {
-
-
 	/*Indexing: */
 	int i,j;
 
@@ -93,12 +82,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void MeshPartitionUsage(void){
-	_printLine_("   usage:");
-	_printString_("   [element_partitioning,node_partitioning]=MeshPartition(md.mesh,numpartitions)");
-	_printLine_("   where:");
-	_printLine_("      element_partitioning is a vector of partitioning area numbers, for every element.");
-	_printLine_("      node_partitioning is a vector of partitioning area numbers, for every node.");
-	_printLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshPartition/MeshPartition.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshPartition/MeshPartition.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/MeshPartition/MeshPartition.h	(revision 13236)
@@ -16,18 +16,12 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void MeshPartitionUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
 #include "../../c/shared/shared.h"
 #include "../../c/issm-binding.h"
 
-#undef CLEANUP
-#define CLEANUP MeshPartitionLocalCleanup();
-
 #undef __FUNCT__ 
 #define __FUNCT__  "MeshPartition"
 
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMesh2d/InterpFromMesh2d.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMesh2d/InterpFromMesh2d.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMesh2d/InterpFromMesh2d.cpp	(revision 13236)
@@ -4,7 +4,22 @@
 	
 #include "./InterpFromMesh2d.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) {
+void InterpFromMesh2dUsage(void){/*{{{*/
+	_pprintLine_("   usage:");
+	_pprintLine_("         data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime);\n");
+	_pprintLine_("      or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value);\n");
+	_pprintLine_("      or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value,contourname);\n");
+	_pprintLine_("   where:");
+	_pprintLine_("      x,y: coordinates of the nodes where data is defined");
+	_pprintLine_("      index: index of the mesh where data is defined");
+	_pprintLine_("      data - vector holding the data to be interpolated onto the points.");
+	_pprintLine_("      x_prime,y_prime: coordinates of the mesh vertices onto which we interpolate.");
+	_pprintLine_("      default_value: a scalar or vector of size length(x_prime).");
+	_pprintLine_("      contourname: linear interpolation will happen on all x_interp,y_interp inside the contour, default value will be adopted on the rest of the mesh.");
+	_pprintLine_("      data_prime:  vector of prime interpolated data.");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(InterpFromMesh2d){
 
 	/*input: */
 	double* index_data=NULL;
@@ -134,20 +149,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void InterpFromMesh2dUsage(void)
-{
-	_pprintLine_("   usage:");
-	_pprintLine_("         data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime);\n");
-	_pprintLine_("      or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value);\n");
-	_pprintLine_("      or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value,contourname);\n");
-	_pprintLine_("   where:");
-	_pprintLine_("      x,y: coordinates of the nodes where data is defined");
-	_pprintLine_("      index: index of the mesh where data is defined");
-	_pprintLine_("      data - vector holding the data to be interpolated onto the points.");
-	_pprintLine_("      x_prime,y_prime: coordinates of the mesh vertices onto which we interpolate.");
-	_pprintLine_("      default_value: a scalar or vector of size length(x_prime).");
-	_pprintLine_("      contourname: linear interpolation will happen on all x_interp,y_interp inside the contour, default value will be adopted on the rest of the mesh.");
-	_pprintLine_("      data_prime:  vector of prime interpolated data.");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMesh2d/InterpFromMesh2d.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMesh2d/InterpFromMesh2d.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMesh2d/InterpFromMesh2d.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void InterpFromMesh2dUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ElementConnectivity/ElementConnectivity.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ElementConnectivity/ElementConnectivity.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ElementConnectivity/ElementConnectivity.cpp	(revision 13236)
@@ -4,6 +4,11 @@
 
 #include "./ElementConnectivity.h"
 
+void ElementConnectivityUsage(void) {/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("   usage: elementconnectivity = " << __FUNCT__ << "(elements, nodeconnectivity);");
+	_pprintLine_("");
+}/*}}}*/
 WRAPPER(ElementConnectivity){
 
 	/*inputs: */
@@ -34,9 +39,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void ElementConnectivityUsage(void) {
-	_pprintLine_("");
-	_pprintLine_("   usage: elementconnectivity = " << __FUNCT__ << "(elements, nodeconnectivity);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ElementConnectivity/ElementConnectivity.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ElementConnectivity/ElementConnectivity.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ElementConnectivity/ElementConnectivity.h	(revision 13236)
@@ -52,7 +52,4 @@
 #undef NRHS
 #define NRHS  2
 
-/* local prototypes: */
-void ElementConnectivityUsage(void);
-
 #endif  /* _ELEMENTCONNECTIVITY_H */
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kriging/Kriging.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kriging/Kriging.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kriging/Kriging.h	(revision 13236)
@@ -1,5 +1,5 @@
 /*
-	KrigingUsage.h
+	Kriging.h
 */
 
 #ifndef _KRIGING_H_
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void KrigingUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/shared/shared.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kriging/Kriging.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kriging/Kriging.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Kriging/Kriging.cpp	(revision 13236)
@@ -3,7 +3,26 @@
  */
 #include "./Kriging.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void KrigingUsage(void){/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("   usage: predictions=" << __FUNCT__ << "(x,y,observations,x_interp,y_interp,'options');");
+	_pprintLine_("   available options:");
+	_pprintLine_("      -'model': Available variogram models 'gaussian' (default),'spherical','power','exponential'");
+	_pprintLine_("         -'nugget': nugget effect (default 0.2)");
+	_pprintLine_("         -'range':  for gaussian, spherical and exponential models (default sqrt(3))");
+	_pprintLine_("         -'sill':   for gaussian, spherical and exponential models (default 1)");
+	_pprintLine_("         -'slope':  for power model (default 1)");
+	_pprintLine_("         -'power':  for power model (default 1)");
+	_pprintLine_("      -'searchradius': search radius for each prediction (default is observations span)");
+	_pprintLine_("      -'boxlength':    minimum length of quadtree boxes (useful to decrease the number of observations)");
+	_pprintLine_("      -'maxdata':      minimum number of observations for a prediction (default is 50)");
+	_pprintLine_("      -'mindata':      maximum number of observations for a prediction (default is 1)");
+	_pprintLine_("      -'maxtrimming':  maximum trimming value (default is -1.e+21)");
+	_pprintLine_("      -'mintrimming':  minimum trimming value (default is +1.e+21)");
+	_pprintLine_("      -'minspacing':   minimum distance between observation (default is 0.01)");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(Kriging){
 
 	/*Outputs*/
 	double  *x            = NULL;
@@ -51,23 +70,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void KrigingUsage(void){
-	_pprintLine_("");
-	_pprintLine_("   usage: predictions=" << __FUNCT__ << "(x,y,observations,x_interp,y_interp,'options');");
-	_pprintLine_("   available options:");
-	_pprintLine_("      -'model': Available variogram models 'gaussian' (default),'spherical','power','exponential'");
-	_pprintLine_("         -'nugget': nugget effect (default 0.2)");
-	_pprintLine_("         -'range':  for gaussian, spherical and exponential models (default sqrt(3))");
-	_pprintLine_("         -'sill':   for gaussian, spherical and exponential models (default 1)");
-	_pprintLine_("         -'slope':  for power model (default 1)");
-	_pprintLine_("         -'power':  for power model (default 1)");
-	_pprintLine_("      -'searchradius': search radius for each prediction (default is observations span)");
-	_pprintLine_("      -'boxlength':    minimum length of quadtree boxes (useful to decrease the number of observations)");
-	_pprintLine_("      -'maxdata':      minimum number of observations for a prediction (default is 50)");
-	_pprintLine_("      -'mindata':      maximum number of observations for a prediction (default is 1)");
-	_pprintLine_("      -'maxtrimming':  maximum trimming value (default is -1.e+21)");
-	_pprintLine_("      -'mintrimming':  minimum trimming value (default is +1.e+21)");
-	_pprintLine_("      -'minspacing':   minimum distance between observation (default is 0.01)");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/EnumToString/EnumToString.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/EnumToString/EnumToString.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/EnumToString/EnumToString.cpp	(revision 13236)
@@ -4,6 +4,11 @@
 
 #include "./EnumToString.h"
 
+void EnumToStringUsage(void){/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("   usage: " << __FUNCT__ << "string = EnumToString(enum);");
+	_pprintLine_("");
+}/*}}}*/
 WRAPPER(EnumToString){
 
 	char    *name    = NULL;
@@ -27,9 +32,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void EnumToStringUsage(void){
-	_pprintLine_("");
-	_pprintLine_("   usage: " << __FUNCT__ << "string = EnumToString(enum);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/EnumToString/EnumToString.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/EnumToString/EnumToString.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/EnumToString/EnumToString.h	(revision 13236)
@@ -46,7 +46,4 @@
 #undef NRHS
 #define NRHS  1
 
-/* local prototypes: */
-void EnumToStringUsage(void);
-
 #endif  /* _TEST_H */
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/StringToEnum/StringToEnum.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/StringToEnum/StringToEnum.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/StringToEnum/StringToEnum.cpp	(revision 13236)
@@ -4,6 +4,11 @@
 
 #include "./StringToEnum.h"
 
+void StringToEnumUsage(void){/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("   usage: " << __FUNCT__ << "enum = StringToEnum(string);");
+	_pprintLine_("");
+}/*}}}*/
 WRAPPER(StringToEnum){
 
 	char    *name    = NULL;
@@ -27,10 +32,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void StringToEnumUsage(void)
-{
-	_pprintLine_("");
-	_pprintLine_("   usage: " << __FUNCT__ << "enum = StringToEnum(string);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/StringToEnum/StringToEnum.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/StringToEnum/StringToEnum.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/StringToEnum/StringToEnum.h	(revision 13236)
@@ -46,7 +46,4 @@
 #undef NRHS
 #define NRHS  1
 
-/* local prototypes: */
-void StringToEnumUsage(void);
-
 #endif  /* _TEST_H */
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgTriangulate/BamgTriangulate.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgTriangulate/BamgTriangulate.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgTriangulate/BamgTriangulate.cpp	(revision 13236)
@@ -3,7 +3,16 @@
  */
 #include "./BamgTriangulate.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void BamgTriangulateUsage(void){/*{{{*/
+	_pprintString_("BAMGTRIANGULATE - Delaunay Triangulation of a list of points");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      index=BamgTriangulate(x,y);");
+	_pprintLine_("      index: index of the triangulation");
+	_pprintLine_("      x,y: coordinates of the nodes");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(BamgTriangulate){
 
 	/*input: */
 	double* x=NULL;
@@ -45,14 +54,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void BamgTriangulateUsage(void)
-{
-	_pprintString_("BAMGTRIANGULATE - Delaunay Triangulation of a list of points");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      index=BamgTriangulate(x,y);");
-	_pprintLine_("      index: index of the triangulation");
-	_pprintLine_("      x,y: coordinates of the nodes");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgTriangulate/BamgTriangulate.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgTriangulate/BamgTriangulate.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/BamgTriangulate/BamgTriangulate.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void BamgTriangulateUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh2d/InterpFromMeshToMesh2d.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh2d/InterpFromMeshToMesh2d.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh2d/InterpFromMeshToMesh2d.cpp	(revision 13236)
@@ -3,7 +3,30 @@
  */
 #include "./InterpFromMeshToMesh2d.h"
 
-
+void InterpFromMeshToMesh2dUsage(void){/*{{{*/
+	_pprintLine_("INTERFROMMESHTOMESH2D - interpolation from a 2d triangular mesh onto a list of point");
+	_pprintLine_("");
+	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
+	_pprintLine_("   defined on a Delaunay triangulation onto a list of point");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("         data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp);");
+	_pprintLine_("      or data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp,OPTIONS);");
+	_pprintLine_("");
+	_pprintLine_("      index             : index of the mesh where data is defined");
+	_pprintLine_("      x,y               : coordinates of the nodes where data is defined");
+	_pprintLine_("      data              : matrix holding the data to be interpolated onto the mesh. (one column per field)");
+	_pprintLine_("      x_interp,y_interp : coordinates of the points onto which we interpolate.");
+	_pprintLine_("      data_interp       : vector of mesh interpolated data.");
+	_pprintLine_("      Available options :");
+	_pprintLine_("         - 'default' : default value if point is outsite of triangulation (instead of linear interolation)");
+	_pprintLine_("");
+	_pprintLine_("   Example:");
+	_pprintLine_("      load('temperature.mat');");
+	_pprintLine_("      md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y);");
+	_pprintLine_("      md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y,'default',253);");
+	_pprintLine_("");
+}/*}}}*/
 WRAPPER(InterpFromMeshToMesh2d){
 
 	/*Intermediaties*/
@@ -54,29 +77,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void InterpFromMeshToMesh2dUsage(void){ /*{{{*/
-	_pprintLine_("INTERFROMMESHTOMESH2D - interpolation from a 2d triangular mesh onto a list of point");
-	_pprintLine_("");
-	_pprintLine_("   This function is a multi-threaded mex file that interpolates a field");
-	_pprintLine_("   defined on a Delaunay triangulation onto a list of point");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("         data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp);");
-	_pprintLine_("      or data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp,OPTIONS);");
-	_pprintLine_("");
-	_pprintLine_("      index             : index of the mesh where data is defined");
-	_pprintLine_("      x,y               : coordinates of the nodes where data is defined");
-	_pprintLine_("      data              : matrix holding the data to be interpolated onto the mesh. (one column per field)");
-	_pprintLine_("      x_interp,y_interp : coordinates of the points onto which we interpolate.");
-	_pprintLine_("      data_interp       : vector of mesh interpolated data.");
-	_pprintLine_("      Available options :");
-	_pprintLine_("         - 'default' : default value if point is outsite of triangulation (instead of linear interolation)");
-	_pprintLine_("");
-	_pprintLine_("   Example:");
-	_pprintLine_("      load('temperature.mat');");
-	_pprintLine_("      md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y);");
-	_pprintLine_("      md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y,'default',253);");
-	_pprintLine_("");
-}
-/*}}}*/
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh2d/InterpFromMeshToMesh2d.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh2d/InterpFromMeshToMesh2d.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/InterpFromMeshToMesh2d/InterpFromMeshToMesh2d.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void InterpFromMeshToMesh2dUsage(void);
-
 /*Header files: */
 #include "../../c/include/globals.h"
 #include "../../c/toolkits/toolkits.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToMesh/ContourToMesh.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToMesh/ContourToMesh.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToMesh/ContourToMesh.h	(revision 13236)
@@ -62,8 +62,5 @@
 #undef NRHS
 #define NRHS 6
 
-/* local prototypes: */
-void ContourToMeshUsage(void);
-
 #endif  /* _CONTOURTOMESH_H */
 
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToMesh/ContourToMesh.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToMesh/ContourToMesh.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/ContourToMesh/ContourToMesh.cpp	(revision 13236)
@@ -1,25 +1,31 @@
 /*! \file  ContourtoMesh
     \brief: takes an  contour file, and figures out which nodes or elements from the mesh  
     are inside this contour. 
-	usage:
-	[in_nod,in_elem]=ContourToMesh(index,x,y,contours,interptype,edgevalue);
-	
-	input:
-
-		index,x,y: delaunay triangulation.
-		contours: structure holding sets of vertices making open contours. 
-		interptype: string definining type of interpolation ('element', or 'node', or 'element and node');
-		edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons
-
-	output:
-		in_nod: vector of flags (0 or 1), of size nods if interptype is set to 'node' or 'element and node', 
-				or of size 0 otherwise.
-		in_elem: vector of flags (0 or 1), of size nel if interptype is set to 'element' or 'element and node', 
-				or of size 0 otherwise.
 */
 	
 #include "./ContourToMesh.h"
 
+void ContourToMeshUsage(void){/*{{{*/
+	_printLine_("CONTOURTOMESH - Flag the elements or nodes inside a contour");
+	_printLine_("");
+	_printLine_("      Usage: ");
+	_printLine_("         [in_nod,in_elem]=ContourToMesh(index,x,y,contourname,interptype,edgevalue)\n");
+	_printLine_("");
+	_printLine_("         index,x,y: mesh triangulation.");
+	_printLine_("         contourname: name of .exp file containing the contours.");
+	_printLine_("         interptype: string definining type of interpolation ('element', or 'node').");
+	_printLine_("         edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons.");
+	_printLine_("         in_nod: vector of flags (0 or 1), of size nods if interptype is set to 'node' or 'element and node', ");
+	_printLine_("            or of size 0 otherwise.");
+	_printLine_("         in_elem: vector of flags (0 or 1), of size nel if interptype is set to 'element' or 'element and node', ");
+	_printLine_("            or of size 0 otherwise.");
+	_printLine_("");
+	_printLine_("      Example: ");
+	_printLine_("         in_nod=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','node',1)");
+	_printLine_("         in_elements=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element',0)");
+	_printLine_("         [in_nodes,in_elements]=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element and node',0)");
+	_printLine_("");
+}/*}}}*/
 WRAPPER(ContourToMesh){
 
 	int i,j;
@@ -55,7 +61,6 @@
 		_error_("usage. See above");
 	}
 
-
 	/*Fetch inputs: */
 	FetchData(&index,&nel,NULL,INDEX);
 	FetchData(&x,&nods,NULL,X);
@@ -87,27 +92,3 @@
 	MODULEEND();
 	
 }
-
-void ContourToMeshUsage(void)//{{{1
-{
-	_printLine_("CONTOURTOMESH - Flag the elements or nodes inside a contour");
-	_printLine_("");
-	_printLine_("      Usage: ");
-	_printLine_("         [in_nod,in_elem]=ContourToMesh(index,x,y,contourname,interptype,edgevalue)\n");
-	_printLine_("");
-	_printLine_("         index,x,y: mesh triangulation.");
-	_printLine_("         contourname: name of .exp file containing the contours.");
-	_printLine_("         interptype: string definining type of interpolation ('element', or 'node').");
-	_printLine_("         edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons.");
-	_printLine_("         in_nod: vector of flags (0 or 1), of size nods if interptype is set to 'node' or 'element and node', ");
-	_printLine_("            or of size 0 otherwise.");
-	_printLine_("         in_elem: vector of flags (0 or 1), of size nel if interptype is set to 'element' or 'element and node', ");
-	_printLine_("            or of size 0 otherwise.");
-	_printLine_("");
-	_printLine_("      Example: ");
-	_printLine_("         in_nod=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','node',1)");
-	_printLine_("         in_elements=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element',0)");
-	_printLine_("         [in_nodes,in_elements]=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element and node',0)");
-	_printLine_("");
-}
-//}}}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Xy2ll/Xy2ll.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Xy2ll/Xy2ll.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Xy2ll/Xy2ll.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void Xy2llUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Xy2ll/Xy2ll.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Xy2ll/Xy2ll.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Xy2ll/Xy2ll.cpp	(revision 13236)
@@ -3,7 +3,31 @@
  */
 #include "./Xy2ll.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void Xy2llUsage(void){/*{{{*/
+	_pprintLine_("Xy2ll - x/y to lat/long coordinate transformation module:");
+	_pprintLine_("");
+	_pprintLine_("   This module transforms x/y to lat/long coordinates.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      [lat,lon]=Xy2ll(x,y,sgn,'param name',param,...);");
+	_pprintLine_("");
+	_pprintLine_("      x           x coordinates (double vector)");
+	_pprintLine_("      y           y coordinates (double vector)");
+	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
+	_pprintLine_("");
+	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
+	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
+	_pprintLine_("");
+	_pprintLine_("      lat         latitude coordinates (double vector)");
+	_pprintLine_("      lon         longitude coordinates (double vector)");
+	_pprintLine_("");
+	_pprintLine_("   Examples:");
+	_pprintLine_("      [lat,lon]=Xy2ll(x,y, 1);");
+	_pprintLine_("      [lat,lon]=Xy2ll(x,y, 1,'central_meridian',45,'standard_parallel',70);");
+	_pprintLine_("      [lat,lon]=Xy2ll(x,y,-1,'central_meridian', 0,'standard_parallel',71);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(Xy2ll){
 
 	int i,verbose=1;
 
@@ -70,29 +94,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void Xy2llUsage(void){
-	_pprintLine_("Xy2ll - x/y to lat/long coordinate transformation module:");
-	_pprintLine_("");
-	_pprintLine_("   This module transforms x/y to lat/long coordinates.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      [lat,lon]=Xy2ll(x,y,sgn,'param name',param,...);");
-	_pprintLine_("");
-	_pprintLine_("      x           x coordinates (double vector)");
-	_pprintLine_("      y           y coordinates (double vector)");
-	_pprintLine_("      sgn         sign for hemisphere (double, +1 (north) or -1 (south))");
-	_pprintLine_("");
-	_pprintLine_("      central_meridian     central meridian (double, optional, but must specify with sp)");
-	_pprintLine_("      standard_parallel    standard parallel (double, optional, but must specify with cm)");
-	_pprintLine_("");
-	_pprintLine_("      lat         latitude coordinates (double vector)");
-	_pprintLine_("      lon         longitude coordinates (double vector)");
-	_pprintLine_("");
-	_pprintLine_("   Examples:");
-	_pprintLine_("      [lat,lon]=Xy2ll(x,y, 1);");
-	_pprintLine_("      [lat,lon]=Xy2ll(x,y, 1,'central_meridian',45,'standard_parallel',70);");
-	_pprintLine_("      [lat,lon]=Xy2ll(x,y,-1,'central_meridian', 0,'standard_parallel',71);");
-	_pprintLine_("");
-}
-
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.h	(revision 13236)
@@ -16,9 +16,6 @@
 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
 #endif
 
-/* local prototypes: */
-void KMLMeshWriteUsage(void);
-
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
 #include "../../c/Container/Container.h"
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.cpp	(revision 13236)
@@ -3,7 +3,32 @@
  */
 #include "./KMLMeshWrite.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void KMLMeshWriteUsage(void){/*{{{*/
+	_pprintLine_("KMLMeshWrite - KML mesh writer module:");
+	_pprintLine_("");
+	_pprintLine_("   This module writes the mesh of a model as KML polygons into the specified KML file.");
+	_pprintLine_("");
+	_pprintLine_("   Usage:");
+	_pprintLine_("      ierror=KMLMeshWrite(name,notes,elem,nodecon,lat,long,part,data,cmap,kmlfile);");
+	_pprintLine_("");
+	_pprintLine_("      name       model name (string, may be empty)");
+	_pprintLine_("      notes      model notes (string or cell array of strings, may be empty)");
+	_pprintLine_("      elem       elements (double array)");
+	_pprintLine_("      nodecon    nodal connectivity array (double array, may be empty)");
+	_pprintLine_("      lat        nodal latititudes (double vector)");
+	_pprintLine_("      long       nodal longitudes (double vector)");
+	_pprintLine_("      part       nodal partitions (double vector, may be empty)");
+	_pprintLine_("      data       nodal or element data (double vector, may be empty)");
+	_pprintLine_("      cmap       color map (double nx3 array, may be empty)");
+	_pprintLine_("      kmlfile    KML file name (string)");
+	_pprintLine_("");
+	_pprintLine_("      ierror     error flag (double, non-zero for error)");
+	_pprintLine_("");
+	_pprintLine_("   Example:");
+	_pprintLine_("      KMLMeshWrite(md.name,md.notes,md.elements,md.nodeconnectivity,md.lat,md.long,md.part,md.fm_criterion,options.cmap,filekml);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(KMLMeshWrite){
 
 	int i,j,nnodes=0,verbose=1;
 
@@ -121,29 +146,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void KMLMeshWriteUsage(void){
-	_pprintLine_("KMLMeshWrite - KML mesh writer module:");
-	_pprintLine_("");
-	_pprintLine_("   This module writes the mesh of a model as KML polygons into the specified KML file.");
-	_pprintLine_("");
-	_pprintLine_("   Usage:");
-	_pprintLine_("      ierror=KMLMeshWrite(name,notes,elem,nodecon,lat,long,part,data,cmap,kmlfile);");
-	_pprintLine_("");
-	_pprintLine_("      name       model name (string, may be empty)");
-	_pprintLine_("      notes      model notes (string or cell array of strings, may be empty)");
-	_pprintLine_("      elem       elements (double array)");
-	_pprintLine_("      nodecon    nodal connectivity array (double array, may be empty)");
-	_pprintLine_("      lat        nodal latititudes (double vector)");
-	_pprintLine_("      long       nodal longitudes (double vector)");
-	_pprintLine_("      part       nodal partitions (double vector, may be empty)");
-	_pprintLine_("      data       nodal or element data (double vector, may be empty)");
-	_pprintLine_("      cmap       color map (double nx3 array, may be empty)");
-	_pprintLine_("      kmlfile    KML file name (string)");
-	_pprintLine_("");
-	_pprintLine_("      ierror     error flag (double, non-zero for error)");
-	_pprintLine_("");
-	_pprintLine_("   Example:");
-	_pprintLine_("      KMLMeshWrite(md.name,md.notes,md.elements,md.nodeconnectivity,md.lat,md.long,md.part,md.fm_criterion,options.cmap,filekml);");
-	_pprintLine_("");
-}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMesh/TriMesh.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMesh/TriMesh.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMesh/TriMesh.h	(revision 13236)
@@ -62,7 +62,4 @@
 #undef NRHS
 #define NRHS  3
 
-/* local prototypes: */
-void TriMeshUsage(void);
-
 #endif  /* _TRIMESH_H */
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMesh/TriMesh.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMesh/TriMesh.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/TriMesh/TriMesh.cpp	(revision 13236)
@@ -4,6 +4,15 @@
 
 #include "./TriMesh.h"
 
+void TriMeshUsage(void){/*{{{*/
+	_printLine_("");
+	_printLine_("   usage: [index,x,y,segments,segmentmarkers]=TriMesh(domainoutlinefilename,rifts,area) ");
+	_printLine_("      where: index,x,y defines a triangulation, segments is an array made ");
+	_printLine_("      of exterior segments to the mesh domain outline, segmentmarkers is an array flagging each segment, ");
+	_printLine_("      outlinefilename an Argus domain outline file, ");
+	_printLine_("      area is the maximum area desired for any element of the resulting mesh, ");
+	_printLine_("");
+}/*}}}*/
 WRAPPER(TriMesh){
 	
 	/* input: */
@@ -59,15 +68,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void TriMeshUsage(void) //{{{1
-{
-	_printLine_("");
-	_printLine_("   usage: [index,x,y,segments,segmentmarkers]=TriMesh(domainoutlinefilename,rifts,area) ");
-	_printLine_("      where: index,x,y defines a triangulation, segments is an array made ");
-	_printLine_("      of exterior segments to the mesh domain outline, segmentmarkers is an array flagging each segment, ");
-	_printLine_("      outlinefilename an Argus domain outline file, ");
-	_printLine_("      area is the maximum area desired for any element of the resulting mesh, ");
-	_printLine_("");
-}
-//}}}
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Chaco/Chaco.h
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Chaco/Chaco.h	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Chaco/Chaco.h	(revision 13236)
@@ -26,9 +26,6 @@
 #include "../../c/shared/shared.h"
 #include "../../c/issm-binding.h"
 
-/* local prototypes: */
-void ChacoUsage(void);
-
 #undef __FUNCT__ 
 #define __FUNCT__  "Chaco"
 
Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Chaco/Chaco.cpp
===================================================================
--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Chaco/Chaco.cpp	(revision 13235)
+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/modules/Chaco/Chaco.cpp	(revision 13236)
@@ -8,10 +8,14 @@
 #error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
 #endif
 
-
 #include "./Chaco.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+void ChacoUsage(void){/*{{{*/
+	_pprintLine_("");
+	_pprintLine_("Usage: [assgn] = Chaco(A,vwgts,ewgts,x,y,z,options,nparts,goal);");
+	_pprintLine_("");
+}/*}}}*/
+WRAPPER(Chaco){
    
 	int i;
 	int nterms;
@@ -129,9 +133,3 @@
 	/*end module: */
 	MODULEEND();
 }
-
-void ChacoUsage(void){
-	_pprintLine_("");
-	_pprintLine_("Usage: [assgn] = Chaco(A,vwgts,ewgts,x,y,z,options,nparts,goal);");
-	_pprintLine_("");
-}
