From d0beca8eca988f6dad175d3d52f5a296f390a9c1 Mon Sep 17 00:00:00 2001 From: Todd Zullinger Date: Mon, 15 Jan 2007 02:12:04 +0000 Subject: add support files for converting gtk-docs to python docstrings git-svn-id: https://gtkpod.svn.sf.net/svnroot/gtkpod/libgpod/trunk@1372 f01d2545-417e-4e96-918e-98f8d0dbbcb6 --- bindings/python/gpod_doc.i.in | 86 ++++++++++++++++++++++++++++++++++++++ bindings/python/gtkdoc-to-swig.xsl | 54 ++++++++++++++++++++++++ 2 files changed, 140 insertions(+) create mode 100644 bindings/python/gpod_doc.i.in create mode 100644 bindings/python/gtkdoc-to-swig.xsl diff --git a/bindings/python/gpod_doc.i.in b/bindings/python/gpod_doc.i.in new file mode 100644 index 0000000..fa25c12 --- /dev/null +++ b/bindings/python/gpod_doc.i.in @@ -0,0 +1,86 @@ +%feature("autodoc", "1"); + +%feature("autodoc", "sw_get_tracks(Itdb_iTunesDB itdb) -> [Itdb_Track, ...]") sw_get_tracks; +%feature("docstring", " +Get tracks in itdb. + +Parameters +itdb: an Itdb_iTunesDB +Returns: a list of Itdb_Track objects +") sw_get_tracks; + +%feature("autodoc", "sw_get_track(GList list, gint index) -> Itdb_Track") sw_get_track; +%feature("docstring", " +Get a track + +Parameters +list: a GList +index: position of the track +Returns: an Itdb_Track +") sw_get_track; + +%feature("autodoc", "sw_get_rule(GList list, gint index) -> SPLRule") sw_get_rule; +%feature("docstring", " +Get a rule + +Parameters +list: a GList +index: position of the rule +Returns: an SPLRule +") sw_get_rule; + +%feature("autodoc", "sw_get_playlist(GList list, gint index) -> Itdb_Playlist") sw_get_playlist; +%feature("docstring", " +Get a playlist + +Parameters +list: a GList +index: position of the playlist +Returns: an Itdb_Playlist +") sw_get_playlist; + +%feature("autodoc", "sw_get_list_len(GList list) -> Int") sw_get_list_len; +%feature("docstring", " +Get the length of list + +Parameters +list: a GList +Returns: length of list +") sw_get_list_len; + +%feature("autodoc", "sw_get_playlists(Itdb_iTunesDB itdb) -> [Itdb_Playlist, ...]") sw_get_playlists; +%feature("docstring", " +Get playlists + +Parameters +itdb: an Itdb_iTunesDB +Returns: a list of Itdb_Playlist objects +") sw_get_playlists; + +%feature("autodoc", "sw_get_playlist_tracks(Itdb_Playlist pl) -> [Itdb_Track, ...]") sw_get_playlist_tracks; +%feature("docstring", " +Get tracks in playlist + +pl: an Itdb_Playlist +Returns: a list of Itdb_Track objects +") sw_get_playlist_tracks; + +%feature("autodoc", "sw_set_track_userdata(Itdb_Track track, Dictionary userdata)") sw_set_track_userdata; +%feature("docstring", " +Set a tracks userdata + +Parameters +track: an Itdb_Track +userdata: a dictionary. Note that userdata can be None, in order to +clear all userdata. +") sw_set_track_userdata; + +%feature("autodoc", "sw_get_track_userdata(Itdb_Track track) -> Dictionary") sw_get_track_userdata; +%feature("docstring", " +Get track userdata + +Parameters +track: an Itdb_Track +Returns: a dictionary containing any userdata for track +") sw_get_track_userdata; + diff --git a/bindings/python/gtkdoc-to-swig.xsl b/bindings/python/gtkdoc-to-swig.xsl new file mode 100644 index 0000000..520ceb7 --- /dev/null +++ b/bindings/python/gtkdoc-to-swig.xsl @@ -0,0 +1,54 @@ + + + + + + + + %feature("docstring", " + + + + + Parameters + + + + + + + + + + + ") + + ; + + + + + + + + + + + \" + + + + + + + + + + + -- cgit