[webkit-efl] Naming rules for setting APIs
Jinwoo Song
jinwoo7.song at samsung.com
Wed Oct 10 04:07:15 PDT 2012
Hi,
I'm revisiting API names and documentation of WebKit2 EFL settings.
https://bugs.webkit.org/show_bug.cgi?id=98793
Currently, there is no concrete rules for API naming, so the names are inconsistent.
For example:
ewk_settings_enable_frame_flattening_set()/ewk_settings_enable_frame_flattening_get()
vs.
ewk_settings_developer_extras_enabled_set()/ewk_settings_developer_extras_enabled_get()
Grzegorz suggested to use 'ewk_settings_enable_frame_flattening_set() with following rules and I also prefer this one.
> 1) WK1 uses similar API, for example: ewk_view_setting_enable_frame_flattening_set
> 2) Verb next to another verb (enabled_set) doesn't looks/sounds well.
> 3) I'd rather prefer not using plural in API (enabled -> enable)
> 4) The Spelling API bug 91854 proposes API syntax based on above suggestions (as during work on this there wasn't ewk2-settings yet). So we will have consistent API.
FYI, GTK uses set_enable_frame_flattening() and Qt uses setFrameFlatteningEnabled().
So I'd like to here the opinions for the naming rule and if there is no objections for the suggested rule, I'll adjust the APIs with this one.
Thanks,
Jinwoo
More information about the webkit-efl
mailing list