From b9efc92cb88010a24b0a7db1dbd97d274b0504f2 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Sun, 26 Feb 2012 15:13:37 +0100 Subject: parse and generate elm_general and elm_tooltip --- lib/efl/native/elm/elm_general.rb | 104 ++++++++++++++++++++++++++++++++++++++ lib/efl/native/elm/elm_tooltip.rb | 63 +++++++++++++++++++++++ 2 files changed, 167 insertions(+) create mode 100644 lib/efl/native/elm/elm_general.rb create mode 100644 lib/efl/native/elm/elm_tooltip.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_general.rb b/lib/efl/native/elm/elm_general.rb new file mode 100644 index 0000000..71b61e2 --- /dev/null +++ b/lib/efl/native/elm/elm_general.rb @@ -0,0 +1,104 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module Elm + # + FCT_PREFIX = 'elm_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Object_Layer; + enum :elm_object_layer, [ :elm_object_layer_background, EVAS_LAYER_MIN+64, :elm_object_layer_default, 0, :elm_object_layer_focus, + EVAS_LAYER_MAX-128, :elm_object_layer_tooltip, EVAS_LAYER_MAX-64, :elm_object_layer_cursor, EVAS_LAYER_MAX-32, :elm_object_layer_last, 32736 ] + # typedef enum {...} Elm_Policy; + enum :elm_policy, [ :elm_policy_quit, :elm_policy_last ] + # typedef enum {...} Elm_Policy_Quit; + enum :elm_policy_quit, [ :elm_policy_quit_none, 0, :elm_policy_quit_last_window_closed, 1 ] + # typedef enum {...} Elm_Focus_Direction; + enum :elm_focus_direction, [ :elm_focus_previous, :elm_focus_next ] + # + # TYPEDEFS + # typedef struct _Elm_Event_Policy_Changed Elm_Event_Policy_Changed; + typedef :pointer, :elm_event_policy_changed + # typedef struct _Elm_Object_Item Elm_Object_Item; + typedef :pointer, :elm_object_item + # + # CALLBACKS + # typedef Eina_Bool (*Elm_Event_Cb) (void *data, Evas_Object *obj, Evas_Object *src, Evas_Callback_Type type, void *event_info); + callback :elm_event_cb, [ :pointer, :evas_object, :evas_object, :evas_callback_type, :pointer ], :bool + # + # VARIABLES + # EAPI extern int ELM_ECORE_EVENT_ETHUMB_CONNECT; + attach_variable :ELM_ECORE_EVENT_ETHUMB_CONNECT, :int + # EAPI extern int ELM_EVENT_CONFIG_ALL_CHANGED; + attach_variable :ELM_EVENT_CONFIG_ALL_CHANGED, :int + # EAPI extern int ELM_EVENT_POLICY_CHANGED; + attach_variable :ELM_EVENT_POLICY_CHANGED, :int + # + # FUNCTIONS + fcts = [ + # EAPI int elm_init(int argc, char **argv); + [ :elm_init, [ :int, :pointer ], :int ], + # EAPI int elm_shutdown(void); + [ :elm_shutdown, [ ], :int ], + # EAPI void elm_run(void); + [ :elm_run, [ ], :void ], + # EAPI void elm_exit(void); + [ :elm_exit, [ ], :void ], + # EAPI void elm_quicklaunch_mode_set(Eina_Bool ql_on); + [ :elm_quicklaunch_mode_set, [ :bool ], :void ], + # EAPI Eina_Bool elm_quicklaunch_mode_get(void); + [ :elm_quicklaunch_mode_get, [ ], :bool ], + # EAPI int elm_quicklaunch_init(int argc, char **argv); + [ :elm_quicklaunch_init, [ :int, :pointer ], :int ], + # EAPI int elm_quicklaunch_sub_init(int argc, char **argv); + [ :elm_quicklaunch_sub_init, [ :int, :pointer ], :int ], + # EAPI int elm_quicklaunch_sub_shutdown(void); + [ :elm_quicklaunch_sub_shutdown, [ ], :int ], + # EAPI int elm_quicklaunch_shutdown(void); + [ :elm_quicklaunch_shutdown, [ ], :int ], + # EAPI void elm_quicklaunch_seed(void); + [ :elm_quicklaunch_seed, [ ], :void ], + # EAPI Eina_Bool elm_quicklaunch_prepare(int argc, char **argv); + [ :elm_quicklaunch_prepare, [ :int, :pointer ], :bool ], + # EAPI Eina_Bool elm_quicklaunch_fork(int argc, char **argv, char *cwd, void (postfork_func) (void *data), void *postfork_data); + # FIXME + # EAPI void elm_quicklaunch_cleanup(void); + [ :elm_quicklaunch_cleanup, [ ], :void ], + # EAPI int elm_quicklaunch_fallback(int argc, char **argv); + [ :elm_quicklaunch_fallback, [ :int, :pointer ], :int ], + # EAPI char *elm_quicklaunch_exe_path_get(const char *exe); + [ :elm_quicklaunch_exe_path_get, [ :string ], :string ], + # EAPI Eina_Bool elm_policy_set(unsigned int policy, int value); + [ :elm_policy_set, [ :uint, :int ], :bool ], + # EAPI int elm_policy_get(unsigned int policy); + [ :elm_policy_get, [ :uint ], :int ], + # EAPI void elm_language_set(const char *lang); + [ :elm_language_set, [ :string ], :void ], + # EAPI void elm_object_domain_translatable_text_part_set(Evas_Object *obj, const char *part, const char *domain, const char *text); + [ :elm_object_domain_translatable_text_part_set, [ :evas_object, :string, :string, :string ], :void ], + # EAPI const char *elm_object_translatable_text_part_get(const Evas_Object *obj, const char *part); + [ :elm_object_translatable_text_part_get, [ :evas_object, :string ], :string ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_tooltip.rb b/lib/efl/native/elm/elm_tooltip.rb new file mode 100644 index 0000000..68774a6 --- /dev/null +++ b/lib/efl/native/elm/elm_tooltip.rb @@ -0,0 +1,63 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module Elm + # + FCT_PREFIX = 'elm_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # CALLBACKS + # typedef Evas_Object *(*Elm_Tooltip_Content_Cb) (void *data, Evas_Object *obj, Evas_Object *tooltip); + callback :elm_tooltip_content_cb, [ :pointer, :evas_object, :evas_object ], :evas_object + # typedef Evas_Object *(*Elm_Tooltip_Item_Content_Cb) (void *data, Evas_Object *obj, Evas_Object *tooltip, void *item); + callback :elm_tooltip_item_content_cb, [ :pointer, :evas_object, :evas_object, :pointer ], :evas_object + # + # FUNCTIONS + fcts = [ + # EAPI double elm_tooltip_delay_get(void); + [ :elm_tooltip_delay_get, [ ], :double ], + # EAPI Eina_Bool elm_tooltip_delay_set(double delay); + [ :elm_tooltip_delay_set, [ :double ], :bool ], + # EAPI void elm_object_tooltip_show(Evas_Object *obj); + [ :elm_object_tooltip_show, [ :evas_object ], :void ], + # EAPI void elm_object_tooltip_hide(Evas_Object *obj); + [ :elm_object_tooltip_hide, [ :evas_object ], :void ], + # EAPI void elm_object_tooltip_text_set(Evas_Object *obj, const char *text); + [ :elm_object_tooltip_text_set, [ :evas_object, :string ], :void ], + # EAPI void elm_object_tooltip_domain_translatable_text_set(Evas_Object *obj, const char *domain, const char *text); + [ :elm_object_tooltip_domain_translatable_text_set, [ :evas_object, :string, :string ], :void ], + # EAPI void elm_object_tooltip_content_cb_set(Evas_Object *obj, Elm_Tooltip_Content_Cb func, const void *data, Evas_Smart_Cb del_cb); + [ :elm_object_tooltip_content_cb_set, [ :evas_object, :elm_tooltip_content_cb, :pointer, :evas_smart_cb ], :void ], + # EAPI void elm_object_tooltip_unset(Evas_Object *obj); + [ :elm_object_tooltip_unset, [ :evas_object ], :void ], + # EAPI void elm_object_tooltip_style_set(Evas_Object *obj, const char *style); + [ :elm_object_tooltip_style_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_object_tooltip_style_get(const Evas_Object *obj); + [ :elm_object_tooltip_style_get, [ :evas_object ], :string ], + # EAPI Eina_Bool elm_object_tooltip_window_mode_set(Evas_Object *obj, Eina_Bool disable); + [ :elm_object_tooltip_window_mode_set, [ :evas_object, :bool ], :bool ], + # EAPI Eina_Bool elm_object_tooltip_window_mode_get(const Evas_Object *obj); + [ :elm_object_tooltip_window_mode_get, [ :evas_object ], :bool ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF -- cgit v1.2.3 From fdda52941d977938b5c14086e81ee6bf6f17fd49 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Sun, 26 Feb 2012 16:07:31 +0100 Subject: parse elm_object_item.h and generate native/elm/elm_object_item.rb --- lib/efl/native/elm/elm_object_item.rb | 99 +++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 3 +- tools/genruby.rb | 5 ++ 3 files changed, 106 insertions(+), 1 deletion(-) create mode 100644 lib/efl/native/elm/elm_object_item.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_object_item.rb b/lib/efl/native/elm/elm_object_item.rb new file mode 100644 index 0000000..86a67d1 --- /dev/null +++ b/lib/efl/native/elm/elm_object_item.rb @@ -0,0 +1,99 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +require 'efl/native/elm/elm_general' +require 'efl/native/elm/elm_tooltip' +# +module Efl + # + module Elm + # + FCT_PREFIX = 'elm_object_item_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # CALLBACKS + # typedef void (*Elm_Object_Item_Smart_Cb) (void *data, Elm_Object_Item *it, void *event_info); + callback :elm_object_item_smart_cb, [ :pointer, :elm_object_item, :pointer ], :void + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_object_item_widget_get(const Elm_Object_Item *it); + [ :elm_object_item_widget_get, [ :elm_object_item ], :evas_object ], + # EAPI void elm_object_item_part_content_set(Elm_Object_Item *it, const char *part, Evas_Object *content); + [ :elm_object_item_part_content_set, [ :elm_object_item, :string, :evas_object ], :void ], + # EAPI Evas_Object *elm_object_item_part_content_get(const Elm_Object_Item *it, const char *part); + [ :elm_object_item_part_content_get, [ :elm_object_item, :string ], :evas_object ], + # EAPI Evas_Object *elm_object_item_part_content_unset(Elm_Object_Item *it, const char *part); + [ :elm_object_item_part_content_unset, [ :elm_object_item, :string ], :evas_object ], + # EAPI void elm_object_item_part_text_set(Elm_Object_Item *it, const char *part, const char *label); + [ :elm_object_item_part_text_set, [ :elm_object_item, :string, :string ], :void ], + # EAPI const char *elm_object_item_part_text_get(const Elm_Object_Item *it, const char *part); + [ :elm_object_item_part_text_get, [ :elm_object_item, :string ], :string ], + # EAPI void elm_object_item_access_info_set(Elm_Object_Item *it, const char *txt); + [ :elm_object_item_access_info_set, [ :elm_object_item, :string ], :void ], + # EAPI void *elm_object_item_data_get(const Elm_Object_Item *it); + [ :elm_object_item_data_get, [ :elm_object_item ], :pointer ], + # EAPI void elm_object_item_data_set(Elm_Object_Item *it, void *data); + [ :elm_object_item_data_set, [ :elm_object_item, :pointer ], :void ], + # EAPI void elm_object_item_signal_emit(Elm_Object_Item *it, const char *emission, const char *source); + [ :elm_object_item_signal_emit, [ :elm_object_item, :string, :string ], :void ], + # EAPI void elm_object_item_disabled_set(Elm_Object_Item *it, Eina_Bool disabled); + [ :elm_object_item_disabled_set, [ :elm_object_item, :bool ], :void ], + # EAPI Eina_Bool elm_object_item_disabled_get(const Elm_Object_Item *it); + [ :elm_object_item_disabled_get, [ :elm_object_item ], :bool ], + # EAPI void elm_object_item_del_cb_set(Elm_Object_Item *it, Evas_Smart_Cb del_cb); + [ :elm_object_item_del_cb_set, [ :elm_object_item, :evas_smart_cb ], :void ], + # EAPI void elm_object_item_del(Elm_Object_Item *it); + [ :elm_object_item_del, [ :elm_object_item ], :void ], + # EAPI void elm_object_item_tooltip_text_set(Elm_Object_Item *it, const char *text); + [ :elm_object_item_tooltip_text_set, [ :elm_object_item, :string ], :void ], + # EAPI Eina_Bool elm_object_item_tooltip_window_mode_set(Elm_Object_Item *it, Eina_Bool disable); + [ :elm_object_item_tooltip_window_mode_set, [ :elm_object_item, :bool ], :bool ], + # EAPI Eina_Bool elm_object_item_tooltip_window_mode_get(const Elm_Object_Item *it); + [ :elm_object_item_tooltip_window_mode_get, [ :elm_object_item ], :bool ], + # EAPI void elm_object_item_tooltip_content_cb_set(Elm_Object_Item *it, Elm_Tooltip_Item_Content_Cb func, const void *data, Evas_Smart_Cb del_cb); + [ :elm_object_item_tooltip_content_cb_set, [ :elm_object_item, :elm_tooltip_item_content_cb, :pointer, :evas_smart_cb ], :void ], + # EAPI void elm_object_item_tooltip_unset(Elm_Object_Item *it); + [ :elm_object_item_tooltip_unset, [ :elm_object_item ], :void ], + # EAPI void elm_object_item_tooltip_style_set(Elm_Object_Item *it, const char *style); + [ :elm_object_item_tooltip_style_set, [ :elm_object_item, :string ], :void ], + # EAPI const char *elm_object_item_tooltip_style_get(const Elm_Object_Item *it); + [ :elm_object_item_tooltip_style_get, [ :elm_object_item ], :string ], + # EAPI void elm_object_item_cursor_set(Elm_Object_Item *it, const char *cursor); + [ :elm_object_item_cursor_set, [ :elm_object_item, :string ], :void ], + # EAPI const char *elm_object_item_cursor_get(const Elm_Object_Item *it); + [ :elm_object_item_cursor_get, [ :elm_object_item ], :string ], + # EAPI void elm_object_item_cursor_unset(Elm_Object_Item *it); + [ :elm_object_item_cursor_unset, [ :elm_object_item ], :void ], + # EAPI void elm_object_item_cursor_style_set(Elm_Object_Item *it, const char *style); + [ :elm_object_item_cursor_style_set, [ :elm_object_item, :string ], :void ], + # EAPI const char *elm_object_item_cursor_style_get(const Elm_Object_Item *it); + [ :elm_object_item_cursor_style_get, [ :elm_object_item ], :string ], + # EAPI void elm_object_item_cursor_engine_only_set(Elm_Object_Item *it, Eina_Bool engine_only); + [ :elm_object_item_cursor_engine_only_set, [ :elm_object_item, :bool ], :void ], + # EAPI Eina_Bool elm_object_item_cursor_engine_only_get(const Elm_Object_Item *it); + [ :elm_object_item_cursor_engine_only_get, [ :elm_object_item ], :bool ], + # EAPI void elm_object_item_smart_callback_add(Elm_Object_Item *it, const char *event, Elm_Object_Item_Smart_Cb func, const void *data); + [ :elm_object_item_smart_callback_add, [ :elm_object_item, :string, :elm_object_item_smart_cb, :pointer ], :void ], + # EAPI void *elm_object_item_smart_callback_del(Elm_Object_Item *it, const char *event, Elm_Object_Item_Smart_Cb func); + [ :elm_object_item_smart_callback_del, [ :elm_object_item, :string, :elm_object_item_smart_cb ], :pointer ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index f4b0617..f17a0fe 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -42,9 +42,10 @@ for header in \ "${INCLUDE}/ecore-1/Ecore_Fb.h" \ "${INCLUDE}/ecore-1/Ecore_File.h" \ "${INCLUDE}/EMap.h" \ + "${INCLUDE}/elementary-0/Elementary.h" \ "${INCLUDE}/elementary-0/elm_general.h" \ "${INCLUDE}/elementary-0/elm_tooltip.h" \ - "${INCLUDE}/elementary-0/Elementary.h" \ + "${INCLUDE}/elementary-0/elm_object_item.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 9b9706a..e36eef2 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -342,6 +342,11 @@ libs << { :modname=>'Elm', :prefix=>'elm', :outfile=>'elm/elm_tooltip.rb', :requires=>['efl/native/elementary'], :constants=>[] } +libs << { + :lib=>'elementary-ver-pre-svn-09.so.0',:header=>'elm_object_item.h', + :modname=>'Elm', :prefix=>'elm_object_item', :outfile=>'elm/elm_object_item.rb', + :requires=>['efl/native/elementary','efl/native/elm/elm_general','efl/native/elm/elm_tooltip'], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 3dabd42a102f8cacf36d69fbb5a893a6c8acfeb4 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Sun, 26 Feb 2012 23:37:01 +0100 Subject: reorder elementary stack requires: all require elementary, which requires elm_general and elm_tootip --- lib/efl/native/elementary.rb | 3 ++- lib/efl/native/elm/elm_general.rb | 1 + lib/efl/native/elm/elm_object_item.rb | 2 -- tools/genruby.rb | 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elementary.rb b/lib/efl/native/elementary.rb index 5e1317f..1bba9d0 100644 --- a/lib/efl/native/elementary.rb +++ b/lib/efl/native/elementary.rb @@ -2,7 +2,8 @@ # -*- coding: UTF-8 -*- # require 'efl/native' -require 'efl/native/evas' +require 'efl/native/elm/elm_general' +require 'efl/native/elm/elm_tooltip' # module Efl # diff --git a/lib/efl/native/elm/elm_general.rb b/lib/efl/native/elm/elm_general.rb index 71b61e2..8cde6ac 100644 --- a/lib/efl/native/elm/elm_general.rb +++ b/lib/efl/native/elm/elm_general.rb @@ -2,6 +2,7 @@ # -*- coding: UTF-8 -*- # require 'efl/native' +require 'efl/native/evas' require 'efl/native/elementary' # module Efl diff --git a/lib/efl/native/elm/elm_object_item.rb b/lib/efl/native/elm/elm_object_item.rb index 86a67d1..5cdc65f 100644 --- a/lib/efl/native/elm/elm_object_item.rb +++ b/lib/efl/native/elm/elm_object_item.rb @@ -3,8 +3,6 @@ # require 'efl/native' require 'efl/native/elementary' -require 'efl/native/elm/elm_general' -require 'efl/native/elm/elm_tooltip' # module Efl # diff --git a/tools/genruby.rb b/tools/genruby.rb index e36eef2..b5922bd 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -330,12 +330,12 @@ libs << { libs << { :lib=>'elementary-ver-pre-svn-09.so.0',:header=>'Elementary.h', :modname=>'Elm', :prefix=>'elm', :outfile=>'elementary.rb', - :requires=>['efl/native/evas'], :constants=>[] + :requires=>['efl/native/elm/elm_general','efl/native/elm/elm_tooltip'], :constants=>[] } libs << { :lib=>'elementary-ver-pre-svn-09.so.0',:header=>'elm_general.h', :modname=>'Elm', :prefix=>'elm', :outfile=>'elm/elm_general.rb', - :requires=>['efl/native/elementary'], :constants=>[] + :requires=>['efl/native/evas','efl/native/elementary'], :constants=>[] } libs << { :lib=>'elementary-ver-pre-svn-09.so.0',:header=>'elm_tooltip.h', @@ -345,7 +345,7 @@ libs << { libs << { :lib=>'elementary-ver-pre-svn-09.so.0',:header=>'elm_object_item.h', :modname=>'Elm', :prefix=>'elm_object_item', :outfile=>'elm/elm_object_item.rb', - :requires=>['efl/native/elementary','efl/native/elm/elm_general','efl/native/elm/elm_tooltip'], :constants=>[] + :requires=>['efl/native/elementary'], :constants=>[] } Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 863fce3d0c74445ab4be4b69b998970f33fa076a Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 09:52:26 +0100 Subject: update module names, elm_tooltip->ElmTooltip, elm_object_item->ElmObjectItem --- lib/efl/native/elm/elm_object_item.rb | 2 +- lib/efl/native/elm/elm_tooltip.rb | 2 +- tools/genruby.rb | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_object_item.rb b/lib/efl/native/elm/elm_object_item.rb index 5cdc65f..f2f634d 100644 --- a/lib/efl/native/elm/elm_object_item.rb +++ b/lib/efl/native/elm/elm_object_item.rb @@ -6,7 +6,7 @@ require 'efl/native/elementary' # module Efl # - module Elm + module ElmObjectItem # FCT_PREFIX = 'elm_object_item_' unless const_defined? :FCT_PREFIX # diff --git a/lib/efl/native/elm/elm_tooltip.rb b/lib/efl/native/elm/elm_tooltip.rb index 68774a6..233e154 100644 --- a/lib/efl/native/elm/elm_tooltip.rb +++ b/lib/efl/native/elm/elm_tooltip.rb @@ -6,7 +6,7 @@ require 'efl/native/elementary' # module Efl # - module Elm + module ElmTooltip # FCT_PREFIX = 'elm_' unless const_defined? :FCT_PREFIX # diff --git a/tools/genruby.rb b/tools/genruby.rb index 6c69031..96f50c6 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -342,12 +342,12 @@ libs << { } libs << { :lib=>ELM_LIB,:header=>'elm_tooltip.h', - :modname=>'Elm', :prefix=>'elm', :outfile=>'elm/elm_tooltip.rb', + :modname=>'ElmTooltip', :prefix=>'elm', :outfile=>'elm/elm_tooltip.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } libs << { :lib=>ELM_LIB,:header=>'elm_object_item.h', - :modname=>'Elm', :prefix=>'elm_object_item', :outfile=>'elm/elm_object_item.rb', + :modname=>'ElmObjectItem', :prefix=>'elm_object_item', :outfile=>'elm/elm_object_item.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } Dir.mkdir lib_path unless (File.exists? lib_path) -- cgit v1.2.3 From debba5aaff32de4ba857ad4f177fc6c2c21bec46 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:04:30 +0100 Subject: parse elm_icon.h and generate elm_icon.rb --- lib/efl/native/elm/elm_icon.rb | 97 ++++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 3 files changed, 103 insertions(+) create mode 100644 lib/efl/native/elm/elm_icon.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_icon.rb b/lib/efl/native/elm/elm_icon.rb new file mode 100644 index 0000000..dabfeb4 --- /dev/null +++ b/lib/efl/native/elm/elm_icon.rb @@ -0,0 +1,97 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmIcon + # + FCT_PREFIX = 'elm_icon_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Icon_Type; + enum :elm_icon_type, [ :elm_icon_none, :elm_icon_file, :elm_icon_standard ] + # typedef enum {...} Elm_Icon_Lookup_Order; + enum :elm_icon_lookup_order, [ :elm_icon_lookup_fdo_theme, :elm_icon_lookup_theme_fdo, :elm_icon_lookup_fdo, :elm_icon_lookup_theme ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_icon_add(Evas_Object *parent); + [ :elm_icon_add, [ :evas_object ], :evas_object ], + # EAPI Eina_Bool elm_icon_file_set(Evas_Object *obj, const char *file, const char *group); + [ :elm_icon_file_set, [ :evas_object, :string, :string ], :bool ], + # EAPI Eina_Bool elm_icon_memfile_set(Evas_Object *obj, const void *img, size_t size, const char *format, const char *key); + [ :elm_icon_memfile_set, [ :evas_object, :pointer, :ulong, :string, :string ], :bool ], + # EAPI void elm_icon_file_get(const Evas_Object *obj, const char **file, const char **group); + [ :elm_icon_file_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_icon_thumb_set(Evas_Object *obj, const char *file, const char *group); + [ :elm_icon_thumb_set, [ :evas_object, :string, :string ], :void ], + # EAPI Eina_Bool elm_icon_standard_set(Evas_Object *obj, const char *name); + [ :elm_icon_standard_set, [ :evas_object, :string ], :bool ], + # EAPI const char *elm_icon_standard_get(const Evas_Object *obj); + [ :elm_icon_standard_get, [ :evas_object ], :string ], + # EAPI void elm_icon_smooth_set(Evas_Object *obj, Eina_Bool smooth); + [ :elm_icon_smooth_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_icon_smooth_get(const Evas_Object *obj); + [ :elm_icon_smooth_get, [ :evas_object ], :bool ], + # EAPI void elm_icon_no_scale_set(Evas_Object *obj, Eina_Bool no_scale); + [ :elm_icon_no_scale_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_icon_no_scale_get(const Evas_Object *obj); + [ :elm_icon_no_scale_get, [ :evas_object ], :bool ], + # EAPI void elm_icon_scale_set(Evas_Object *obj, Eina_Bool scale_up, Eina_Bool scale_down); + [ :elm_icon_scale_set, [ :evas_object, :bool, :bool ], :void ], + # EAPI void elm_icon_scale_get(const Evas_Object *obj, Eina_Bool *scale_up, Eina_Bool *scale_down); + [ :elm_icon_scale_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_icon_size_get(const Evas_Object *obj, int *w, int *h); + [ :elm_icon_size_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_icon_fill_outside_set(Evas_Object *obj, Eina_Bool fill_outside); + [ :elm_icon_fill_outside_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_icon_fill_outside_get(const Evas_Object *obj); + [ :elm_icon_fill_outside_get, [ :evas_object ], :bool ], + # EAPI void elm_icon_prescale_set(Evas_Object *obj, int size); + [ :elm_icon_prescale_set, [ :evas_object, :int ], :void ], + # EAPI int elm_icon_prescale_get(const Evas_Object *obj); + [ :elm_icon_prescale_get, [ :evas_object ], :int ], + # EAPI Evas_Object *elm_icon_object_get(Evas_Object *obj); + [ :elm_icon_object_get, [ :evas_object ], :evas_object ], + # EAPI void elm_icon_order_lookup_set(Evas_Object *obj, Elm_Icon_Lookup_Order order); + [ :elm_icon_order_lookup_set, [ :evas_object, :elm_icon_lookup_order ], :void ], + # EAPI Elm_Icon_Lookup_Order elm_icon_order_lookup_get(const Evas_Object *obj); + [ :elm_icon_order_lookup_get, [ :evas_object ], :elm_icon_lookup_order ], + # EAPI void elm_icon_preload_set(Evas_Object *obj, Eina_Bool disable); + [ :elm_icon_preload_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_icon_animated_available_get(const Evas_Object *obj); + [ :elm_icon_animated_available_get, [ :evas_object ], :bool ], + # EAPI void elm_icon_animated_set(Evas_Object *obj, Eina_Bool animated); + [ :elm_icon_animated_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_icon_animated_get(const Evas_Object *obj); + [ :elm_icon_animated_get, [ :evas_object ], :bool ], + # EAPI void elm_icon_animated_play_set(Evas_Object *obj, Eina_Bool play); + [ :elm_icon_animated_play_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_icon_animated_play_get(const Evas_Object *obj); + [ :elm_icon_animated_play_get, [ :evas_object ], :bool ], + # EAPI void elm_icon_aspect_fixed_set(Evas_Object *obj, Eina_Bool fixed); + [ :elm_icon_aspect_fixed_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_icon_aspect_fixed_get(const Evas_Object *obj); + [ :elm_icon_aspect_fixed_get, [ :evas_object ], :bool ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index f17a0fe..ba30448 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -46,6 +46,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_general.h" \ "${INCLUDE}/elementary-0/elm_tooltip.h" \ "${INCLUDE}/elementary-0/elm_object_item.h" \ + "${INCLUDE}/elementary-0/elm_icon.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 96f50c6..52a174a 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -350,6 +350,11 @@ libs << { :modname=>'ElmObjectItem', :prefix=>'elm_object_item', :outfile=>'elm/elm_object_item.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_icon.h', + :modname=>'ElmIcon', :prefix=>'elm_icon', :outfile=>'elm/elm_icon.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 706034d6d53414e6eb8b5880af38c8dc101f8c65 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:05:17 +0100 Subject: parse elm_scroller.h and generate elm_scroller.rb --- lib/efl/native/elm/elm_scroller.rb | 80 ++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 3 files changed, 86 insertions(+) create mode 100644 lib/efl/native/elm/elm_scroller.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_scroller.rb b/lib/efl/native/elm/elm_scroller.rb new file mode 100644 index 0000000..a935c7f --- /dev/null +++ b/lib/efl/native/elm/elm_scroller.rb @@ -0,0 +1,80 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmScroller + # + FCT_PREFIX = 'elm_scroller_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Scroller_Policy; + enum :elm_scroller_policy, [ :elm_scroller_policy_auto, 0, :elm_scroller_policy_on, 1, :elm_scroller_policy_off, 2, :elm_scroller_policy_last, + 3 ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_scroller_add(Evas_Object *parent); + [ :elm_scroller_add, [ :evas_object ], :evas_object ], + # EAPI void elm_scroller_custom_widget_base_theme_set(Evas_Object *obj, const char *widget, const char *base); + [ :elm_scroller_custom_widget_base_theme_set, [ :evas_object, :string, :string ], :void ], + # EAPI void elm_scroller_content_min_limit(Evas_Object *obj, Eina_Bool w, Eina_Bool h); + [ :elm_scroller_content_min_limit, [ :evas_object, :bool, :bool ], :void ], + # EAPI void elm_scroller_region_show(Evas_Object *obj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h); + [ :elm_scroller_region_show, [ :evas_object, :int, :int, :int, :int ], :void ], + # EAPI void elm_scroller_policy_set(Evas_Object *obj, Elm_Scroller_Policy policy_h, Elm_Scroller_Policy policy_v); + [ :elm_scroller_policy_set, [ :evas_object, :elm_scroller_policy, :elm_scroller_policy ], :void ], + # EAPI void elm_scroller_policy_get(const Evas_Object *obj, Elm_Scroller_Policy *policy_h, Elm_Scroller_Policy *policy_v); + [ :elm_scroller_policy_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_scroller_region_get(const Evas_Object *obj, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h); + [ :elm_scroller_region_get, [ :evas_object, :pointer, :pointer, :pointer, :pointer ], :void ], + # EAPI void elm_scroller_child_size_get(const Evas_Object *obj, Evas_Coord *w, Evas_Coord *h); + [ :elm_scroller_child_size_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_scroller_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce); + [ :elm_scroller_bounce_set, [ :evas_object, :bool, :bool ], :void ], + # EAPI void elm_scroller_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce); + [ :elm_scroller_bounce_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_scroller_page_relative_set(Evas_Object *obj, double h_pagerel, double v_pagerel); + [ :elm_scroller_page_relative_set, [ :evas_object, :double, :double ], :void ], + # EAPI void elm_scroller_page_size_set(Evas_Object *obj, Evas_Coord h_pagesize, Evas_Coord v_pagesize); + [ :elm_scroller_page_size_set, [ :evas_object, :int, :int ], :void ], + # EAPI void elm_scroller_current_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber); + [ :elm_scroller_current_page_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_scroller_last_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber); + [ :elm_scroller_last_page_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_scroller_page_show(Evas_Object *obj, int h_pagenumber, int v_pagenumber); + [ :elm_scroller_page_show, [ :evas_object, :int, :int ], :void ], + # EAPI void elm_scroller_page_bring_in(Evas_Object *obj, int h_pagenumber, int v_pagenumber); + [ :elm_scroller_page_bring_in, [ :evas_object, :int, :int ], :void ], + # EAPI void elm_scroller_region_bring_in(Evas_Object *obj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h); + [ :elm_scroller_region_bring_in, [ :evas_object, :int, :int, :int, :int ], :void ], + # EAPI void elm_scroller_propagate_events_set(Evas_Object *obj, Eina_Bool propagation); + [ :elm_scroller_propagate_events_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_scroller_propagate_events_get(const Evas_Object *obj); + [ :elm_scroller_propagate_events_get, [ :evas_object ], :bool ], + # EAPI void elm_scroller_gravity_set(Evas_Object *obj, double x, double y); + [ :elm_scroller_gravity_set, [ :evas_object, :double, :double ], :void ], + # EAPI void elm_scroller_gravity_get(const Evas_Object *obj, double *x, double *y); + [ :elm_scroller_gravity_get, [ :evas_object, :pointer, :pointer ], :void ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index ba30448..6ca6065 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -47,6 +47,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_tooltip.h" \ "${INCLUDE}/elementary-0/elm_object_item.h" \ "${INCLUDE}/elementary-0/elm_icon.h" \ + "${INCLUDE}/elementary-0/elm_scroller.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 52a174a..1bef0fc 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -355,6 +355,11 @@ libs << { :modname=>'ElmIcon', :prefix=>'elm_icon', :outfile=>'elm/elm_icon.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_scroller.h', + :modname=>'ElmScroller', :prefix=>'elm_scroller', :outfile=>'elm/elm_scroller.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 6700f66b82f8cc46886a4ed60d1c3e29d853df24 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:05:59 +0100 Subject: parse elm_entry.h and generate elm_entry.rb --- lib/efl/native/elm/elm_entry.rb | 239 ++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 + 3 files changed, 245 insertions(+) create mode 100644 lib/efl/native/elm/elm_entry.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_entry.rb b/lib/efl/native/elm/elm_entry.rb new file mode 100644 index 0000000..529f8e1 --- /dev/null +++ b/lib/efl/native/elm/elm_entry.rb @@ -0,0 +1,239 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmEntry + # + FCT_PREFIX = 'elm_entry_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Text_Format; + enum :elm_text_format, [ :elm_text_format_plain_utf8, :elm_text_format_markup_utf8 ] + # typedef enum {...} Elm_Wrap_Type; + enum :elm_wrap_type, [ :elm_wrap_none, 0, :elm_wrap_char, 1, :elm_wrap_word, 2, :elm_wrap_mixed, 3, :elm_wrap_last, 4 ] + # typedef enum {...} Elm_Input_Panel_Layout; + enum :elm_input_panel_layout, [ :elm_input_panel_layout_normal, :elm_input_panel_layout_number, :elm_input_panel_layout_email, + :elm_input_panel_layout_url, :elm_input_panel_layout_phonenumber, :elm_input_panel_layout_ip, :elm_input_panel_layout_month, + :elm_input_panel_layout_numberonly, :elm_input_panel_layout_invalid, :elm_input_panel_layout_hex, :elm_input_panel_layout_terminal, + :elm_input_panel_layout_password ] + # typedef enum {...} Elm_Input_Panel_Lang; + enum :elm_input_panel_lang, [ :elm_input_panel_lang_automatic, :elm_input_panel_lang_alphabet ] + # typedef enum {...} Elm_Autocapital_Type; + enum :elm_autocapital_type, [ :elm_autocapital_type_none, :elm_autocapital_type_word, :elm_autocapital_type_sentence, + :elm_autocapital_type_allcharacter ] + # typedef enum {...} Elm_Input_Panel_Return_Key_Type; + enum :elm_input_panel_return_key_type, [ :elm_input_panel_return_key_type_default, :elm_input_panel_return_key_type_done, + :elm_input_panel_return_key_type_go, :elm_input_panel_return_key_type_join, :elm_input_panel_return_key_type_login, + :elm_input_panel_return_key_type_next, :elm_input_panel_return_key_type_search, :elm_input_panel_return_key_type_send ] + # + # TYPEDEFS + # typedef struct _Elm_Entry_Anchor_Info Elm_Entry_Anchor_Info; + typedef :pointer, :elm_entry_anchor_info + # typedef Edje_Entry_Change_Info Elm_Entry_Change_Info; + typedef :edje_entry_change_info, :elm_entry_change_info + # typedef struct _Elm_Entry_Filter_Limit_Size Elm_Entry_Filter_Limit_Size; + typedef :pointer, :elm_entry_filter_limit_size + # typedef struct _Elm_Entry_Filter_Accept_Set Elm_Entry_Filter_Accept_Set; + typedef :pointer, :elm_entry_filter_accept_set + # + # CALLBACKS + # typedef void (*Elm_Entry_Filter_Cb) (void *data, Evas_Object *entry, char **text); + callback :elm_entry_filter_cb, [ :pointer, :evas_object, :pointer ], :void + # use in elm_entry_item_provider_* : Evas_Object * (*func)(void *data, Evas_Object * entry, const char *item) + callback :elm_entry_item_provider_cb, [ :pointer, :evas_object, :string ], :evas_object + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_entry_add(Evas_Object *parent); + [ :elm_entry_add, [ :evas_object ], :evas_object ], + # EAPI void elm_entry_single_line_set(Evas_Object *obj, Eina_Bool single_line); + [ :elm_entry_single_line_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_single_line_get(const Evas_Object *obj); + [ :elm_entry_single_line_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_password_set(Evas_Object *obj, Eina_Bool password); + [ :elm_entry_password_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_password_get(const Evas_Object *obj); + [ :elm_entry_password_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_entry_set(Evas_Object *obj, const char *entry); + [ :elm_entry_entry_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_entry_entry_get(const Evas_Object *obj); + [ :elm_entry_entry_get, [ :evas_object ], :string ], + # EAPI void elm_entry_entry_append(Evas_Object *obj, const char *entry); + [ :elm_entry_entry_append, [ :evas_object, :string ], :void ], + # EAPI Eina_Bool elm_entry_is_empty(const Evas_Object *obj); + [ :elm_entry_is_empty, [ :evas_object ], :bool ], + # EAPI const char *elm_entry_selection_get(const Evas_Object *obj); + [ :elm_entry_selection_get, [ :evas_object ], :string ], + # EAPI Evas_Object * elm_entry_textblock_get(Evas_Object *obj); + [ :elm_entry_textblock_get, [ :evas_object ], :evas_object ], + # EAPI void elm_entry_calc_force(Evas_Object *obj); + [ :elm_entry_calc_force, [ :evas_object ], :void ], + # EAPI void elm_entry_entry_insert(Evas_Object *obj, const char *entry); + [ :elm_entry_entry_insert, [ :evas_object, :string ], :void ], + # EAPI void elm_entry_line_wrap_set(Evas_Object *obj, Elm_Wrap_Type wrap); + [ :elm_entry_line_wrap_set, [ :evas_object, :elm_wrap_type ], :void ], + # EAPI Elm_Wrap_Type elm_entry_line_wrap_get(const Evas_Object *obj); + [ :elm_entry_line_wrap_get, [ :evas_object ], :elm_wrap_type ], + # EAPI void elm_entry_editable_set(Evas_Object *obj, Eina_Bool editable); + [ :elm_entry_editable_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_editable_get(const Evas_Object *obj); + [ :elm_entry_editable_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_select_none(Evas_Object *obj); + [ :elm_entry_select_none, [ :evas_object ], :void ], + # EAPI void elm_entry_select_all(Evas_Object *obj); + [ :elm_entry_select_all, [ :evas_object ], :void ], + # EAPI Eina_Bool elm_entry_cursor_next(Evas_Object *obj); + [ :elm_entry_cursor_next, [ :evas_object ], :bool ], + # EAPI Eina_Bool elm_entry_cursor_prev(Evas_Object *obj); + [ :elm_entry_cursor_prev, [ :evas_object ], :bool ], + # EAPI Eina_Bool elm_entry_cursor_up(Evas_Object *obj); + [ :elm_entry_cursor_up, [ :evas_object ], :bool ], + # EAPI Eina_Bool elm_entry_cursor_down(Evas_Object *obj); + [ :elm_entry_cursor_down, [ :evas_object ], :bool ], + # EAPI void elm_entry_cursor_begin_set(Evas_Object *obj); + [ :elm_entry_cursor_begin_set, [ :evas_object ], :void ], + # EAPI void elm_entry_cursor_end_set(Evas_Object *obj); + [ :elm_entry_cursor_end_set, [ :evas_object ], :void ], + # EAPI void elm_entry_cursor_line_begin_set(Evas_Object *obj); + [ :elm_entry_cursor_line_begin_set, [ :evas_object ], :void ], + # EAPI void elm_entry_cursor_line_end_set(Evas_Object *obj); + [ :elm_entry_cursor_line_end_set, [ :evas_object ], :void ], + # EAPI void elm_entry_cursor_selection_begin(Evas_Object *obj); + [ :elm_entry_cursor_selection_begin, [ :evas_object ], :void ], + # EAPI void elm_entry_cursor_selection_end(Evas_Object *obj); + [ :elm_entry_cursor_selection_end, [ :evas_object ], :void ], + # EAPI Eina_Bool elm_entry_cursor_is_format_get(const Evas_Object *obj); + [ :elm_entry_cursor_is_format_get, [ :evas_object ], :bool ], + # EAPI Eina_Bool elm_entry_cursor_is_visible_format_get(const Evas_Object *obj); + [ :elm_entry_cursor_is_visible_format_get, [ :evas_object ], :bool ], + # EAPI char *elm_entry_cursor_content_get(const Evas_Object *obj); + [ :elm_entry_cursor_content_get, [ :evas_object ], :string ], + # EAPI Eina_Bool elm_entry_cursor_geometry_get(const Evas_Object *obj, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h); + [ :elm_entry_cursor_geometry_get, [ :evas_object, :pointer, :pointer, :pointer, :pointer ], :bool ], + # EAPI void elm_entry_cursor_pos_set(Evas_Object *obj, int pos); + [ :elm_entry_cursor_pos_set, [ :evas_object, :int ], :void ], + # EAPI int elm_entry_cursor_pos_get(const Evas_Object *obj); + [ :elm_entry_cursor_pos_get, [ :evas_object ], :int ], + # EAPI void elm_entry_selection_cut(Evas_Object *obj); + [ :elm_entry_selection_cut, [ :evas_object ], :void ], + # EAPI void elm_entry_selection_copy(Evas_Object *obj); + [ :elm_entry_selection_copy, [ :evas_object ], :void ], + # EAPI void elm_entry_selection_paste(Evas_Object *obj); + [ :elm_entry_selection_paste, [ :evas_object ], :void ], + # EAPI void elm_entry_context_menu_clear(Evas_Object *obj); + [ :elm_entry_context_menu_clear, [ :evas_object ], :void ], + # EAPI void elm_entry_context_menu_item_add(Evas_Object *obj, const char *label, const char *icon_file, Elm_Icon_Type icon_type, Evas_Smart_Cb func, const void *data); + [ :elm_entry_context_menu_item_add, [ :evas_object, :string, :string, :elm_icon_type, :evas_smart_cb, :pointer ], :void ], + # EAPI void elm_entry_context_menu_disabled_set(Evas_Object *obj, Eina_Bool disabled); + [ :elm_entry_context_menu_disabled_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_context_menu_disabled_get(const Evas_Object *obj); + [ :elm_entry_context_menu_disabled_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_item_provider_append(Evas_Object *obj, Evas_Object * (*func)(void *data, Evas_Object * entry, const char *item), void *data); + [ :elm_entry_item_provider_append, [ :evas_object, :elm_entry_item_provider_cb, :pointer ], :void ], + # EAPI void elm_entry_item_provider_prepend(Evas_Object *obj, Evas_Object * (*func)(void *data, Evas_Object * entry, const char *item), void *data); + [ :elm_entry_item_provider_prepend, [ :evas_object, :elm_entry_item_provider_cb, :pointer ], :void ], + # EAPI void elm_entry_item_provider_remove(Evas_Object *obj, Evas_Object * (*func)(void *data, Evas_Object * entry, const char *item), void *data); + [ :elm_entry_item_provider_remove, [ :evas_object, :elm_entry_item_provider_cb, :pointer ], :void ], + # EAPI void elm_entry_markup_filter_append(Evas_Object *obj, Elm_Entry_Filter_Cb func, void *data); + [ :elm_entry_markup_filter_append, [ :evas_object, :elm_entry_filter_cb, :pointer ], :void ], + # EAPI void elm_entry_markup_filter_prepend(Evas_Object *obj, Elm_Entry_Filter_Cb func, void *data); + [ :elm_entry_markup_filter_prepend, [ :evas_object, :elm_entry_filter_cb, :pointer ], :void ], + # EAPI void elm_entry_markup_filter_remove(Evas_Object *obj, Elm_Entry_Filter_Cb func, void *data); + [ :elm_entry_markup_filter_remove, [ :evas_object, :elm_entry_filter_cb, :pointer ], :void ], + # EAPI char *elm_entry_markup_to_utf8(const char *s); + [ :elm_entry_markup_to_utf8, [ :string ], :string ], + # EAPI char *elm_entry_utf8_to_markup(const char *s); + [ :elm_entry_utf8_to_markup, [ :string ], :string ], + # EAPI void elm_entry_file_set(Evas_Object *obj, const char *file, Elm_Text_Format format); + [ :elm_entry_file_set, [ :evas_object, :string, :elm_text_format ], :void ], + # EAPI void elm_entry_file_get(const Evas_Object *obj, const char **file, Elm_Text_Format *format); + [ :elm_entry_file_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_entry_file_save(Evas_Object *obj); + [ :elm_entry_file_save, [ :evas_object ], :void ], + # EAPI void elm_entry_autosave_set(Evas_Object *obj, Eina_Bool autosave); + [ :elm_entry_autosave_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_autosave_get(const Evas_Object *obj); + [ :elm_entry_autosave_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_cnp_textonly_set(Evas_Object *obj, Eina_Bool textonly); + [ :elm_entry_cnp_textonly_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_cnp_textonly_get(const Evas_Object *obj); + [ :elm_entry_cnp_textonly_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_scrollable_set(Evas_Object *obj, Eina_Bool scroll); + [ :elm_entry_scrollable_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_scrollable_get(const Evas_Object *obj); + [ :elm_entry_scrollable_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_icon_visible_set(Evas_Object *obj, Eina_Bool setting); + [ :elm_entry_icon_visible_set, [ :evas_object, :bool ], :void ], + # EAPI void elm_entry_end_visible_set(Evas_Object *obj, Eina_Bool setting); + [ :elm_entry_end_visible_set, [ :evas_object, :bool ], :void ], + # EAPI void elm_entry_scrollbar_policy_set(Evas_Object *obj, Elm_Scroller_Policy h, Elm_Scroller_Policy v); + [ :elm_entry_scrollbar_policy_set, [ :evas_object, :elm_scroller_policy, :elm_scroller_policy ], :void ], + # EAPI void elm_entry_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce); + [ :elm_entry_bounce_set, [ :evas_object, :bool, :bool ], :void ], + # EAPI void elm_entry_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce); + [ :elm_entry_bounce_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_entry_input_panel_layout_set(Evas_Object *obj, Elm_Input_Panel_Layout layout); + [ :elm_entry_input_panel_layout_set, [ :evas_object, :elm_input_panel_layout ], :void ], + # EAPI Elm_Input_Panel_Layout elm_entry_input_panel_layout_get(const Evas_Object *obj); + [ :elm_entry_input_panel_layout_get, [ :evas_object ], :elm_input_panel_layout ], + # EAPI void elm_entry_autocapital_type_set(Evas_Object *obj, Elm_Autocapital_Type autocapital_type); + [ :elm_entry_autocapital_type_set, [ :evas_object, :elm_autocapital_type ], :void ], + # EAPI Elm_Autocapital_Type elm_entry_autocapital_type_get(const Evas_Object *obj); + [ :elm_entry_autocapital_type_get, [ :evas_object ], :elm_autocapital_type ], + # EAPI void elm_entry_input_panel_enabled_set(Evas_Object *obj, Eina_Bool enabled); + [ :elm_entry_input_panel_enabled_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_input_panel_enabled_get(const Evas_Object *obj); + [ :elm_entry_input_panel_enabled_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_input_panel_show(Evas_Object *obj); + [ :elm_entry_input_panel_show, [ :evas_object ], :void ], + # EAPI void elm_entry_input_panel_hide(Evas_Object *obj); + [ :elm_entry_input_panel_hide, [ :evas_object ], :void ], + # EAPI void elm_entry_input_panel_language_set(Evas_Object *obj, Elm_Input_Panel_Lang lang); + [ :elm_entry_input_panel_language_set, [ :evas_object, :elm_input_panel_lang ], :void ], + # EAPI Elm_Input_Panel_Lang elm_entry_input_panel_language_get(const Evas_Object *obj); + [ :elm_entry_input_panel_language_get, [ :evas_object ], :elm_input_panel_lang ], + # EAPI void elm_entry_input_panel_imdata_set(Evas_Object *obj, const void *data, int len); + [ :elm_entry_input_panel_imdata_set, [ :evas_object, :pointer, :int ], :void ], + # EAPI void elm_entry_input_panel_imdata_get(const Evas_Object *obj, void *data, int *len); + [ :elm_entry_input_panel_imdata_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_entry_input_panel_return_key_type_set(Evas_Object *obj, Elm_Input_Panel_Return_Key_Type return_key_type); + [ :elm_entry_input_panel_return_key_type_set, [ :evas_object, :elm_input_panel_return_key_type ], :void ], + # EAPI Elm_Input_Panel_Return_Key_Type elm_entry_input_panel_return_key_type_get(const Evas_Object *obj); + [ :elm_entry_input_panel_return_key_type_get, [ :evas_object ], :elm_input_panel_return_key_type ], + # EAPI void elm_entry_input_panel_return_key_disabled_set(Evas_Object *obj, Eina_Bool disabled); + [ :elm_entry_input_panel_return_key_disabled_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_input_panel_return_key_disabled_get(const Evas_Object *obj); + [ :elm_entry_input_panel_return_key_disabled_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_imf_context_reset(Evas_Object *obj); + [ :elm_entry_imf_context_reset, [ :evas_object ], :void ], + # EAPI void elm_entry_prediction_allow_set(Evas_Object *obj, Eina_Bool prediction); + [ :elm_entry_prediction_allow_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_entry_prediction_allow_get(const Evas_Object *obj); + [ :elm_entry_prediction_allow_get, [ :evas_object ], :bool ], + # EAPI void elm_entry_filter_limit_size(void *data, Evas_Object *entry, char **text); + [ :elm_entry_filter_limit_size, [ :pointer, :evas_object, :pointer ], :void ], + # EAPI void elm_entry_filter_accept_set(void *data, Evas_Object *entry, char **text); + [ :elm_entry_filter_accept_set, [ :pointer, :evas_object, :pointer ], :void ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 6ca6065..a763dfe 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -48,6 +48,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_object_item.h" \ "${INCLUDE}/elementary-0/elm_icon.h" \ "${INCLUDE}/elementary-0/elm_scroller.h" \ + "${INCLUDE}/elementary-0/elm_entry.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 1bef0fc..4c6dc02 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -360,6 +360,11 @@ libs << { :modname=>'ElmScroller', :prefix=>'elm_scroller', :outfile=>'elm/elm_scroller.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_entry.h', + :modname=>'ElmEntry', :prefix=>'elm_entry', :outfile=>'elm/elm_entry.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 31832748e24d10b0422126ebc020b555520aeb49 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:14:43 +0100 Subject: tools/genruby: add edje,elm_icon,elm_scroller to elm_entry requires --- lib/efl/native/elm/elm_entry.rb | 3 +++ tools/genruby.rb | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_entry.rb b/lib/efl/native/elm/elm_entry.rb index 529f8e1..6e1ba88 100644 --- a/lib/efl/native/elm/elm_entry.rb +++ b/lib/efl/native/elm/elm_entry.rb @@ -2,7 +2,10 @@ # -*- coding: UTF-8 -*- # require 'efl/native' +require 'efl/native/edje' require 'efl/native/elementary' +require 'efl/native/elm/elm_icon' +require 'efl/native/elm/elm_scroller' # module Efl # diff --git a/tools/genruby.rb b/tools/genruby.rb index 4c6dc02..ab78aec 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -363,7 +363,8 @@ libs << { libs << { :lib=>ELM_LIB,:header=>'elm_entry.h', :modname=>'ElmEntry', :prefix=>'elm_entry', :outfile=>'elm/elm_entry.rb', - :requires=>["#{NATIVE}/elementary"], :constants=>[] + :requires=>["#{NATIVE}/edje","#{NATIVE}/elementary","#{NATIVE}/elm/elm_icon","#{NATIVE}/elm/elm_scroller"], :constants=>[] +} } Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 742806e336e6984e4ffa8d87ec6fdde61cbfeaef Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:16:29 +0100 Subject: parse elm_list.h and generate elm_list.rb --- lib/efl/native/elm/elm_list.rb | 105 +++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 4 ++ 3 files changed, 110 insertions(+) create mode 100644 lib/efl/native/elm/elm_list.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_list.rb b/lib/efl/native/elm/elm_list.rb new file mode 100644 index 0000000..8fcbecd --- /dev/null +++ b/lib/efl/native/elm/elm_list.rb @@ -0,0 +1,105 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +require 'efl/native/elm/elm_scroller' +# +module Efl + # + module ElmList + # + FCT_PREFIX = 'elm_list_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_List_Mode; + enum :elm_list_mode, [ :elm_list_compress, 0, :elm_list_scroll, 1, :elm_list_limit, 2, :elm_list_expand, 3, :elm_list_last, 4 ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_list_add(Evas_Object *parent); + [ :elm_list_add, [ :evas_object ], :evas_object ], + # EAPI void elm_list_go(Evas_Object *obj); + [ :elm_list_go, [ :evas_object ], :void ], + # EAPI void elm_list_multi_select_set(Evas_Object *obj, Eina_Bool multi); + [ :elm_list_multi_select_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_list_multi_select_get(const Evas_Object *obj); + [ :elm_list_multi_select_get, [ :evas_object ], :bool ], + # EAPI void elm_list_mode_set(Evas_Object *obj, Elm_List_Mode mode); + [ :elm_list_mode_set, [ :evas_object, :elm_list_mode ], :void ], + # EAPI Elm_List_Mode elm_list_mode_get(const Evas_Object *obj); + [ :elm_list_mode_get, [ :evas_object ], :elm_list_mode ], + # EAPI void elm_list_horizontal_set(Evas_Object *obj, Eina_Bool horizontal); + [ :elm_list_horizontal_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_list_horizontal_get(const Evas_Object *obj); + [ :elm_list_horizontal_get, [ :evas_object ], :bool ], + # EAPI void elm_list_always_select_mode_set(Evas_Object *obj, Eina_Bool always_select); + [ :elm_list_always_select_mode_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_list_always_select_mode_get(const Evas_Object *obj); + [ :elm_list_always_select_mode_get, [ :evas_object ], :bool ], + # EAPI void elm_list_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce); + [ :elm_list_bounce_set, [ :evas_object, :bool, :bool ], :void ], + # EAPI void elm_list_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce); + [ :elm_list_bounce_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_list_scroller_policy_set(Evas_Object *obj, Elm_Scroller_Policy policy_h, Elm_Scroller_Policy policy_v); + [ :elm_list_scroller_policy_set, [ :evas_object, :elm_scroller_policy, :elm_scroller_policy ], :void ], + # EAPI void elm_list_scroller_policy_get(const Evas_Object *obj, Elm_Scroller_Policy *policy_h, Elm_Scroller_Policy *policy_v); + [ :elm_list_scroller_policy_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI Elm_Object_Item *elm_list_item_append(Evas_Object *obj, const char *label, Evas_Object *icon, Evas_Object *end, Evas_Smart_Cb func, const void *data); + [ :elm_list_item_append, [ :evas_object, :string, :evas_object, :evas_object, :evas_smart_cb, :pointer ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_list_item_prepend(Evas_Object *obj, const char *label, Evas_Object *icon, Evas_Object *end, Evas_Smart_Cb func, const void *data); + [ :elm_list_item_prepend, [ :evas_object, :string, :evas_object, :evas_object, :evas_smart_cb, :pointer ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_list_item_insert_before(Evas_Object *obj, Elm_Object_Item *before, const char *label, Evas_Object *icon, Evas_Object *end, Evas_Smart_Cb func, const void *data); + [ :elm_list_item_insert_before, [ :evas_object, :elm_object_item, :string, :evas_object, :evas_object, :evas_smart_cb, :pointer ], + :elm_object_item ], + # EAPI Elm_Object_Item *elm_list_item_insert_after(Evas_Object *obj, Elm_Object_Item *after, const char *label, Evas_Object *icon, Evas_Object *end, Evas_Smart_Cb func, const void *data); + [ :elm_list_item_insert_after, [ :evas_object, :elm_object_item, :string, :evas_object, :evas_object, :evas_smart_cb, :pointer ], + :elm_object_item ], + # EAPI Elm_Object_Item *elm_list_item_sorted_insert(Evas_Object *obj, const char *label, Evas_Object *icon, Evas_Object *end, Evas_Smart_Cb func, const void *data, Eina_Compare_Cb cmp_func); + [ :elm_list_item_sorted_insert, [ :evas_object, :string, :evas_object, :evas_object, :evas_smart_cb, :pointer, :eina_compare_cb ], + :elm_object_item ], + # EAPI void elm_list_clear(Evas_Object *obj); + [ :elm_list_clear, [ :evas_object ], :void ], + # EAPI const Eina_List *elm_list_items_get(const Evas_Object *obj); + [ :elm_list_items_get, [ :evas_object ], :eina_list ], + # EAPI Elm_Object_Item *elm_list_selected_item_get(const Evas_Object *obj); + [ :elm_list_selected_item_get, [ :evas_object ], :elm_object_item ], + # EAPI const Eina_List *elm_list_selected_items_get(const Evas_Object *obj); + [ :elm_list_selected_items_get, [ :evas_object ], :eina_list ], + # EAPI void elm_list_item_selected_set(Elm_Object_Item *it, Eina_Bool selected); + [ :elm_list_item_selected_set, [ :elm_object_item, :bool ], :void ], + # EAPI Eina_Bool elm_list_item_selected_get(const Elm_Object_Item *it); + [ :elm_list_item_selected_get, [ :elm_object_item ], :bool ], + # EAPI void elm_list_item_separator_set(Elm_Object_Item *it, Eina_Bool setting); + [ :elm_list_item_separator_set, [ :elm_object_item, :bool ], :void ], + # EAPI Eina_Bool elm_list_item_separator_get(const Elm_Object_Item *it); + [ :elm_list_item_separator_get, [ :elm_object_item ], :bool ], + # EAPI void elm_list_item_show(Elm_Object_Item *it); + [ :elm_list_item_show, [ :elm_object_item ], :void ], + # EAPI void elm_list_item_bring_in(Elm_Object_Item *it); + [ :elm_list_item_bring_in, [ :elm_object_item ], :void ], + # EAPI Evas_Object *elm_list_item_object_get(const Elm_Object_Item *it); + [ :elm_list_item_object_get, [ :elm_object_item ], :evas_object ], + # EAPI Elm_Object_Item *elm_list_item_prev(const Elm_Object_Item *it); + [ :elm_list_item_prev, [ :elm_object_item ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_list_item_next(const Elm_Object_Item *it); + [ :elm_list_item_next, [ :elm_object_item ], :elm_object_item ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index a763dfe..6b0b8e7 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -49,6 +49,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_icon.h" \ "${INCLUDE}/elementary-0/elm_scroller.h" \ "${INCLUDE}/elementary-0/elm_entry.h" \ + "${INCLUDE}/elementary-0/elm_list.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index ab78aec..c547bc6 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -365,6 +365,10 @@ libs << { :modname=>'ElmEntry', :prefix=>'elm_entry', :outfile=>'elm/elm_entry.rb', :requires=>["#{NATIVE}/edje","#{NATIVE}/elementary","#{NATIVE}/elm/elm_icon","#{NATIVE}/elm/elm_scroller"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_list.h', + :modname=>'ElmList', :prefix=>'elm_list', :outfile=>'elm/elm_list.rb', + :requires=>["#{NATIVE}/elementary","#{NATIVE}/elm/elm_scroller"], :constants=>[] } Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From ea0778f802ea5864e60a22ec826a691aed7b5c70 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:22:47 +0100 Subject: parse elm_win.h and generate elm_win.rb --- lib/efl/native/elm/elm_win.rb | 189 ++++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 ++ 3 files changed, 195 insertions(+) create mode 100644 lib/efl/native/elm/elm_win.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_win.rb b/lib/efl/native/elm/elm_win.rb new file mode 100644 index 0000000..46ed54d --- /dev/null +++ b/lib/efl/native/elm/elm_win.rb @@ -0,0 +1,189 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmWin + # + FCT_PREFIX = 'elm_win_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Win_Type; + enum :elm_win_type, [ :elm_win_basic, :elm_win_dialog_basic, :elm_win_desktop, :elm_win_dock, :melm_win_toolbar, :elm_win_menu, + :elm_win_utility, :elm_win_splash, :elm_win_dropdown_menu, :elm_win_popup_menu, :elm_win_tooltip, :telm_win_notification, :elm_win_combo, + :elm_win_dnd, :elm_win_inlined_image, :teeelm_win_socket_image, :n ] + # typedef enum {...} Elm_Win_Keyboard_Mode; + enum :elm_win_keyboard_mode, [ :elm_win_keyboard_unknown, :elm_win_keyboard_off, :elm_win_keyboard_on, :elm_win_keyboard_alpha, + :elm_win_keyboard_numeric, :elm_win_keyboard_pin, :elm_win_keyboard_phone_number, :elm_win_keyboard_hex, :elm_win_keyboard_terminal, + :elm_win_keyboard_password, :elm_win_keyboard_ip, :elm_win_keyboard_host, :elm_win_keyboard_file, :elm_win_keyboard_url, :elm_win_keyboard_keypad, + :elm_win_keyboard_j2me ] + # typedef enum {...} Elm_Win_Indicator_Mode; + enum :elm_win_indicator_mode, [ :elm_win_indicator_unknown, :elm_win_indicator_hide, :elm_win_indicator_show ] + # typedef enum {...} Elm_Illume_Command; + enum :elm_illume_command, [ :elm_illume_command_focus_back, :elm_illume_command_focus_forward, :elm_illume_command_focus_home, + :elm_illume_command_close ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_win_add(Evas_Object *parent, const char *name, Elm_Win_Type type); + [ :elm_win_add, [ :evas_object, :string, :elm_win_type ], :evas_object ], + # EAPI Evas_Object *elm_win_util_standard_add(const char *name, const char *title); + [ :elm_win_util_standard_add, [ :string, :string ], :evas_object ], + # EAPI void elm_win_resize_object_add(Evas_Object *obj, Evas_Object *subobj); + [ :elm_win_resize_object_add, [ :evas_object, :evas_object ], :void ], + # EAPI void elm_win_resize_object_del(Evas_Object *obj, Evas_Object *subobj); + [ :elm_win_resize_object_del, [ :evas_object, :evas_object ], :void ], + # EAPI void elm_win_title_set(Evas_Object *obj, const char *title); + [ :elm_win_title_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_win_title_get(const Evas_Object *obj); + [ :elm_win_title_get, [ :evas_object ], :string ], + # EAPI void elm_win_autodel_set(Evas_Object *obj, Eina_Bool autodel); + [ :elm_win_autodel_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_autodel_get(const Evas_Object *obj); + [ :elm_win_autodel_get, [ :evas_object ], :bool ], + # EAPI void elm_win_activate(Evas_Object *obj); + [ :elm_win_activate, [ :evas_object ], :void ], + # EAPI void elm_win_lower(Evas_Object *obj); + [ :elm_win_lower, [ :evas_object ], :void ], + # EAPI void elm_win_raise(Evas_Object *obj); + [ :elm_win_raise, [ :evas_object ], :void ], + # EAPI void elm_win_center(Evas_Object *obj, Eina_Bool h, Eina_Bool v); + [ :elm_win_center, [ :evas_object, :bool, :bool ], :void ], + # EAPI void elm_win_borderless_set(Evas_Object *obj, Eina_Bool borderless); + [ :elm_win_borderless_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_borderless_get(const Evas_Object *obj); + [ :elm_win_borderless_get, [ :evas_object ], :bool ], + # EAPI void elm_win_shaped_set(Evas_Object *obj, Eina_Bool shaped); + [ :elm_win_shaped_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_shaped_get(const Evas_Object *obj); + [ :elm_win_shaped_get, [ :evas_object ], :bool ], + # EAPI void elm_win_alpha_set(Evas_Object *obj, Eina_Bool alpha); + [ :elm_win_alpha_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_alpha_get(const Evas_Object *obj); + [ :elm_win_alpha_get, [ :evas_object ], :bool ], + # EAPI void elm_win_transparent_set(Evas_Object *obj, Eina_Bool transparent); + [ :elm_win_transparent_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_transparent_get(const Evas_Object *obj); + [ :elm_win_transparent_get, [ :evas_object ], :bool ], + # EAPI void elm_win_override_set(Evas_Object *obj, Eina_Bool override); + [ :elm_win_override_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_override_get(const Evas_Object *obj); + [ :elm_win_override_get, [ :evas_object ], :bool ], + # EAPI void elm_win_fullscreen_set(Evas_Object *obj, Eina_Bool fullscreen); + [ :elm_win_fullscreen_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_fullscreen_get(const Evas_Object *obj); + [ :elm_win_fullscreen_get, [ :evas_object ], :bool ], + # EAPI void elm_win_maximized_set(Evas_Object *obj, Eina_Bool maximized); + [ :elm_win_maximized_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_maximized_get(const Evas_Object *obj); + [ :elm_win_maximized_get, [ :evas_object ], :bool ], + # EAPI void elm_win_iconified_set(Evas_Object *obj, Eina_Bool iconified); + [ :elm_win_iconified_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_iconified_get(const Evas_Object *obj); + [ :elm_win_iconified_get, [ :evas_object ], :bool ], + # EAPI void elm_win_layer_set(Evas_Object *obj, int layer); + [ :elm_win_layer_set, [ :evas_object, :int ], :void ], + # EAPI int elm_win_layer_get(const Evas_Object *obj); + [ :elm_win_layer_get, [ :evas_object ], :int ], + # EAPI void elm_win_rotation_set(Evas_Object *obj, int rotation); + [ :elm_win_rotation_set, [ :evas_object, :int ], :void ], + # EAPI void elm_win_rotation_with_resize_set(Evas_Object *obj, int rotation); + [ :elm_win_rotation_with_resize_set, [ :evas_object, :int ], :void ], + # EAPI int elm_win_rotation_get(const Evas_Object *obj); + [ :elm_win_rotation_get, [ :evas_object ], :int ], + # EAPI void elm_win_sticky_set(Evas_Object *obj, Eina_Bool sticky); + [ :elm_win_sticky_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_sticky_get(const Evas_Object *obj); + [ :elm_win_sticky_get, [ :evas_object ], :bool ], + # EAPI void elm_win_conformant_set(Evas_Object *obj, Eina_Bool conformant); + [ :elm_win_conformant_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_conformant_get(const Evas_Object *obj); + [ :elm_win_conformant_get, [ :evas_object ], :bool ], + # EAPI void elm_win_quickpanel_set(Evas_Object *obj, Eina_Bool quickpanel); + [ :elm_win_quickpanel_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_quickpanel_get(const Evas_Object *obj); + [ :elm_win_quickpanel_get, [ :evas_object ], :bool ], + # EAPI void elm_win_quickpanel_priority_major_set(Evas_Object *obj, int priority); + [ :elm_win_quickpanel_priority_major_set, [ :evas_object, :int ], :void ], + # EAPI int elm_win_quickpanel_priority_major_get(const Evas_Object *obj); + [ :elm_win_quickpanel_priority_major_get, [ :evas_object ], :int ], + # EAPI void elm_win_quickpanel_priority_minor_set(Evas_Object *obj, int priority); + [ :elm_win_quickpanel_priority_minor_set, [ :evas_object, :int ], :void ], + # EAPI int elm_win_quickpanel_priority_minor_get(const Evas_Object *obj); + [ :elm_win_quickpanel_priority_minor_get, [ :evas_object ], :int ], + # EAPI void elm_win_quickpanel_zone_set(Evas_Object *obj, int zone); + [ :elm_win_quickpanel_zone_set, [ :evas_object, :int ], :void ], + # EAPI int elm_win_quickpanel_zone_get(const Evas_Object *obj); + [ :elm_win_quickpanel_zone_get, [ :evas_object ], :int ], + # EAPI void elm_win_prop_focus_skip_set(Evas_Object *obj, Eina_Bool skip); + [ :elm_win_prop_focus_skip_set, [ :evas_object, :bool ], :void ], + # EAPI void elm_win_illume_command_send(Evas_Object *obj, Elm_Illume_Command command, void *params); + [ :elm_win_illume_command_send, [ :evas_object, :elm_illume_command, :pointer ], :void ], + # EAPI Evas_Object *elm_win_inlined_image_object_get(Evas_Object *obj); + [ :elm_win_inlined_image_object_get, [ :evas_object ], :evas_object ], + # EAPI Eina_Bool elm_win_focus_get(const Evas_Object *obj); + [ :elm_win_focus_get, [ :evas_object ], :bool ], + # EAPI void elm_win_screen_constrain_set(Evas_Object *obj, Eina_Bool constrain); + [ :elm_win_screen_constrain_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_screen_constrain_get(Evas_Object *obj); + [ :elm_win_screen_constrain_get, [ :evas_object ], :bool ], + # EAPI void elm_win_screen_size_get(const Evas_Object *obj, int *x, int *y, int *w, int *h); + [ :elm_win_screen_size_get, [ :evas_object, :pointer, :pointer, :pointer, :pointer ], :void ], + # EAPI void elm_win_focus_highlight_enabled_set(Evas_Object *obj, Eina_Bool enabled); + [ :elm_win_focus_highlight_enabled_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_focus_highlight_enabled_get(const Evas_Object *obj); + [ :elm_win_focus_highlight_enabled_get, [ :evas_object ], :bool ], + # EAPI void elm_win_focus_highlight_style_set(Evas_Object *obj, const char *style); + [ :elm_win_focus_highlight_style_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_win_focus_highlight_style_get(const Evas_Object *obj); + [ :elm_win_focus_highlight_style_get, [ :evas_object ], :string ], + # EAPI void elm_win_keyboard_mode_set(Evas_Object *obj, Elm_Win_Keyboard_Mode mode); + [ :elm_win_keyboard_mode_set, [ :evas_object, :elm_win_keyboard_mode ], :void ], + # EAPI Elm_Win_Keyboard_Mode elm_win_keyboard_mode_get(const Evas_Object *obj); + [ :elm_win_keyboard_mode_get, [ :evas_object ], :elm_win_keyboard_mode ], + # EAPI void elm_win_keyboard_win_set(Evas_Object *obj, Eina_Bool is_keyboard); + [ :elm_win_keyboard_win_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_win_keyboard_win_get(const Evas_Object *obj); + [ :elm_win_keyboard_win_get, [ :evas_object ], :bool ], + # EAPI void elm_win_indicator_mode_set(Evas_Object *obj, Elm_Win_Indicator_Mode mode); + [ :elm_win_indicator_mode_set, [ :evas_object, :elm_win_indicator_mode ], :void ], + # EAPI Elm_Win_Indicator_Mode elm_win_indicator_mode_get(const Evas_Object *obj); + [ :elm_win_indicator_mode_get, [ :evas_object ], :elm_win_indicator_mode ], + # EAPI void elm_win_screen_position_get(const Evas_Object *obj, int *x, int *y); + [ :elm_win_screen_position_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI Eina_Bool elm_win_socket_listen(Evas_Object *obj, const char *svcname, int svcnum, Eina_Bool svcsys); + [ :elm_win_socket_listen, [ :evas_object, :string, :int, :bool ], :bool ], + # EAPI Evas_Object *elm_win_inwin_add(Evas_Object *parent); + [ :elm_win_inwin_add, [ :evas_object ], :evas_object ], + # EAPI void elm_win_inwin_activate(Evas_Object *obj); + [ :elm_win_inwin_activate, [ :evas_object ], :void ], + # EAPI void elm_win_inwin_content_set(Evas_Object *obj, Evas_Object *content); + [ :elm_win_inwin_content_set, [ :evas_object, :evas_object ], :void ], + # EAPI Evas_Object *elm_win_inwin_content_get(const Evas_Object *obj); + [ :elm_win_inwin_content_get, [ :evas_object ], :evas_object ], + # EAPI Evas_Object *elm_win_inwin_content_unset(Evas_Object *obj); + [ :elm_win_inwin_content_unset, [ :evas_object ], :evas_object ], + # EAPI Ecore_X_Window elm_win_xwindow_get(const Evas_Object *obj); + [ :elm_win_xwindow_get, [ :evas_object ], :uint ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 6b0b8e7..7139a4e 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -50,6 +50,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_scroller.h" \ "${INCLUDE}/elementary-0/elm_entry.h" \ "${INCLUDE}/elementary-0/elm_list.h" \ + "${INCLUDE}/elementary-0/elm_win.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index c547bc6..1ac1144 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -370,6 +370,11 @@ libs << { :modname=>'ElmList', :prefix=>'elm_list', :outfile=>'elm/elm_list.rb', :requires=>["#{NATIVE}/elementary","#{NATIVE}/elm/elm_scroller"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_win.h', + :modname=>'ElmWin', :prefix=>'elm_win', :outfile=>'elm/elm_win.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From c70913b5ec836a345a6b96ec72e16d789d2705b2 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:51:27 +0100 Subject: parse elm_bg.h and generate elm_bg.rb --- lib/efl/native/elm/elm_bg.rb | 53 ++++++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++++ 3 files changed, 59 insertions(+) create mode 100644 lib/efl/native/elm/elm_bg.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_bg.rb b/lib/efl/native/elm/elm_bg.rb new file mode 100644 index 0000000..7aa1c61 --- /dev/null +++ b/lib/efl/native/elm/elm_bg.rb @@ -0,0 +1,53 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmBg + # + FCT_PREFIX = 'elm_bg_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Bg_Option; + enum :elm_bg_option, [ :elm_bg_option_center, :elm_bg_option_scale, :elm_bg_option_stretch, :elm_bg_option_tile ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_bg_add(Evas_Object *parent); + [ :elm_bg_add, [ :evas_object ], :evas_object ], + # EAPI void elm_bg_file_set(Evas_Object *obj, const char *file, const char *group); + [ :elm_bg_file_set, [ :evas_object, :string, :string ], :void ], + # EAPI void elm_bg_file_get(const Evas_Object *obj, const char **file, const char **group); + [ :elm_bg_file_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_bg_option_set(Evas_Object *obj, Elm_Bg_Option option); + [ :elm_bg_option_set, [ :evas_object, :elm_bg_option ], :void ], + # EAPI Elm_Bg_Option elm_bg_option_get(const Evas_Object *obj); + [ :elm_bg_option_get, [ :evas_object ], :elm_bg_option ], + # EAPI void elm_bg_color_set(Evas_Object *obj, int r, int g, int b); + [ :elm_bg_color_set, [ :evas_object, :int, :int, :int ], :void ], + # EAPI void elm_bg_color_get(const Evas_Object *obj, int *r, int *g, int *b); + [ :elm_bg_color_get, [ :evas_object, :pointer, :pointer, :pointer ], :void ], + # EAPI void elm_bg_load_size_set(Evas_Object *obj, Evas_Coord w, Evas_Coord h); + [ :elm_bg_load_size_set, [ :evas_object, :int, :int ], :void ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 7139a4e..7b3b207 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -51,6 +51,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_entry.h" \ "${INCLUDE}/elementary-0/elm_list.h" \ "${INCLUDE}/elementary-0/elm_win.h" \ + "${INCLUDE}/elementary-0/elm_bg.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 1ac1144..545459f 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -375,6 +375,11 @@ libs << { :modname=>'ElmWin', :prefix=>'elm_win', :outfile=>'elm/elm_win.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_bg.h', + :modname=>'ElmBg', :prefix=>'elm_bg', :outfile=>'elm/elm_bg.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 6cfd759b104d175f7a1249f09ef84aa742f020e0 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:54:39 +0100 Subject: parse elm_label.h and generate elm_label.rb --- lib/efl/native/elm/elm_label.rb | 60 +++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 ++++ 3 files changed, 66 insertions(+) create mode 100644 lib/efl/native/elm/elm_label.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_label.rb b/lib/efl/native/elm/elm_label.rb new file mode 100644 index 0000000..f17f5e9 --- /dev/null +++ b/lib/efl/native/elm/elm_label.rb @@ -0,0 +1,60 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +require 'efl/native/elm/elm_entry' +# +module Efl + # + module ElmLabel + # + FCT_PREFIX = 'elm_label_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_label_add(Evas_Object *parent); + [ :elm_label_add, [ :evas_object ], :evas_object ], + # EAPI void elm_label_line_wrap_set(Evas_Object *obj, Elm_Wrap_Type wrap); + [ :elm_label_line_wrap_set, [ :evas_object, :elm_wrap_type ], :void ], + # EAPI Elm_Wrap_Type elm_label_line_wrap_get(const Evas_Object *obj); + [ :elm_label_line_wrap_get, [ :evas_object ], :elm_wrap_type ], + # EAPI void elm_label_wrap_width_set(Evas_Object *obj, Evas_Coord w); + [ :elm_label_wrap_width_set, [ :evas_object, :int ], :void ], + # EAPI Evas_Coord elm_label_wrap_width_get(const Evas_Object *obj); + [ :elm_label_wrap_width_get, [ :evas_object ], :int ], + # EAPI void elm_label_wrap_height_set(Evas_Object *obj, Evas_Coord h); + [ :elm_label_wrap_height_set, [ :evas_object, :int ], :void ], + # EAPI Evas_Coord elm_label_wrap_height_get(const Evas_Object *obj); + [ :elm_label_wrap_height_get, [ :evas_object ], :int ], + # EAPI void elm_label_ellipsis_set(Evas_Object *obj, Eina_Bool ellipsis); + [ :elm_label_ellipsis_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_label_ellipsis_get(const Evas_Object *obj); + [ :elm_label_ellipsis_get, [ :evas_object ], :bool ], + # EAPI void elm_label_slide_set(Evas_Object *obj, Eina_Bool slide); + [ :elm_label_slide_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_label_slide_get(const Evas_Object *obj); + [ :elm_label_slide_get, [ :evas_object ], :bool ], + # EAPI void elm_label_slide_duration_set(Evas_Object *obj, double duration); + [ :elm_label_slide_duration_set, [ :evas_object, :double ], :void ], + # EAPI double elm_label_slide_duration_get(const Evas_Object *obj); + [ :elm_label_slide_duration_get, [ :evas_object ], :double ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 7b3b207..7d3965f 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -52,6 +52,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_list.h" \ "${INCLUDE}/elementary-0/elm_win.h" \ "${INCLUDE}/elementary-0/elm_bg.h" \ + "${INCLUDE}/elementary-0/elm_label.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 545459f..0b4188a 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -380,6 +380,11 @@ libs << { :modname=>'ElmBg', :prefix=>'elm_bg', :outfile=>'elm/elm_bg.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_label.h', + :modname=>'ElmLabel', :prefix=>'elm_label', :outfile=>'elm/elm_label.rb', + :requires=>["#{NATIVE}/elementary","#{NATIVE}/elm/elm_entry"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From c7c4a7cea393e77d0a82a660c67da178ac334f81 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 10:56:33 +0100 Subject: parse elm_object.h and generate elm_object.rb --- lib/efl/native/elm/elm_object.rb | 74 ++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 3 files changed, 80 insertions(+) create mode 100644 lib/efl/native/elm/elm_object.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_object.rb b/lib/efl/native/elm/elm_object.rb new file mode 100644 index 0000000..ffeae49 --- /dev/null +++ b/lib/efl/native/elm/elm_object.rb @@ -0,0 +1,74 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/edje' +require 'efl/native/elementary' +# +module Efl + # + module ElmObject + # + FCT_PREFIX = 'elm_object_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI void elm_object_part_text_set(Evas_Object *obj, const char *part, const char *label); + [ :elm_object_part_text_set, [ :evas_object, :string, :string ], :void ], + # EAPI const char *elm_object_part_text_get(const Evas_Object *obj, const char *part); + [ :elm_object_part_text_get, [ :evas_object, :string ], :string ], + # EAPI void elm_object_part_content_set(Evas_Object *obj, const char *part, Evas_Object *content); + [ :elm_object_part_content_set, [ :evas_object, :string, :evas_object ], :void ], + # EAPI Evas_Object *elm_object_part_content_get(const Evas_Object *obj, const char *part); + [ :elm_object_part_content_get, [ :evas_object, :string ], :evas_object ], + # EAPI Evas_Object *elm_object_part_content_unset(Evas_Object *obj, const char *part); + [ :elm_object_part_content_unset, [ :evas_object, :string ], :evas_object ], + # EAPI void elm_object_access_info_set(Evas_Object *obj, const char *txt); + [ :elm_object_access_info_set, [ :evas_object, :string ], :void ], + # EAPI Evas_Object *elm_object_name_find(const Evas_Object *obj, const char *name, int recurse); + [ :elm_object_name_find, [ :evas_object, :string, :int ], :evas_object ], + # EAPI void elm_object_style_set(Evas_Object *obj, const char *style); + [ :elm_object_style_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_object_style_get(const Evas_Object *obj); + [ :elm_object_style_get, [ :evas_object ], :string ], + # EAPI void elm_object_disabled_set(Evas_Object *obj, Eina_Bool disabled); + [ :elm_object_disabled_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_object_disabled_get(const Evas_Object *obj); + [ :elm_object_disabled_get, [ :evas_object ], :bool ], + # EAPI Eina_Bool elm_object_widget_check(const Evas_Object *obj); + [ :elm_object_widget_check, [ :evas_object ], :bool ], + # EAPI Evas_Object *elm_object_parent_widget_get(const Evas_Object *obj); + [ :elm_object_parent_widget_get, [ :evas_object ], :evas_object ], + # EAPI Evas_Object *elm_object_top_widget_get(const Evas_Object *obj); + [ :elm_object_top_widget_get, [ :evas_object ], :evas_object ], + # EAPI const char *elm_object_widget_type_get(const Evas_Object *obj); + [ :elm_object_widget_type_get, [ :evas_object ], :string ], + # EAPI void elm_object_signal_emit(Evas_Object *obj, const char *emission, const char *source); + [ :elm_object_signal_emit, [ :evas_object, :string, :string ], :void ], + # EAPI void elm_object_signal_callback_add(Evas_Object *obj, const char *emission, const char *source, Edje_Signal_Cb func, void *data); + [ :elm_object_signal_callback_add, [ :evas_object, :string, :string, :edje_signal_cb, :pointer ], :void ], + # EAPI void *elm_object_signal_callback_del(Evas_Object *obj, const char *emission, const char *source, Edje_Signal_Cb func); + [ :elm_object_signal_callback_del, [ :evas_object, :string, :string, :edje_signal_cb ], :pointer ], + # EAPI void elm_object_event_callback_add(Evas_Object *obj, Elm_Event_Cb func, const void *data); + [ :elm_object_event_callback_add, [ :evas_object, :elm_event_cb, :pointer ], :void ], + # EAPI void *elm_object_event_callback_del(Evas_Object *obj, Elm_Event_Cb func, const void *data); + [ :elm_object_event_callback_del, [ :evas_object, :elm_event_cb, :pointer ], :pointer ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 7d3965f..de52d7d 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -53,6 +53,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_win.h" \ "${INCLUDE}/elementary-0/elm_bg.h" \ "${INCLUDE}/elementary-0/elm_label.h" \ + "${INCLUDE}/elementary-0/elm_object.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 0b4188a..b044f62 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -385,6 +385,11 @@ libs << { :modname=>'ElmLabel', :prefix=>'elm_label', :outfile=>'elm/elm_label.rb', :requires=>["#{NATIVE}/elementary","#{NATIVE}/elm/elm_entry"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_object.h', + :modname=>'ElmObject', :prefix=>'elm_object', :outfile=>'elm/elm_object.rb', + :requires=>["#{NATIVE}/edje","#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From f41bbfd3a683793044361249544c8bc7bb2747ce Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 14:43:35 +0100 Subject: elm_object_item, elm_tooltip: follow C API --- lib/efl/native/elm/elm_object_item.rb | 4 ---- lib/efl/native/elm/elm_tooltip.rb | 4 ---- 2 files changed, 8 deletions(-) (limited to 'lib/efl/native/elm') diff --git a/lib/efl/native/elm/elm_object_item.rb b/lib/efl/native/elm/elm_object_item.rb index f2f634d..703aba0 100644 --- a/lib/efl/native/elm/elm_object_item.rb +++ b/lib/efl/native/elm/elm_object_item.rb @@ -83,10 +83,6 @@ module Efl [ :elm_object_item_cursor_engine_only_set, [ :elm_object_item, :bool ], :void ], # EAPI Eina_Bool elm_object_item_cursor_engine_only_get(const Elm_Object_Item *it); [ :elm_object_item_cursor_engine_only_get, [ :elm_object_item ], :bool ], - # EAPI void elm_object_item_smart_callback_add(Elm_Object_Item *it, const char *event, Elm_Object_Item_Smart_Cb func, const void *data); - [ :elm_object_item_smart_callback_add, [ :elm_object_item, :string, :elm_object_item_smart_cb, :pointer ], :void ], - # EAPI void *elm_object_item_smart_callback_del(Elm_Object_Item *it, const char *event, Elm_Object_Item_Smart_Cb func); - [ :elm_object_item_smart_callback_del, [ :elm_object_item, :string, :elm_object_item_smart_cb ], :pointer ], ] # attach_fcts fcts diff --git a/lib/efl/native/elm/elm_tooltip.rb b/lib/efl/native/elm/elm_tooltip.rb index 233e154..f8fa2ce 100644 --- a/lib/efl/native/elm/elm_tooltip.rb +++ b/lib/efl/native/elm/elm_tooltip.rb @@ -29,10 +29,6 @@ module Efl # # FUNCTIONS fcts = [ - # EAPI double elm_tooltip_delay_get(void); - [ :elm_tooltip_delay_get, [ ], :double ], - # EAPI Eina_Bool elm_tooltip_delay_set(double delay); - [ :elm_tooltip_delay_set, [ :double ], :bool ], # EAPI void elm_object_tooltip_show(Evas_Object *obj); [ :elm_object_tooltip_show, [ :evas_object ], :void ], # EAPI void elm_object_tooltip_hide(Evas_Object *obj); -- cgit v1.2.3 From c858ea430f766c94b5f9ca1cb716306b8b6d7031 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 14:52:35 +0100 Subject: parse elm_box.h, generate elm_box.rb --- lib/efl/elm/elm_box.rb | 42 ++++++++++++++++++++++ lib/efl/native/elm/elm_box.rb | 81 +++++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 4 files changed, 129 insertions(+) create mode 100644 lib/efl/elm/elm_box.rb create mode 100644 lib/efl/native/elm/elm_box.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_box.rb b/lib/efl/elm/elm_box.rb new file mode 100644 index 0000000..b0539a2 --- /dev/null +++ b/lib/efl/elm/elm_box.rb @@ -0,0 +1,42 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_box' +# +module Efl + # + module Elm + # + class ElmBox < ElmObject + # + include Helper + constructor :elm_box_add + search_prefixes 'elm_box_' + # + def padding_get + x = FFI::MemoryPointer.new :int + y = FFI::MemoryPointer.new :int + Native::elm_box_padding_get @ptr, x, y + [ x.read_int, y.read_int ] + end + alias :padding :padding_get + # + def align_get + x = FFI::MemoryPointer.new :float + y = FFI::MemoryPointer.new :float + Native::elm_box_align_get @ptr, x, y + [ x.read_float, y.read_float ] + end + alias :align :padding_get + # + def children_get + Efl::EinaList::REinaList.new Native.elm_box_children_get @ptr + end + alias :children :children_get + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_box.rb b/lib/efl/native/elm/elm_box.rb new file mode 100644 index 0000000..4b776cd --- /dev/null +++ b/lib/efl/native/elm/elm_box.rb @@ -0,0 +1,81 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmBox + # + FCT_PREFIX = 'elm_box_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # TYPEDEFS + # typedef struct _Elm_Box_Transition Elm_Box_Transition; + typedef :pointer, :elm_box_transition + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_box_add(Evas_Object *parent); + [ :elm_box_add, [ :evas_object ], :evas_object ], + # EAPI void elm_box_horizontal_set(Evas_Object *obj, Eina_Bool horizontal); + [ :elm_box_horizontal_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_box_horizontal_get(const Evas_Object *obj); + [ :elm_box_horizontal_get, [ :evas_object ], :bool ], + # EAPI void elm_box_homogeneous_set(Evas_Object *obj, Eina_Bool homogeneous); + [ :elm_box_homogeneous_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_box_homogeneous_get(const Evas_Object *obj); + [ :elm_box_homogeneous_get, [ :evas_object ], :bool ], + # EAPI void elm_box_pack_start(Evas_Object *obj, Evas_Object *subobj); + [ :elm_box_pack_start, [ :evas_object, :evas_object ], :void ], + # EAPI void elm_box_pack_end(Evas_Object *obj, Evas_Object *subobj); + [ :elm_box_pack_end, [ :evas_object, :evas_object ], :void ], + # EAPI void elm_box_pack_before(Evas_Object *obj, Evas_Object *subobj, Evas_Object *before); + [ :elm_box_pack_before, [ :evas_object, :evas_object, :evas_object ], :void ], + # EAPI void elm_box_pack_after(Evas_Object *obj, Evas_Object *subobj, Evas_Object *after); + [ :elm_box_pack_after, [ :evas_object, :evas_object, :evas_object ], :void ], + # EAPI void elm_box_clear(Evas_Object *obj); + [ :elm_box_clear, [ :evas_object ], :void ], + # EAPI void elm_box_unpack(Evas_Object *obj, Evas_Object *subobj); + [ :elm_box_unpack, [ :evas_object, :evas_object ], :void ], + # EAPI void elm_box_unpack_all(Evas_Object *obj); + [ :elm_box_unpack_all, [ :evas_object ], :void ], + # EAPI Eina_List *elm_box_children_get(const Evas_Object *obj); + [ :elm_box_children_get, [ :evas_object ], :eina_list ], + # EAPI void elm_box_padding_set(Evas_Object *obj, Evas_Coord horizontal, Evas_Coord vertical); + [ :elm_box_padding_set, [ :evas_object, :int, :int ], :void ], + # EAPI void elm_box_padding_get(const Evas_Object *obj, Evas_Coord *horizontal, Evas_Coord *vertical); + [ :elm_box_padding_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_box_align_set(Evas_Object *obj, double horizontal, double vertical); + [ :elm_box_align_set, [ :evas_object, :double, :double ], :void ], + # EAPI void elm_box_align_get(const Evas_Object *obj, double *horizontal, double *vertical); + [ :elm_box_align_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_box_recalculate(Evas_Object *obj); + [ :elm_box_recalculate, [ :evas_object ], :void ], + # EAPI void elm_box_layout_set(Evas_Object *obj, Evas_Object_Box_Layout cb, const void *data, void (*free_data)(void *data)); + # FIXME + # EAPI void elm_box_layout_transition(Evas_Object *obj, Evas_Object_Box_Data *priv, void *data); + [ :elm_box_layout_transition, [ :evas_object, :evas_object_box_data, :pointer ], :void ], + # EAPI Elm_Box_Transition *elm_box_transition_new(const double duration, Evas_Object_Box_Layout start_layout, void *start_layout_data, void (*start_layout_free_data)(void *data), Evas_Object_Box_Layout end_layout, void *end_layout_data, void (*end_layout_free_data)(void *data), void (*transition_end_cb)(void *data), void *transition_end_data); + # FIXME + # EAPI void elm_box_transition_free(void *data); + [ :elm_box_transition_free, [ :pointer ], :void ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index de52d7d..adf3a67 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -54,6 +54,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_bg.h" \ "${INCLUDE}/elementary-0/elm_label.h" \ "${INCLUDE}/elementary-0/elm_object.h" \ + "${INCLUDE}/elementary-0/elm_box.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index b044f62..a706e5e 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -390,6 +390,11 @@ libs << { :modname=>'ElmObject', :prefix=>'elm_object', :outfile=>'elm/elm_object.rb', :requires=>["#{NATIVE}/edje","#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_box.h', + :modname=>'ElmBox', :prefix=>'elm_box', :outfile=>'elm/elm_box.rb', + :requires=>["#{NATIVE}/edje","#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 31656c652ea2dd77ed0aa2180635a2b41a543c01 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 14:53:14 +0100 Subject: parse elm_button.h, generate elm_button.rb --- lib/efl/elm/elm_button.rb | 22 +++++++++++++++++++ lib/efl/native/elm/elm_button.rb | 47 ++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 7 +++++- 4 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 lib/efl/elm/elm_button.rb create mode 100644 lib/efl/native/elm/elm_button.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_button.rb b/lib/efl/elm/elm_button.rb new file mode 100644 index 0000000..dbf9c86 --- /dev/null +++ b/lib/efl/elm/elm_button.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_button' +# +module Efl + # + module Elm + # + class ElmButton < ElmObject + # + include Helper + constructor :elm_button_add + search_prefixes 'elm_button_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_button.rb b/lib/efl/native/elm/elm_button.rb new file mode 100644 index 0000000..c850123 --- /dev/null +++ b/lib/efl/native/elm/elm_button.rb @@ -0,0 +1,47 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmButton + # + FCT_PREFIX = 'elm_button_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_button_add(Evas_Object *parent); + [ :elm_button_add, [ :evas_object ], :evas_object ], + # EAPI void elm_button_autorepeat_set(Evas_Object *obj, Eina_Bool on); + [ :elm_button_autorepeat_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_button_autorepeat_get(const Evas_Object *obj); + [ :elm_button_autorepeat_get, [ :evas_object ], :bool ], + # EAPI void elm_button_autorepeat_initial_timeout_set(Evas_Object *obj, double t); + [ :elm_button_autorepeat_initial_timeout_set, [ :evas_object, :double ], :void ], + # EAPI double elm_button_autorepeat_initial_timeout_get(const Evas_Object *obj); + [ :elm_button_autorepeat_initial_timeout_get, [ :evas_object ], :double ], + # EAPI void elm_button_autorepeat_gap_timeout_set(Evas_Object *obj, double t); + [ :elm_button_autorepeat_gap_timeout_set, [ :evas_object, :double ], :void ], + # EAPI double elm_button_autorepeat_gap_timeout_get(const Evas_Object *obj); + [ :elm_button_autorepeat_gap_timeout_get, [ :evas_object ], :double ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index adf3a67..75b4076 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -55,6 +55,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_label.h" \ "${INCLUDE}/elementary-0/elm_object.h" \ "${INCLUDE}/elementary-0/elm_box.h" \ + "${INCLUDE}/elementary-0/elm_button.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index a706e5e..0874c59 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -393,7 +393,12 @@ libs << { libs << { :lib=>ELM_LIB,:header=>'elm_box.h', :modname=>'ElmBox', :prefix=>'elm_box', :outfile=>'elm/elm_box.rb', - :requires=>["#{NATIVE}/edje","#{NATIVE}/elementary"], :constants=>[] + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} +libs << { + :lib=>ELM_LIB,:header=>'elm_button.h', + :modname=>'ElmButton', :prefix=>'elm_button', :outfile=>'elm/elm_button.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] } Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 85de83d793de3e09cdce18cb6034047db400788a Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:00:28 +0100 Subject: parse elm_frame.h, generate elm_frame.rb --- lib/efl/elm/elm_frame.rb | 22 ++++++++++++++++++++ lib/efl/native/elm/elm_frame.rb | 45 +++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++++ 4 files changed, 73 insertions(+) create mode 100644 lib/efl/elm/elm_frame.rb create mode 100644 lib/efl/native/elm/elm_frame.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_frame.rb b/lib/efl/elm/elm_frame.rb new file mode 100644 index 0000000..f1eb7a7 --- /dev/null +++ b/lib/efl/elm/elm_frame.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_frame' +# +module Efl + # + module Elm + # + class ElmFrame < ElmObject + # + include Helper + constructor :elm_frame_add + search_prefixes 'elm_frame_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_frame.rb b/lib/efl/native/elm/elm_frame.rb new file mode 100644 index 0000000..e941b82 --- /dev/null +++ b/lib/efl/native/elm/elm_frame.rb @@ -0,0 +1,45 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmFrame + # + FCT_PREFIX = 'elm_frame_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_frame_add(Evas_Object *parent); + [ :elm_frame_add, [ :evas_object ], :evas_object ], + # EAPI void elm_frame_autocollapse_set(Evas_Object *obj, Eina_Bool autocollapse); + [ :elm_frame_autocollapse_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_frame_autocollapse_get(const Evas_Object *obj); + [ :elm_frame_autocollapse_get, [ :evas_object ], :bool ], + # EAPI void elm_frame_collapse_set(Evas_Object *obj, Eina_Bool collapse); + [ :elm_frame_collapse_set, [ :evas_object, :bool ], :void ], + # EAPI void elm_frame_collapse_go(Evas_Object *obj, Eina_Bool collapse); + [ :elm_frame_collapse_go, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_frame_collapse_get(const Evas_Object *obj); + [ :elm_frame_collapse_get, [ :evas_object ], :bool ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 75b4076..39097a6 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -56,6 +56,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_object.h" \ "${INCLUDE}/elementary-0/elm_box.h" \ "${INCLUDE}/elementary-0/elm_button.h" \ + "${INCLUDE}/elementary-0/elm_frame.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 0874c59..f4d523d 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -400,6 +400,11 @@ libs << { :modname=>'ElmButton', :prefix=>'elm_button', :outfile=>'elm/elm_button.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_frame.h', + :modname=>'ElmFrame', :prefix=>'elm_frame', :outfile=>'elm/elm_frame.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 41f77c375f4bfcc6395425aa86158bdad93108ad Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:03:43 +0100 Subject: parse elm_panel.h, generate elm_panel.rb --- lib/efl/elm/elm_panel.rb | 22 +++++++++++++++++ lib/efl/native/elm/elm_panel.rb | 55 +++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 6 +++++ 4 files changed, 84 insertions(+) create mode 100644 lib/efl/elm/elm_panel.rb create mode 100644 lib/efl/native/elm/elm_panel.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_panel.rb b/lib/efl/elm/elm_panel.rb new file mode 100644 index 0000000..41dbcc5 --- /dev/null +++ b/lib/efl/elm/elm_panel.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_panel' +# +module Efl + # + module Elm + # + class ElmPanel < ElmObject + # + include Helper + constructor :elm_panel_add + search_prefixes 'elm_panel_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_panel.rb b/lib/efl/native/elm/elm_panel.rb new file mode 100644 index 0000000..4fe40a4 --- /dev/null +++ b/lib/efl/native/elm/elm_panel.rb @@ -0,0 +1,55 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmPanel + # + FCT_PREFIX = 'elm_panel_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Panel_Orient; + enum :elm_panel_orient, [ :elm_panel_orient_top, :elm_panel_orient_bottom, :elm_panel_orient_left, :elm_panel_orient_right ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_panel_add(Evas_Object *parent); + [ :elm_panel_add, [ :evas_object ], :evas_object ], + # EAPI void elm_panel_orient_set(Evas_Object *obj, Elm_Panel_Orient orient); + [ :elm_panel_orient_set, [ :evas_object, :elm_panel_orient ], :void ], + # EAPI Elm_Panel_Orient elm_panel_orient_get(const Evas_Object *obj); + [ :elm_panel_orient_get, [ :evas_object ], :elm_panel_orient ], + # EAPI void elm_panel_hidden_set(Evas_Object *obj, Eina_Bool hidden); + [ :elm_panel_hidden_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_panel_hidden_get(const Evas_Object *obj); + [ :elm_panel_hidden_get, [ :evas_object ], :bool ], + # EAPI void elm_panel_toggle(Evas_Object *obj); + [ :elm_panel_toggle, [ :evas_object ], :void ], + # EAPI void elm_panel_content_set(Evas_Object *obj, Evas_Object *content); + [ :elm_panel_content_set, [ :evas_object, :evas_object ], :void ], + # EAPI Evas_Object * elm_panel_content_get(const Evas_Object *obj); + [ :elm_panel_content_get, [ :evas_object ], :evas_object ], + # EAPI Evas_Object * elm_panel_content_unset(Evas_Object *obj); + [ :elm_panel_content_unset, [ :evas_object ], :evas_object ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 39097a6..ce754e3 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -57,6 +57,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_box.h" \ "${INCLUDE}/elementary-0/elm_button.h" \ "${INCLUDE}/elementary-0/elm_frame.h" \ + "${INCLUDE}/elementary-0/elm_panel.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index f4d523d..1be9b57 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -405,6 +405,12 @@ libs << { :modname=>'ElmFrame', :prefix=>'elm_frame', :outfile=>'elm/elm_frame.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_panel.h', + :modname=>'ElmPanel', :prefix=>'elm_panel', :outfile=>'elm/elm_panel.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} +# Dir.mkdir lib_path unless (File.exists? lib_path) # libs.each do |lib| -- cgit v1.2.3 From 8af4c2366a9685c06f3114203cb21da42de6b53f Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:09:12 +0100 Subject: parse elm_image.h, generate elm_image.rb --- lib/efl/elm/elm_image.rb | 22 ++++++++++++ lib/efl/native/elm/elm_image.rb | 80 +++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 4 files changed, 108 insertions(+) create mode 100644 lib/efl/elm/elm_image.rb create mode 100644 lib/efl/native/elm/elm_image.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_image.rb b/lib/efl/elm/elm_image.rb new file mode 100644 index 0000000..6a37ee9 --- /dev/null +++ b/lib/efl/elm/elm_image.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_image' +# +module Efl + # + module Elm + # + class ElmImage < ElmObject + # + include Helper + constructor :elm_image_add + search_prefixes 'elm_image_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_image.rb b/lib/efl/native/elm/elm_image.rb new file mode 100644 index 0000000..356c5dd --- /dev/null +++ b/lib/efl/native/elm/elm_image.rb @@ -0,0 +1,80 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmImage + # + FCT_PREFIX = 'elm_image_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Image_Orient; + enum :elm_image_orient, [ :elm_image_orient_none, 0, :elm_image_orient_0, 0, :elm_image_rotate_90, 1, :elm_image_rotate_180, 2, + :elm_image_rotate_270, 3, :elm_image_flip_horizontal, 4, :elm_image_flip_vertical, 5, :elm_image_flip_transpose, 6, :elm_image_flip_transverse, 7 ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_image_add(Evas_Object *parent); + [ :elm_image_add, [ :evas_object ], :evas_object ], + # EAPI Eina_Bool elm_image_file_set(Evas_Object *obj, const char *file, const char *group); + [ :elm_image_file_set, [ :evas_object, :string, :string ], :bool ], + # EAPI void elm_image_file_get(const Evas_Object *obj, const char **file, const char **group); + [ :elm_image_file_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_image_smooth_set(Evas_Object *obj, Eina_Bool smooth); + [ :elm_image_smooth_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_image_smooth_get(const Evas_Object *obj); + [ :elm_image_smooth_get, [ :evas_object ], :bool ], + # EAPI void elm_image_object_size_get(const Evas_Object *obj, int *w, int *h); + [ :elm_image_object_size_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_image_no_scale_set(Evas_Object *obj, Eina_Bool no_scale); + [ :elm_image_no_scale_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_image_no_scale_get(const Evas_Object *obj); + [ :elm_image_no_scale_get, [ :evas_object ], :bool ], + # EAPI void elm_image_scale_set(Evas_Object *obj, Eina_Bool scale_up, Eina_Bool scale_down); + [ :elm_image_scale_set, [ :evas_object, :bool, :bool ], :void ], + # EAPI void elm_image_scale_get(const Evas_Object *obj, Eina_Bool *scale_up, Eina_Bool *scale_down); + [ :elm_image_scale_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_image_fill_outside_set(Evas_Object *obj, Eina_Bool fill_outside); + [ :elm_image_fill_outside_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_image_fill_outside_get(const Evas_Object *obj); + [ :elm_image_fill_outside_get, [ :evas_object ], :bool ], + # EAPI void elm_image_prescale_set(Evas_Object *obj, int size); + [ :elm_image_prescale_set, [ :evas_object, :int ], :void ], + # EAPI int elm_image_prescale_get(const Evas_Object *obj); + [ :elm_image_prescale_get, [ :evas_object ], :int ], + # EAPI void elm_image_orient_set(Evas_Object *obj, Elm_Image_Orient orient); + [ :elm_image_orient_set, [ :evas_object, :elm_image_orient ], :void ], + # EAPI Elm_Image_Orient elm_image_orient_get(const Evas_Object *obj); + [ :elm_image_orient_get, [ :evas_object ], :elm_image_orient ], + # EAPI void elm_image_editable_set(Evas_Object *obj, Eina_Bool set); + [ :elm_image_editable_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_image_editable_get(const Evas_Object *obj); + [ :elm_image_editable_get, [ :evas_object ], :bool ], + # EAPI Evas_Object *elm_image_object_get(const Evas_Object *obj); + [ :elm_image_object_get, [ :evas_object ], :evas_object ], + # EAPI void elm_image_aspect_fixed_set(Evas_Object *obj, Eina_Bool fixed); + [ :elm_image_aspect_fixed_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_image_aspect_fixed_get(const Evas_Object *obj); + [ :elm_image_aspect_fixed_get, [ :evas_object ], :bool ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index ce754e3..4c50504 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -58,6 +58,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_button.h" \ "${INCLUDE}/elementary-0/elm_frame.h" \ "${INCLUDE}/elementary-0/elm_panel.h" \ + "${INCLUDE}/elementary-0/elm_image.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 1be9b57..e963dfa 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -410,6 +410,11 @@ libs << { :modname=>'ElmPanel', :prefix=>'elm_panel', :outfile=>'elm/elm_panel.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_image.h', + :modname=>'ElmImage', :prefix=>'elm_image', :outfile=>'elm/elm_image.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 979cdad00dc4617cf1614f4d4bbdc07a1e7bc1d1 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:13:17 +0100 Subject: parse elm_grid.h, generate elm_grid.rb --- lib/efl/elm/elm_grid.rb | 22 ++++++++++++++++++ lib/efl/native/elm/elm_grid.rb | 51 ++++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++++ 4 files changed, 79 insertions(+) create mode 100644 lib/efl/elm/elm_grid.rb create mode 100644 lib/efl/native/elm/elm_grid.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_grid.rb b/lib/efl/elm/elm_grid.rb new file mode 100644 index 0000000..9b00a35 --- /dev/null +++ b/lib/efl/elm/elm_grid.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_grid' +# +module Efl + # + module Elm + # + class ElmGrid < ElmObject + # + include Helper + constructor :elm_grid_add + search_prefixes 'elm_grid_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_grid.rb b/lib/efl/native/elm/elm_grid.rb new file mode 100644 index 0000000..0b02565 --- /dev/null +++ b/lib/efl/native/elm/elm_grid.rb @@ -0,0 +1,51 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmGrid + # + FCT_PREFIX = 'elm_grid_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_grid_add(Evas_Object *parent); + [ :elm_grid_add, [ :evas_object ], :evas_object ], + # EAPI void elm_grid_size_set(Evas_Object *obj, Evas_Coord w, Evas_Coord h); + [ :elm_grid_size_set, [ :evas_object, :int, :int ], :void ], + # EAPI void elm_grid_size_get(const Evas_Object *obj, Evas_Coord *w, Evas_Coord *h); + [ :elm_grid_size_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_grid_pack(Evas_Object *obj, Evas_Object *subobj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h); + [ :elm_grid_pack, [ :evas_object, :evas_object, :int, :int, :int, :int ], :void ], + # EAPI void elm_grid_unpack(Evas_Object *obj, Evas_Object *subobj); + [ :elm_grid_unpack, [ :evas_object, :evas_object ], :void ], + # EAPI void elm_grid_clear(Evas_Object *obj, Eina_Bool clear); + [ :elm_grid_clear, [ :evas_object, :bool ], :void ], + # EAPI void elm_grid_pack_set(Evas_Object *subobj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h); + [ :elm_grid_pack_set, [ :evas_object, :int, :int, :int, :int ], :void ], + # EAPI void elm_grid_pack_get(Evas_Object *subobj, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h); + [ :elm_grid_pack_get, [ :evas_object, :pointer, :pointer, :pointer, :pointer ], :void ], + # EAPI Eina_List *elm_grid_children_get(const Evas_Object *obj); + [ :elm_grid_children_get, [ :evas_object ], :eina_list ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 4c50504..e830d2a 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -59,6 +59,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_frame.h" \ "${INCLUDE}/elementary-0/elm_panel.h" \ "${INCLUDE}/elementary-0/elm_image.h" \ + "${INCLUDE}/elementary-0/elm_grid.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index e963dfa..2d80a8d 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -415,6 +415,11 @@ libs << { :modname=>'ElmImage', :prefix=>'elm_image', :outfile=>'elm/elm_image.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_grid.h', + :modname=>'ElmGrid', :prefix=>'elm_grid', :outfile=>'elm/elm_grid.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 7d085da91d5c2c7da74f9eaca50cca9faa4e33ef Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:25:27 +0100 Subject: parse elm_menu.h, generate elm_menu.rb --- lib/efl/elm/elm_menu.rb | 55 ++++++++++++++++++++++++++++++ lib/efl/native/elm/elm_menu.rb | 77 ++++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 4 files changed, 138 insertions(+) create mode 100644 lib/efl/elm/elm_menu.rb create mode 100644 lib/efl/native/elm/elm_menu.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_menu.rb b/lib/efl/elm/elm_menu.rb new file mode 100644 index 0000000..f285011 --- /dev/null +++ b/lib/efl/elm/elm_menu.rb @@ -0,0 +1,55 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/elm/elm_object_item' +require 'efl/native/elm/elm_menu' +# +module Efl + # + module Elm + # + class ElmMenu < ElmObject + # + include Helper + constructor :elm_menu_add + search_prefixes 'elm_menu_' + # + def item_add parent, icon=nil, label=nil, cb=nil, data=nil + ElmObjectItem.new Native::elm_menu_item_add @ptr, parent, icon, label, cb, data + end + # + def item_add_object parent, subobj, cb=nil, data=nil + ElmObjectItem.new Native::elm_menu_item_add_object @ptr, parent, subobj, cb, data + end + # + def item_separator_add parent + ElmObjectItem.new Native::elm_menu_item_separator_add @ptr, parent + end + # + def selected_item_get + ElmObjectItem.new Native::elm_menu_selected_item_get @ptr + end + # + def last_item_get + ElmObjectItem.new Native::elm_menu_last_item_get @ptr + end + # + def first_item_get + ElmObjectItem.new Native::elm_menu_first_item_get @ptr + end + # + def item_next_get it + ElmObjectItem.new Native::elm_menu_item_next_get it + end + # + def item_prev_get it + ElmObjectItem.new Native::elm_menu_item_prev_get it + end + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_menu.rb b/lib/efl/native/elm/elm_menu.rb new file mode 100644 index 0000000..bb981a6 --- /dev/null +++ b/lib/efl/native/elm/elm_menu.rb @@ -0,0 +1,77 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmMenu + # + FCT_PREFIX = 'elm_menu_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_menu_add(Evas_Object *parent); + [ :elm_menu_add, [ :evas_object ], :evas_object ], + # EAPI void elm_menu_parent_set(Evas_Object *obj, Evas_Object *parent); + [ :elm_menu_parent_set, [ :evas_object, :evas_object ], :void ], + # EAPI Evas_Object *elm_menu_parent_get(const Evas_Object *obj); + [ :elm_menu_parent_get, [ :evas_object ], :evas_object ], + # EAPI void elm_menu_move(Evas_Object *obj, Evas_Coord x, Evas_Coord y); + [ :elm_menu_move, [ :evas_object, :int, :int ], :void ], + # EAPI void elm_menu_close(Evas_Object *obj); + [ :elm_menu_close, [ :evas_object ], :void ], + # EAPI const Eina_List *elm_menu_items_get(const Evas_Object *obj); + [ :elm_menu_items_get, [ :evas_object ], :eina_list ], + # EAPI Evas_Object *elm_menu_item_object_get(const Elm_Object_Item *it); + [ :elm_menu_item_object_get, [ :elm_object_item ], :evas_object ], + # EAPI Elm_Object_Item *elm_menu_item_add(Evas_Object *obj, Elm_Object_Item *parent, const char *icon, const char *label, Evas_Smart_Cb func, const void *data); + [ :elm_menu_item_add, [ :evas_object, :elm_object_item, :string, :string, :evas_smart_cb, :pointer ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_menu_item_add_object(Evas_Object *obj, Elm_Object_Item *parent, Evas_Object *subobj, Evas_Smart_Cb func, const void *data); + [ :elm_menu_item_add_object, [ :evas_object, :elm_object_item, :evas_object, :evas_smart_cb, :pointer ], :elm_object_item ], + # EAPI void elm_menu_item_object_icon_name_set(Elm_Object_Item *it, const char *icon); + [ :elm_menu_item_object_icon_name_set, [ :elm_object_item, :string ], :void ], + # EAPI const char *elm_menu_item_object_icon_name_get(const Elm_Object_Item *it); + [ :elm_menu_item_object_icon_name_get, [ :elm_object_item ], :string ], + # EAPI void elm_menu_item_selected_set(Elm_Object_Item *it, Eina_Bool selected); + [ :elm_menu_item_selected_set, [ :elm_object_item, :bool ], :void ], + # EAPI Eina_Bool elm_menu_item_selected_get(const Elm_Object_Item *it); + [ :elm_menu_item_selected_get, [ :elm_object_item ], :bool ], + # EAPI Elm_Object_Item *elm_menu_item_separator_add(Evas_Object *obj, Elm_Object_Item *parent); + [ :elm_menu_item_separator_add, [ :evas_object, :elm_object_item ], :elm_object_item ], + # EAPI Eina_Bool elm_menu_item_is_separator(Elm_Object_Item *it); + [ :elm_menu_item_is_separator, [ :elm_object_item ], :bool ], + # EAPI const Eina_List *elm_menu_item_subitems_get(const Elm_Object_Item *it); + [ :elm_menu_item_subitems_get, [ :elm_object_item ], :eina_list ], + # EAPI unsigned int elm_menu_item_index_get(const Elm_Object_Item *it); + [ :elm_menu_item_index_get, [ :elm_object_item ], :uint ], + # EAPI Elm_Object_Item *elm_menu_selected_item_get(const Evas_Object *obj); + [ :elm_menu_selected_item_get, [ :evas_object ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_menu_last_item_get(const Evas_Object *obj); + [ :elm_menu_last_item_get, [ :evas_object ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_menu_first_item_get(const Evas_Object *obj); + [ :elm_menu_first_item_get, [ :evas_object ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_menu_item_next_get(const Elm_Object_Item *it); + [ :elm_menu_item_next_get, [ :elm_object_item ], :elm_object_item ], + # EAPI Elm_Object_Item *elm_menu_item_prev_get(const Elm_Object_Item *it); + [ :elm_menu_item_prev_get, [ :elm_object_item ], :elm_object_item ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index e830d2a..501fc6e 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -60,6 +60,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_panel.h" \ "${INCLUDE}/elementary-0/elm_image.h" \ "${INCLUDE}/elementary-0/elm_grid.h" \ + "${INCLUDE}/elementary-0/elm_menu.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 2d80a8d..a58c294 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -420,6 +420,11 @@ libs << { :modname=>'ElmGrid', :prefix=>'elm_grid', :outfile=>'elm/elm_grid.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_menu.h', + :modname=>'ElmMenu', :prefix=>'elm_menu', :outfile=>'elm/elm_menu.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From da1ba75528a8366db7a3d09a8c67070dd0b47b90 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:27:30 +0100 Subject: parse elm_check.h, generate elm_check.rb --- lib/efl/elm/elm_check.rb | 22 ++++++++++++++++++++++ lib/efl/native/elm/elm_check.rb | 41 +++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++++ 4 files changed, 69 insertions(+) create mode 100644 lib/efl/elm/elm_check.rb create mode 100644 lib/efl/native/elm/elm_check.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_check.rb b/lib/efl/elm/elm_check.rb new file mode 100644 index 0000000..141890a --- /dev/null +++ b/lib/efl/elm/elm_check.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_check' +# +module Efl + # + module Elm + # + class ElmCheck < ElmObject + # + include Helper + constructor :elm_check_add + search_prefixes 'elm_check_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_check.rb b/lib/efl/native/elm/elm_check.rb new file mode 100644 index 0000000..9165d30 --- /dev/null +++ b/lib/efl/native/elm/elm_check.rb @@ -0,0 +1,41 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmCheck + # + FCT_PREFIX = 'elm_check_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object * elm_check_add(Evas_Object *parent); + [ :elm_check_add, [ :evas_object ], :evas_object ], + # EAPI void elm_check_state_set(Evas_Object *obj, Eina_Bool state); + [ :elm_check_state_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_check_state_get(const Evas_Object *obj); + [ :elm_check_state_get, [ :evas_object ], :bool ], + # EAPI void elm_check_state_pointer_set(Evas_Object *obj, Eina_Bool *statep); + [ :elm_check_state_pointer_set, [ :evas_object, :pointer ], :void ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 501fc6e..4168dcc 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -61,6 +61,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_image.h" \ "${INCLUDE}/elementary-0/elm_grid.h" \ "${INCLUDE}/elementary-0/elm_menu.h" \ + "${INCLUDE}/elementary-0/elm_check.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index a58c294..cbd4fc2 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -425,6 +425,11 @@ libs << { :modname=>'ElmMenu', :prefix=>'elm_menu', :outfile=>'elm/elm_menu.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_check.h', + :modname=>'ElmCheck', :prefix=>'elm_check', :outfile=>'elm/elm_check.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 2d73b282cb57c14a2dc9b8d4a052643c48bae892 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:31:46 +0100 Subject: parse elm_clock.h, generate elm_clock.rb --- lib/efl/elm/elm_clock.rb | 22 ++++++++++++++ lib/efl/native/elm/elm_clock.rb | 64 +++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 ++++ 4 files changed, 92 insertions(+) create mode 100644 lib/efl/elm/elm_clock.rb create mode 100644 lib/efl/native/elm/elm_clock.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_clock.rb b/lib/efl/elm/elm_clock.rb new file mode 100644 index 0000000..4ebd02a --- /dev/null +++ b/lib/efl/elm/elm_clock.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_clock' +# +module Efl + # + module Elm + # + class ElmClock < ElmObject + # + include Helper + constructor :elm_clock_add + search_prefixes 'elm_clock_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_clock.rb b/lib/efl/native/elm/elm_clock.rb new file mode 100644 index 0000000..bd6cff7 --- /dev/null +++ b/lib/efl/native/elm/elm_clock.rb @@ -0,0 +1,64 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmClock + # + FCT_PREFIX = 'elm_clock_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Clock_Digedit; + enum :elm_clock_digedit, [ :elm_clock_none, 0, :elm_clock_hour_decimal, 1<<0, :elm_clock_hour_unit, 1<<1, :elm_clock_min_decimal, 1<<2, + :elm_clock_min_unit, 1<<3, :elm_clock_sec_decimal, 1<<4, :elm_clock_sec_unit, 1<<5, :elm_clock_all, (1<<6)-1 ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_clock_add(Evas_Object *parent); + [ :elm_clock_add, [ :evas_object ], :evas_object ], + # EAPI void elm_clock_time_set(Evas_Object *obj, int hrs, int min, int sec); + [ :elm_clock_time_set, [ :evas_object, :int, :int, :int ], :void ], + # EAPI void elm_clock_time_get(const Evas_Object *obj, int *hrs, int *min, int *sec); + [ :elm_clock_time_get, [ :evas_object, :pointer, :pointer, :pointer ], :void ], + # EAPI void elm_clock_edit_set(Evas_Object *obj, Eina_Bool edit); + [ :elm_clock_edit_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_clock_edit_get(const Evas_Object *obj); + [ :elm_clock_edit_get, [ :evas_object ], :bool ], + # EAPI void elm_clock_digit_edit_set(Evas_Object *obj, Elm_Clock_Digedit digedit); + [ :elm_clock_digit_edit_set, [ :evas_object, :elm_clock_digedit ], :void ], + # EAPI Elm_Clock_Digedit elm_clock_digit_edit_get(const Evas_Object *obj); + [ :elm_clock_digit_edit_get, [ :evas_object ], :elm_clock_digedit ], + # EAPI void elm_clock_show_am_pm_set(Evas_Object *obj, Eina_Bool am_pm); + [ :elm_clock_show_am_pm_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_clock_show_am_pm_get(const Evas_Object *obj); + [ :elm_clock_show_am_pm_get, [ :evas_object ], :bool ], + # EAPI void elm_clock_show_seconds_set(Evas_Object *obj, Eina_Bool seconds); + [ :elm_clock_show_seconds_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_clock_show_seconds_get(const Evas_Object *obj); + [ :elm_clock_show_seconds_get, [ :evas_object ], :bool ], + # EAPI void elm_clock_interval_set(Evas_Object *obj, double interval); + [ :elm_clock_interval_set, [ :evas_object, :double ], :void ], + # EAPI double elm_clock_interval_get(const Evas_Object *obj); + [ :elm_clock_interval_get, [ :evas_object ], :double ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 4168dcc..f79a192 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -62,6 +62,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_grid.h" \ "${INCLUDE}/elementary-0/elm_menu.h" \ "${INCLUDE}/elementary-0/elm_check.h" \ + "${INCLUDE}/elementary-0/elm_clock.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index cbd4fc2..a9c10ae 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -430,6 +430,11 @@ libs << { :modname=>'ElmCheck', :prefix=>'elm_check', :outfile=>'elm/elm_check.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_clock.h', + :modname=>'ElmClock', :prefix=>'elm_clock', :outfile=>'elm/elm_clock.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 8dc91c77cfcb1e6adc7cbabef1fa578df00a3617 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:36:00 +0100 Subject: parse elm_calendar.h, generate elm_calendar.rb --- lib/efl/elm/elm_calendar.rb | 22 +++++++++++ lib/efl/native/elm/elm_calendar.rb | 76 ++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 4 files changed, 104 insertions(+) create mode 100644 lib/efl/elm/elm_calendar.rb create mode 100644 lib/efl/native/elm/elm_calendar.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_calendar.rb b/lib/efl/elm/elm_calendar.rb new file mode 100644 index 0000000..e8cf708 --- /dev/null +++ b/lib/efl/elm/elm_calendar.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_calendar' +# +module Efl + # + module Elm + # + class ElmCalendar < ElmObject + # + include Helper + constructor :elm_calendar_add + search_prefixes 'elm_calendar_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_calendar.rb b/lib/efl/native/elm/elm_calendar.rb new file mode 100644 index 0000000..9677040 --- /dev/null +++ b/lib/efl/native/elm/elm_calendar.rb @@ -0,0 +1,76 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmCalendar + # + FCT_PREFIX = 'elm_calendar_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Calendar_Mark_Repeat; + enum :elm_calendar_mark_repeat, [ :elm_calendar_unique, :elm_calendar_daily, :elm_calendar_weekly, :elm_calendar_monthly, + :elm_calendar_annually ] + # + # TYPEDEFS + # typedef struct _Elm_Calendar_Mark Elm_Calendar_Mark; + typedef :pointer, :elm_calendar_mark + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_calendar_add(Evas_Object *parent); + [ :elm_calendar_add, [ :evas_object ], :evas_object ], + # EAPI const char **elm_calendar_weekdays_names_get(const Evas_Object *obj); + [ :elm_calendar_weekdays_names_get, [ :evas_object ], :pointer ], + # EAPI void elm_calendar_weekdays_names_set(Evas_Object *obj, const char *weekdays[]); + # FIXME + # EAPI void elm_calendar_min_max_year_set(Evas_Object *obj, int min, int max); + [ :elm_calendar_min_max_year_set, [ :evas_object, :int, :int ], :void ], + # EAPI void elm_calendar_min_max_year_get(const Evas_Object *obj, int *min, int *max); + [ :elm_calendar_min_max_year_get, [ :evas_object, :pointer, :pointer ], :void ], + # EAPI void elm_calendar_day_selection_enabled_set(Evas_Object *obj, Eina_Bool enabled); + [ :elm_calendar_day_selection_enabled_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_calendar_day_selection_enabled_get(const Evas_Object *obj); + [ :elm_calendar_day_selection_enabled_get, [ :evas_object ], :bool ], + # EAPI void elm_calendar_selected_time_set(Evas_Object *obj, struct tm *selected_time); + [ :elm_calendar_selected_time_set, [ :evas_object, :pointer ], :void ], + # EAPI Eina_Bool elm_calendar_selected_time_get(const Evas_Object *obj, struct tm *selected_time); + [ :elm_calendar_selected_time_get, [ :evas_object, :pointer ], :bool ], + # EAPI void elm_calendar_format_function_set(Evas_Object *obj, char *(*format_function)(struct tm *stime)); + # FIXME + # EAPI Elm_Calendar_Mark *elm_calendar_mark_add(Evas_Object *obj, const char *mark_type, struct tm *mark_time, Elm_Calendar_Mark_Repeat repeat); + [ :elm_calendar_mark_add, [ :evas_object, :string, :pointer, :elm_calendar_mark_repeat ], :elm_calendar_mark ], + # EAPI void elm_calendar_mark_del(Elm_Calendar_Mark *mark); + [ :elm_calendar_mark_del, [ :elm_calendar_mark ], :void ], + # EAPI void elm_calendar_marks_clear(Evas_Object *obj); + [ :elm_calendar_marks_clear, [ :evas_object ], :void ], + # EAPI const Eina_List *elm_calendar_marks_get(const Evas_Object *obj); + [ :elm_calendar_marks_get, [ :evas_object ], :eina_list ], + # EAPI void elm_calendar_marks_draw(Evas_Object *obj); + [ :elm_calendar_marks_draw, [ :evas_object ], :void ], + # EAPI void elm_calendar_interval_set(Evas_Object *obj, double interval); + [ :elm_calendar_interval_set, [ :evas_object, :double ], :void ], + # EAPI double elm_calendar_interval_get(const Evas_Object *obj); + [ :elm_calendar_interval_get, [ :evas_object ], :double ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index f79a192..3a3478c 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -63,6 +63,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_menu.h" \ "${INCLUDE}/elementary-0/elm_check.h" \ "${INCLUDE}/elementary-0/elm_clock.h" \ + "${INCLUDE}/elementary-0/elm_calendar.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index a9c10ae..edac863 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -435,6 +435,11 @@ libs << { :modname=>'ElmClock', :prefix=>'elm_clock', :outfile=>'elm/elm_clock.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_calendar.h', + :modname=>'ElmCalendar', :prefix=>'elm_calendar', :outfile=>'elm/elm_calendar.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 06825f703d413cec78849877fb2dba6593336175 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:36:18 +0100 Subject: parse elm_bubble.h, generate elm_bubble.rb --- lib/efl/elm/elm_bubble.rb | 22 ++++++++++++++++++++++ lib/efl/native/elm/elm_bubble.rb | 39 +++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++++ 4 files changed, 67 insertions(+) create mode 100644 lib/efl/elm/elm_bubble.rb create mode 100644 lib/efl/native/elm/elm_bubble.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_bubble.rb b/lib/efl/elm/elm_bubble.rb new file mode 100644 index 0000000..ca5bbef --- /dev/null +++ b/lib/efl/elm/elm_bubble.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_bubble' +# +module Efl + # + module Elm + # + class ElmBubble < ElmObject + # + include Helper + constructor :elm_bubble_add + search_prefixes 'elm_bubble_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_bubble.rb b/lib/efl/native/elm/elm_bubble.rb new file mode 100644 index 0000000..11b000b --- /dev/null +++ b/lib/efl/native/elm/elm_bubble.rb @@ -0,0 +1,39 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmBubble + # + FCT_PREFIX = 'elm_bubble_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_bubble_add(Evas_Object *parent); + [ :elm_bubble_add, [ :evas_object ], :evas_object ], + # EAPI void elm_bubble_corner_set(Evas_Object *obj, const char *corner); + [ :elm_bubble_corner_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_bubble_corner_get(const Evas_Object *obj); + [ :elm_bubble_corner_get, [ :evas_object ], :string ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 3a3478c..7aab889 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -64,6 +64,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_check.h" \ "${INCLUDE}/elementary-0/elm_clock.h" \ "${INCLUDE}/elementary-0/elm_calendar.h" \ + "${INCLUDE}/elementary-0/elm_bubble.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index edac863..aafe4d4 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -440,6 +440,11 @@ libs << { :modname=>'ElmCalendar', :prefix=>'elm_calendar', :outfile=>'elm/elm_calendar.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_bubble.h', + :modname=>'ElmBubble', :prefix=>'elm_bubble', :outfile=>'elm/elm_bubble.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From d91b9c4689573bf64750c57089ad3711d4389cd7 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:38:22 +0100 Subject: parse elm_layout.h, generate elm_layout.rb --- lib/efl/elm/elm_layout.rb | 22 ++++++++++++ lib/efl/native/elm/elm_layout.rb | 77 ++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 +++ 4 files changed, 105 insertions(+) create mode 100644 lib/efl/elm/elm_layout.rb create mode 100644 lib/efl/native/elm/elm_layout.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_layout.rb b/lib/efl/elm/elm_layout.rb new file mode 100644 index 0000000..a1eb99f --- /dev/null +++ b/lib/efl/elm/elm_layout.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_layout' +# +module Efl + # + module Elm + # + class ElmLayout < ElmObject + # + include Helper + constructor :elm_layout_add + search_prefixes 'elm_layout_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_layout.rb b/lib/efl/native/elm/elm_layout.rb new file mode 100644 index 0000000..c9d76b9 --- /dev/null +++ b/lib/efl/native/elm/elm_layout.rb @@ -0,0 +1,77 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmLayout + # + FCT_PREFIX = 'elm_layout_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_layout_add(Evas_Object *parent); + [ :elm_layout_add, [ :evas_object ], :evas_object ], + # EAPI Eina_Bool elm_layout_file_set(Evas_Object *obj, const char *file, const char *group); + [ :elm_layout_file_set, [ :evas_object, :string, :string ], :bool ], + # EAPI Eina_Bool elm_layout_theme_set(Evas_Object *obj, const char *clas, const char *group, const char *style); + [ :elm_layout_theme_set, [ :evas_object, :string, :string, :string ], :bool ], + # EAPI void elm_layout_box_append(Evas_Object *obj, const char *part, Evas_Object *child); + [ :elm_layout_box_append, [ :evas_object, :string, :evas_object ], :void ], + # EAPI void elm_layout_box_prepend(Evas_Object *obj, const char *part, Evas_Object *child); + [ :elm_layout_box_prepend, [ :evas_object, :string, :evas_object ], :void ], + # EAPI void elm_layout_box_insert_before(Evas_Object *obj, const char *part, Evas_Object *child, const Evas_Object *reference); + [ :elm_layout_box_insert_before, [ :evas_object, :string, :evas_object, :evas_object ], :void ], + # EAPI void elm_layout_box_insert_at(Evas_Object *obj, const char *part, Evas_Object *child, unsigned int pos); + [ :elm_layout_box_insert_at, [ :evas_object, :string, :evas_object, :uint ], :void ], + # EAPI Evas_Object *elm_layout_box_remove(Evas_Object *obj, const char *part, Evas_Object *child); + [ :elm_layout_box_remove, [ :evas_object, :string, :evas_object ], :evas_object ], + # EAPI void elm_layout_box_remove_all(Evas_Object *obj, const char *part, Eina_Bool clear); + [ :elm_layout_box_remove_all, [ :evas_object, :string, :bool ], :void ], + # EAPI void elm_layout_table_pack(Evas_Object *obj, const char *part, Evas_Object *child_obj, unsigned short col, unsigned short row, unsigned short colspan, unsigned short rowspan); + [ :elm_layout_table_pack, [ :evas_object, :string, :evas_object, :ushort, :ushort, :ushort, :ushort ], :void ], + # EAPI Evas_Object *elm_layout_table_unpack(Evas_Object *obj, const char *part, Evas_Object *child_obj); + [ :elm_layout_table_unpack, [ :evas_object, :string, :evas_object ], :evas_object ], + # EAPI void elm_layout_table_clear(Evas_Object *obj, const char *part, Eina_Bool clear); + [ :elm_layout_table_clear, [ :evas_object, :string, :bool ], :void ], + # EAPI Evas_Object *elm_layout_edje_get(const Evas_Object *obj); + [ :elm_layout_edje_get, [ :evas_object ], :evas_object ], + # EAPI const char *elm_layout_data_get(const Evas_Object *obj, const char *key); + [ :elm_layout_data_get, [ :evas_object, :string ], :string ], + # EAPI void elm_layout_sizing_eval(Evas_Object *obj); + [ :elm_layout_sizing_eval, [ :evas_object ], :void ], + # EAPI Eina_Bool elm_layout_part_cursor_set(Evas_Object *obj, const char *part_name, const char *cursor); + [ :elm_layout_part_cursor_set, [ :evas_object, :string, :string ], :bool ], + # EAPI const char *elm_layout_part_cursor_get(const Evas_Object *obj, const char *part_name); + [ :elm_layout_part_cursor_get, [ :evas_object, :string ], :string ], + # EAPI void elm_layout_part_cursor_unset(Evas_Object *obj, const char *part_name); + [ :elm_layout_part_cursor_unset, [ :evas_object, :string ], :void ], + # EAPI Eina_Bool elm_layout_part_cursor_style_set(Evas_Object *obj, const char *part_name, const char *style); + [ :elm_layout_part_cursor_style_set, [ :evas_object, :string, :string ], :bool ], + # EAPI const char *elm_layout_part_cursor_style_get(const Evas_Object *obj, const char *part_name); + [ :elm_layout_part_cursor_style_get, [ :evas_object, :string ], :string ], + # EAPI Eina_Bool elm_layout_part_cursor_engine_only_set(Evas_Object *obj, const char *part_name, Eina_Bool engine_only); + [ :elm_layout_part_cursor_engine_only_set, [ :evas_object, :string, :bool ], :bool ], + # EAPI Eina_Bool elm_layout_part_cursor_engine_only_get(const Evas_Object *obj, const char *part_name); + [ :elm_layout_part_cursor_engine_only_get, [ :evas_object, :string ], :bool ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 7aab889..ad3dd8e 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -65,6 +65,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_clock.h" \ "${INCLUDE}/elementary-0/elm_calendar.h" \ "${INCLUDE}/elementary-0/elm_bubble.h" \ + "${INCLUDE}/elementary-0/elm_layout.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index aafe4d4..70f2592 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -445,6 +445,11 @@ libs << { :modname=>'ElmBubble', :prefix=>'elm_bubble', :outfile=>'elm/elm_bubble.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_layout.h', + :modname=>'ElmLayout', :prefix=>'elm_layout', :outfile=>'elm/elm_layout.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From 5894c348596d25e349ec92f7a56c67374dd68618 Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:43:50 +0100 Subject: parse elm_cursor.h, generate elm_cursor.rb --- lib/efl/elm/elm_cursor.rb | 20 ++++++++++++++++ lib/efl/native/elm/elm_cursor.rb | 51 ++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 ++++ 4 files changed, 77 insertions(+) create mode 100644 lib/efl/elm/elm_cursor.rb create mode 100644 lib/efl/native/elm/elm_cursor.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_cursor.rb b/lib/efl/elm/elm_cursor.rb new file mode 100644 index 0000000..cfdd602 --- /dev/null +++ b/lib/efl/elm/elm_cursor.rb @@ -0,0 +1,20 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_cursor' +# +module Efl + # + module Elm + # + class ElmCursor < ElmObject + # + search_prefixes 'elm_cursor_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_cursor.rb b/lib/efl/native/elm/elm_cursor.rb new file mode 100644 index 0000000..1a0b6fe --- /dev/null +++ b/lib/efl/native/elm/elm_cursor.rb @@ -0,0 +1,51 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmCursor + # + FCT_PREFIX = 'elm_cursor_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # FUNCTIONS + fcts = [ + # EAPI void elm_object_cursor_set(Evas_Object *obj, const char *cursor); + [ :elm_object_cursor_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_object_cursor_get(const Evas_Object *obj); + [ :elm_object_cursor_get, [ :evas_object ], :string ], + # EAPI void elm_object_cursor_unset(Evas_Object *obj); + [ :elm_object_cursor_unset, [ :evas_object ], :void ], + # EAPI void elm_object_cursor_style_set(Evas_Object *obj, const char *style); + [ :elm_object_cursor_style_set, [ :evas_object, :string ], :void ], + # EAPI const char *elm_object_cursor_style_get(const Evas_Object *obj); + [ :elm_object_cursor_style_get, [ :evas_object ], :string ], + # EAPI void elm_object_cursor_engine_only_set(Evas_Object *obj, Eina_Bool engine_only); + [ :elm_object_cursor_engine_only_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_object_cursor_engine_only_get(const Evas_Object *obj); + [ :elm_object_cursor_engine_only_get, [ :evas_object ], :bool ], + # EAPI int elm_cursor_engine_only_get(void); + [ :elm_cursor_engine_only_get, [ ], :int ], + # EAPI Eina_Bool elm_cursor_engine_only_set(int engine_only); + [ :elm_cursor_engine_only_set, [ :int ], :bool ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index ad3dd8e..57eae16 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -66,6 +66,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_calendar.h" \ "${INCLUDE}/elementary-0/elm_bubble.h" \ "${INCLUDE}/elementary-0/elm_layout.h" \ + "${INCLUDE}/elementary-0/elm_cursor.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 70f2592..10f269d 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -450,6 +450,11 @@ libs << { :modname=>'ElmLayout', :prefix=>'elm_layout', :outfile=>'elm/elm_layout.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_cursor.h', + :modname=>'ElmCursor', :prefix=>'elm_cursor', :outfile=>'elm/elm_cursor.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3 From b030c490265bb13ee98a650da419a033495042ed Mon Sep 17 00:00:00 2001 From: Jérémy Zurcher Date: Mon, 27 Feb 2012 15:45:59 +0100 Subject: parse elm_notify.h, generate elm_notify.rb --- lib/efl/elm/elm_notify.rb | 22 ++++++++++++++++ lib/efl/native/elm/elm_notify.rb | 57 ++++++++++++++++++++++++++++++++++++++++ tools/extract-api.sh | 1 + tools/genruby.rb | 5 ++++ 4 files changed, 85 insertions(+) create mode 100644 lib/efl/elm/elm_notify.rb create mode 100644 lib/efl/native/elm/elm_notify.rb (limited to 'lib/efl/native/elm') diff --git a/lib/efl/elm/elm_notify.rb b/lib/efl/elm/elm_notify.rb new file mode 100644 index 0000000..c1b3d4c --- /dev/null +++ b/lib/efl/elm/elm_notify.rb @@ -0,0 +1,22 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/elm/elm_object' +require 'efl/native/elm/elm_notify' +# +module Efl + # + module Elm + # + class ElmNotify < ElmObject + # + include Helper + constructor :elm_notify_add + search_prefixes 'elm_check_' + # + end + # + end +end +# +# EOF diff --git a/lib/efl/native/elm/elm_notify.rb b/lib/efl/native/elm/elm_notify.rb new file mode 100644 index 0000000..656bb28 --- /dev/null +++ b/lib/efl/native/elm/elm_notify.rb @@ -0,0 +1,57 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/elementary' +# +module Efl + # + module ElmNotify + # + FCT_PREFIX = 'elm_notify_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'elementary-ver-pre-svn-09.so.0' + # + # ENUMS + # typedef enum {...} Elm_Notify_Orient; + enum :elm_notify_orient, [ :elm_notify_orient_top, :elm_notify_orient_center, :elm_notify_orient_bottom, :elm_notify_orient_left, + :elm_notify_orient_right, :elm_notify_orient_top_left, :elm_notify_orient_top_right, :elm_notify_orient_bottom_left, :elm_notify_orient_bottom_right, + :elm_notify_orient_last ] + # + # FUNCTIONS + fcts = [ + # EAPI Evas_Object *elm_notify_add(Evas_Object *parent); + [ :elm_notify_add, [ :evas_object ], :evas_object ], + # EAPI void elm_notify_parent_set(Evas_Object *obj, Evas_Object *parent); + [ :elm_notify_parent_set, [ :evas_object, :evas_object ], :void ], + # EAPI Evas_Object *elm_notify_parent_get(const Evas_Object *obj); + [ :elm_notify_parent_get, [ :evas_object ], :evas_object ], + # EAPI void elm_notify_orient_set(Evas_Object *obj, Elm_Notify_Orient orient); + [ :elm_notify_orient_set, [ :evas_object, :elm_notify_orient ], :void ], + # EAPI Elm_Notify_Orient elm_notify_orient_get(const Evas_Object *obj); + [ :elm_notify_orient_get, [ :evas_object ], :elm_notify_orient ], + # EAPI void elm_notify_timeout_set(Evas_Object *obj, double timeout); + [ :elm_notify_timeout_set, [ :evas_object, :double ], :void ], + # EAPI double elm_notify_timeout_get(const Evas_Object *obj); + [ :elm_notify_timeout_get, [ :evas_object ], :double ], + # EAPI void elm_notify_repeat_events_set(Evas_Object *obj, Eina_Bool repeat); + [ :elm_notify_repeat_events_set, [ :evas_object, :bool ], :void ], + # EAPI Eina_Bool elm_notify_repeat_events_get(const Evas_Object *obj); + [ :elm_notify_repeat_events_get, [ :evas_object ], :bool ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 57eae16..af7945b 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -67,6 +67,7 @@ for header in \ "${INCLUDE}/elementary-0/elm_bubble.h" \ "${INCLUDE}/elementary-0/elm_layout.h" \ "${INCLUDE}/elementary-0/elm_cursor.h" \ + "${INCLUDE}/elementary-0/elm_notify.h" \ ; do # if [ ! -e "$header" ]; then diff --git a/tools/genruby.rb b/tools/genruby.rb index 10f269d..f6980fb 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -455,6 +455,11 @@ libs << { :modname=>'ElmCursor', :prefix=>'elm_cursor', :outfile=>'elm/elm_cursor.rb', :requires=>["#{NATIVE}/elementary"], :constants=>[] } +libs << { + :lib=>ELM_LIB,:header=>'elm_notify.h', + :modname=>'ElmNotify', :prefix=>'elm_notify', :outfile=>'elm/elm_notify.rb', + :requires=>["#{NATIVE}/elementary"], :constants=>[] +} # Dir.mkdir lib_path unless (File.exists? lib_path) # -- cgit v1.2.3