1 // Copyright 2013 Samsung Electronics. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
7 * @brief Describes the settings API.
9 * @note The ewk_settings is for setting the preference of specific ewk_view.
10 * We can get the ewk_settings from ewk_view using ewk_view_settings_get() API.
13 #ifndef ewk_settings_h
14 #define ewk_settings_h
23 /** Creates a type name for Ewk_Settings */
24 typedef struct Ewk_Settings Ewk_Settings;
27 * Creates a type name for the callback function used to notify the client when
28 * the continuous spell checking setting was changed by WebKit.
30 * @param enable @c EINA_TRUE if continuous spell checking is enabled or @c EINA_FALSE if it's disabled
32 typedef void (*Ewk_Settings_Continuous_Spell_Checking_Change_Cb)(Eina_Bool enable);
35 * \enum _Ewk_Editable_Link_Behavior
37 * @brief Editable link behavior mode (Must remain in sync with WKEditableLinkBehavior)
39 enum _Ewk_Editable_Link_Behavior {
40 EWK_EDITABLE_LINK_BEHAVIOR_DEFAULT,
41 EWK_EDITABLE_LINK_BEHAVIOR_ALWAYS_LIVE,
42 EWK_EDITABLE_LINK_BEHAVIOR_ONLY_LIVE_WITH_SHIFTKEY,
43 EWK_EDITABLE_LINK_BEHAVIOR_LIVE_WHEN_NOT_FOCUSED,
44 EWK_EDITABLE_LINK_BEHAVIOR_NEVER_LIVE
46 typedef enum _Ewk_Editable_Link_Behavior Ewk_Editable_Link_Behavior;
48 enum _Ewk_Legacy_Font_Size_Mode {
49 EWK_LEGACY_FONT_SIZE_MODE_ALWAYS,
50 EWK_LEGACY_FONT_SIZE_MODE_ONLY_IF_PIXEL_VALUES_MATCH,
51 EWK_LEGACY_FONT_SIZE_MODE_NEVER
54 typedef enum _Ewk_Legacy_Font_Size_Mode Ewk_Legacy_Font_Size_Mode;
56 enum _Ewk_List_Style_Position {
57 EWK_LIST_STYLE_POSITION_OUTSIDE, /**< Default WebKit value. */
58 EWK_LIST_STYLE_POSITION_INSIDE
60 typedef enum _Ewk_List_Style_Position Ewk_List_Style_Position;
63 * Enables/disables the Javascript Fullscreen API. The Javascript API allows
64 * to request full screen mode, for more information see:
65 * http://dvcs.w3.org/hg/fullscreen/raw-file/tip/Overview.html
67 * Default value for Javascript Fullscreen API setting is @c EINA_TRUE .
69 * @param settings settings object to enable Javascript Fullscreen API
70 * @param enable @c EINA_TRUE to enable Javascript Fullscreen API or
71 * @c EINA_FALSE to disable
73 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
75 EXPORT_API Eina_Bool ewk_settings_fullscreen_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
78 * Returns whether the Javascript Fullscreen API is enabled or not.
80 * @param settings settings object to query whether Javascript Fullscreen API is enabled
82 * @return @c EINA_TRUE if the Javascript Fullscreen API is enabled
83 * @c EINA_FALSE if not or on failure
85 EXPORT_API Eina_Bool ewk_settings_fullscreen_enabled_get(const Ewk_Settings *settings);
88 * Enables/disables the javascript executing.
90 * @param settings settings object to set javascript executing
91 * @param enable @c EINA_TRUE to enable javascript executing
92 * @c EINA_FALSE to disable
94 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
96 EXPORT_API Eina_Bool ewk_settings_javascript_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
99 * Returns the javascript can be executable or not.
101 * @param settings settings object to query if the javascript can be executed
103 * @return @c EINA_TRUE if the javascript can be executed
104 * @c EINA_FALSE if not or on failure
106 EXPORT_API Eina_Bool ewk_settings_javascript_enabled_get(const Ewk_Settings *settings);
109 * Enables/disables auto loading of the images.
111 * @param settings settings object to set auto loading of the images
112 * @param automatic @c EINA_TRUE to enable auto loading of the images,
113 * @c EINA_FALSE to disable
115 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
117 EXPORT_API Eina_Bool ewk_settings_loads_images_automatically_set(Ewk_Settings *settings, Eina_Bool automatic);
120 * Returns the images can be loaded automatically or not.
122 * @param settings settings object to get auto loading of the images
124 * @return @c EINA_TRUE if the images are loaded automatically,
125 * @c EINA_FALSE if not or on failure
127 EXPORT_API Eina_Bool ewk_settings_loads_images_automatically_get(const Ewk_Settings *settings);
130 * Requests enables/disables the plug-ins.
132 * @param settings settings object to set the plug-ins
133 * @param enable @c EINA_TRUE to enable the plug-ins
134 * @c EINA_FALSE to disable
136 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
138 EXPORT_API Eina_Bool ewk_settings_plugins_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
141 * Returs enables/disables the plug-ins.
143 * @param settings settings object to set the plug-ins
145 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
147 EXPORT_API Eina_Bool ewk_settings_plugins_enabled_get(const Ewk_Settings *settings);
150 * Requests setting of auto fit.
152 * @param settings settings object to fit to width
153 * @param enable to fit to width.
155 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
157 EXPORT_API Eina_Bool ewk_settings_auto_fitting_set(Ewk_Settings *settings, Eina_Bool enable);
160 * Returns the auto fit status.
162 * @param settings settings object to fit to width
164 * @return @c EINA_TRUE if enable auto fit or @c EINA_FALSE.
166 EXPORT_API Eina_Bool ewk_settings_auto_fitting_get(const Ewk_Settings *settings);
169 * Requests setting of force zoom.
171 * @param settings settings object to enable force zoom
172 * @param enable to force zoom
174 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
176 EXPORT_API Eina_Bool ewk_settings_force_zoom_set(Ewk_Settings *settings, Eina_Bool enable);
179 * Returns the force zoom status.
181 * @param settings settings object to enable force zoom
183 * @return @c EINA_TRUE if enable force zoom or @c EINA_FALSE.
185 EXPORT_API Eina_Bool ewk_settings_force_zoom_get(const Ewk_Settings *settings);
188 * Requests to set the default font size.
190 * @param settings settings object to set the default font size
191 * @param size a new default font size to set
193 * @return @c EINA_TRUE on success @c EINA_FALSE otherwise
195 EXPORT_API Eina_Bool ewk_settings_font_default_size_set(Ewk_Settings *settings, int size);
198 * Returns the default font size.
200 * @param settings settings object to set the default font size
202 * @return @c default font size.
204 EXPORT_API int ewk_settings_font_default_size_get(const Ewk_Settings *settings);
207 * Requests enables/disables if the scripts can open the new windows.
209 * @param settings settings object to set if the scripts can open the new windows
210 * @param allow @c EINA_TRUE if the scripts can open the new windows
211 * @c EINA_FALSE if not
213 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure (scripts are disabled)
215 EXPORT_API Eina_Bool ewk_settings_scripts_window_open_set(Ewk_Settings *settings, Eina_Bool allow);
218 * Returns enables/disables if the scripts can open the new windows.
220 * @param settings settings object to set if the scripts can open the new windows
222 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure (scripts are disabled)
224 EXPORT_API Eina_Bool ewk_settings_scripts_window_open_get(const Ewk_Settings *settings);
227 * Requests for drawing layer borders.
229 * @param settings settings object to drawing layer borders.
230 * @param enable EINA_TRUE to draw layer borders.
232 * @return @c EINA_TRUE on successful request or @c EINA_FALSE on failure
235 EXPORT_API Eina_Bool ewk_settings_compositing_borders_visible_set(Ewk_Settings *settings, Eina_Bool enable);
238 * Checks whether WebKit supports the @a encoding.
240 * @param encoding the encoding string to check whether WebKit supports it
242 * @return @c EINA_TRUE if WebKit supports @a encoding or @c EINA_FALSE if not or
245 EXPORT_API Eina_Bool ewk_settings_is_encoding_valid(const char* encoding);
248 * Requests to set default text encoding name.
250 * @param settings settings object to set default text encoding name
251 * @param encoding default text encoding name
253 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
255 EXPORT_API Eina_Bool ewk_settings_default_encoding_set(Ewk_Settings *settings, const char* encoding);
258 * Returns default text encoding name.
260 * @param settings settings object to query default text encoding nae
262 * @return default text encoding name
264 EXPORT_API const char* ewk_settings_default_encoding_get(const Ewk_Settings *settings);
267 * Requests enables/disables private browsing.
269 * @param settings settings object to set private browsing
270 * @param enable @c EINA_TRUE to enable private browsing
271 * @c EINA_FALSE to disable
273 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
275 EINA_DEPRECATED EXPORT_API Eina_Bool ewk_settings_private_browsing_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
278 * Returns enables/disables private browsing.
280 * @param settings settings object to query if private browsing was enabled
282 * @return @c EINA_TRUE if private browsing was enabled
283 * @c EINA_FALSE if not or on failure
285 EINA_DEPRECATED EXPORT_API Eina_Bool ewk_settings_private_browsing_enabled_get(const Ewk_Settings *settings);
288 * Requests to set editable link behavior.
290 * @param settings settings object to set editable link behavior
291 * @param behavior editable link behaviro
293 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
295 EXPORT_API Eina_Bool ewk_settings_editable_link_behavior_set(Ewk_Settings *settings, Ewk_Editable_Link_Behavior behavior);
298 * Requests to set the load remote images enable/disable
300 * @param settings settings object to set load remote images
302 * @param loadRemoteImages @c EINA_TRUE to enable the load remote images
303 * @c EINA_FALSE to disable
305 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
307 EXPORT_API Eina_Bool ewk_settings_load_remote_images_set(Ewk_Settings *settings, Eina_Bool loadRemoteImages);
309 * Returns enable/disable the load remote images
311 * @param settings settings object to get editable link behavior
313 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
315 EXPORT_API Eina_Bool ewk_settings_load_remote_images_get(const Ewk_Settings *settings);
318 * Sets link magnifier enabled.
320 * @param settings settings object
321 * @param enabled link magnifier enabled
323 EXPORT_API void ewk_settings_link_magnifier_enabled_set(Ewk_Settings *settings, Eina_Bool enabled);
326 * Gets link magnifier enabled.
328 * @param settings settings object
330 * @return @c EINA_TRUE if link magnifier enabled, @c EINA_FALSE otherwise
332 EXPORT_API Eina_Bool ewk_settings_link_magnifier_enabled_get(const Ewk_Settings *settings);
335 * Requests to enable/disable link effect
337 * @param settings settings object to enable/disable link effect
339 * @param linkEffectEnabled @c EINA_TRUE to enable the link effect
340 * @c EINA_FALSE to disable
342 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
344 EXPORT_API Eina_Bool ewk_settings_link_effect_enabled_set(Ewk_Settings *settings, Eina_Bool linkEffectEnabled);
347 * Returns enable/disable link effect
349 * @param settings settings object to get whether link effect is enabled or disabled
351 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
353 EXPORT_API Eina_Bool ewk_settings_link_effect_enabled_get(const Ewk_Settings *settings);
356 * Requests to set the scan malware enable/disable.
358 * @param settings settings object to set scan malware
360 * @param scan_malware_enabled @c EINA_TRUE to enable the scan malware
361 * @c EINA_FALSE to disable
363 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
365 EXPORT_API Eina_Bool ewk_settings_scan_malware_enabled_set(Ewk_Settings *settings, Eina_Bool scan_malware_enabled);
368 * Requests to set the spdy enable/disable.
370 * @param settings settings object to set spdy on soup
372 * @param spdy_enabled @c EINA_TRUE to enable the spdy on soup
373 * @c EINA_FALSE to disable
375 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
377 EXPORT_API Eina_Bool ewk_settings_spdy_enabled_set(Ewk_Settings *settings, Eina_Bool spdy_enabled);
380 * Requests to set the performance features of soup enable/disable.
382 * @param settings settings object to set performance features on soup
384 * @param spdy_enabled @c EINA_TRUE to enable the performance features on soup
385 * @c EINA_FALSE to disable
387 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
389 EXPORT_API Eina_Bool ewk_settings_performance_features_enabled_set(Ewk_Settings *settings, Eina_Bool performance_features_enabled);
392 * Requests to set using encoding detector.
394 * @param settings settings object to set using encoding detector
395 * @param use use encoding detector
397 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
399 EXPORT_API Eina_Bool ewk_settings_uses_encoding_detector_set(Ewk_Settings *settings, Eina_Bool use);
402 * Returns uses encoding detector.
404 * @param settings settings object to query uses encoding detector
406 * @return uses encoding detector
408 EXPORT_API Eina_Bool ewk_settings_uses_encoding_detector_get(const Ewk_Settings *settings);
411 * Requests to set using default keypad (default value : true)
413 * @param settings settings object to use default keypad
414 * @param enable @c EINA_TRUE to use default keypad @c EINA_FALSE to disable
416 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
418 EXPORT_API Eina_Bool ewk_settings_default_keypad_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
421 * Returns enable/disable using default keypad
423 * @param settings settings object to use default keypad
425 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
427 EXPORT_API Eina_Bool ewk_settings_default_keypad_enabled_get(const Ewk_Settings *settings);
430 * Requests to set using keypad without user action (default value : true)
432 * @param settings settings object using keypad without user action
433 * @param enable @c EINA_TRUE to use without user action @c EINA_FALSE to disable
435 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
437 EXPORT_API Eina_Bool ewk_settings_uses_keypad_without_user_action_set(Ewk_Settings *settings, Eina_Bool enable);
440 * Returns using keypad without user action
442 * @param settings settings object using keypad without user action
443 * @param settings settings object to query using keypad without user action
445 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
447 EXPORT_API Eina_Bool ewk_settings_uses_keypad_without_user_action_get(const Ewk_Settings *settings);
451 * Requests setting use of text zoom.
453 * @param settings settings object to text zoom
454 * @param enable to text zoom.
456 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
458 EXPORT_API Eina_Bool ewk_settings_text_zoom_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
461 * Returns whether text zoom is enabled or not.
463 * @param settings settings object to text zoom
465 * @return @c EINA_TRUE if enable text zoom or @c EINA_FALSE.
467 EXPORT_API Eina_Bool ewk_settings_text_zoom_enabled_get(const Ewk_Settings *settings);
470 * Requests enable/disable password form autofill
472 * @param setting setting object to set password form autofill
473 * @param enable @c EINA_TRUE to enable password form autofill
474 * @c EINA_FALSE to disable
476 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
478 EXPORT_API Eina_Bool ewk_settings_autofill_password_form_enabled_set(Ewk_Settings* settings, Eina_Bool enable);
481 * Returns if password form autofill is enabled or disabled.
483 * @param setting setting object to get password form autofill
485 * @return @c EINA_TRUE if password form autofill is enabled
486 * @c EINA_FALSE if password form autofill is disabled
488 EXPORT_API Eina_Bool ewk_settings_autofill_password_form_enabled_get(Ewk_Settings* settings);
491 * Requests enable/disable form candidate data for autofill
493 * @param setting setting object to set form candidate data for autofill
494 * @param enable @c EINA_TRUE to enable form candidate data for autofill
495 * @c EINA_FALSE to disable
497 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
499 EXPORT_API Eina_Bool ewk_settings_form_candidate_data_enabled_set(Ewk_Settings* settings, Eina_Bool enable);
502 * Returns if form candidate data for autofill is enabled or disabled.
504 * @param setting setting object to get form candidate data for autofill
506 * @return @c EINA_TRUE if form candidate data for autofill is enabled
507 * @c EINA_FALSE if form candidate data for autofill is disabled
509 EXPORT_API Eina_Bool ewk_settings_form_candidate_data_enabled_get(Ewk_Settings* settings);
512 * Enables/disables form autofill profile feature.
514 * By default, form autofill profile is disabled.
516 * @param settings settings object to set the form autofill profile
517 * @param enable @c EINA_TRUE to enable the text autosizing
518 * @c EINA_FALSE to disable
520 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
522 * @see ewk_settings_form_profile_data_enabled_get()
524 EXPORT_API Eina_Bool ewk_settings_form_profile_data_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
527 * Returns whether the autofill_text feature is enabled.
529 * @param settings settings object to query whether autofill_text feature is enabled
531 * @return @c EINA_TRUE if the autofill_text feature is enabled
532 * @c EINA_FALSE if not or on failure
534 EXPORT_API Eina_Bool ewk_settings_form_profile_data_enabled_get(const Ewk_Settings *settings);
537 * Requests enable/disable text selection by default WebKit.
539 * @param settings setting object to set text selection by default WebKit
540 * @param enable @c EINA_TRUE to enable text selection by default WebKit
541 * @c EINA_FALSE to disable
543 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
545 EXPORT_API Eina_Bool ewk_settings_text_selection_enabled_set(Ewk_Settings* settings, Eina_Bool enable);
548 * Returns if text selection by default WebKit is enabled or disabled.
550 * @param settings setting object to get text selection by default WebKit
552 * @return @c EINA_TRUE if text selection by default WebKit is enabled
553 * @c EINA_FALSE if not or on failure
555 EXPORT_API Eina_Bool ewk_settings_text_selection_enabled_get(const Ewk_Settings* settings);
558 * Requests enables/disables to clear text selection when webview lose focus
560 * @param settings setting object to set to clear text selection when webview lose focus
561 * @param enable @c EINA_TRUE to clear text selection when webview lose focus
562 * @c EINA_FALSE to disable
564 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
566 EXPORT_API Eina_Bool ewk_settings_clear_text_selection_automatically_set(Ewk_Settings* settings, Eina_Bool enable);
569 * Returns whether text selection is cleared when webview lose focus or not.
571 * @param settings setting object to get whether text selection is cleared when webview lose focus or not
573 * @return @c EINA_TRUE if text selection is cleared when webview lose focus
574 * @c EINA_FALSE if not or on failure
576 EXPORT_API Eina_Bool ewk_settings_clear_text_selection_automatically_get(const Ewk_Settings* settings);
579 * Enables/disables text autosizing.
581 * By default, the text autosizing is disabled.
583 * @param settings settings object to set the text autosizing
584 * @param enable @c EINA_TRUE to enable the text autosizing
585 * @c EINA_FALSE to disable
587 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
589 * @see ewk_settings_text_autosizing_enabled_get()
591 EXPORT_API Eina_Bool ewk_settings_text_autosizing_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
594 * Returns whether the text autosizing is enabled.
596 * The text autosizing is a feature which adjusts the font size of text in wide
597 * columns, and makes text more legible.
599 * @param settings settings object to query whether text autosizing is enabled
601 * @return @c EINA_TRUE if the text autosizing is enabled
602 * @c EINA_FALSE if not or on failure
604 EXPORT_API Eina_Bool ewk_settings_text_autosizing_enabled_get(const Ewk_Settings *settings);
608 * Sets the scale factor for text autosizing.
610 * Default value is 1.0.
612 * @param settings settings object to set the text autosizing
613 * @param factor font scale factor for text autosizing
615 EXPORT_API Eina_Bool ewk_settings_text_autosizing_font_scale_factor_set(Ewk_Settings *settings, double factor);
618 * Gets the current scale factor for text autosizing.
620 * @param settings settings object to set scale factor for text autosizing
622 * @return the current font scale factor for text autosizing.
623 * In case of error, it returns non-positive value.
625 EXPORT_API double ewk_settings_text_autosizing_font_scale_factor_get(const Ewk_Settings *settings);
628 * Requests to enable/disable edge effect
630 * @param settings settings object to enable/disable edge effect
632 * @param enable @c EINA_TRUE to enable the edge effect
633 * @c EINA_FALSE to disable
635 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
637 EXPORT_API Eina_Bool ewk_settings_edge_effect_enabled_set(Ewk_Settings* settings, Eina_Bool enable);
640 * Returns enable/disable edge effect
642 * @param settings settings object to get whether edge effect is enabled or disabled
644 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
646 EXPORT_API Eina_Bool ewk_settings_edge_effect_enabled_get(const Ewk_Settings* settings);
649 * Sets text style for selection mode enabled.
651 * @param settings settings object
652 * @param enabled text style for selection mode
655 EXPORT_API void ewk_settings_text_style_state_enabled_set(Ewk_Settings *settings, Eina_Bool enabled);
657 * Gets text style for selection mode enabled.
659 * @param settings settings object
661 * @return @c EINA_TRUE if text style for selection mode enabled, @c EINA_FALSE otherwise
663 EXPORT_API Eina_Bool ewk_settings_text_style_state_enabled_get(const Ewk_Settings *settings);
666 * Requests to enable/disable to select word by double tap
668 * @param settings settings object to enable/disable to select word by double tap
669 * @param enable @c EINA_TRUE to select word by double tap
670 * @c EINA_FALSE to disable
672 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
674 EXPORT_API Eina_Bool ewk_settings_select_word_automatically_set(Ewk_Settings *settings, Eina_Bool enabled);
677 * Returns enable/disable text selection by double tap
679 * @param settings settings object to get whether word by double tap is selected
681 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
683 EXPORT_API Eina_Bool ewk_settings_select_word_automatically_get(const Ewk_Settings *settings);
686 * Sets legacy font size mode
688 * @param settings settings object
689 * @param mode legacy font size mode
691 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
693 EXPORT_API Eina_Bool ewk_settings_current_legacy_font_size_mode_set(Ewk_Settings *settings, Ewk_Legacy_Font_Size_Mode mode);
696 * Returns set legacy font size mode
698 * @param settings settings object
700 * @return @c Ewk_Legacy_Font_Size_Mode set legacy font size mode
702 EXPORT_API Ewk_Legacy_Font_Size_Mode ewk_settings_current_legacy_font_size_mode_get(const Ewk_Settings *settings);
705 * Sets to paste image as URI (default: paste as base64-encoded-data)
707 * @param settings settings object
708 * @param enable @c EINA_TRUE to paste image as URI @c EINA_FALSE to paste image as data
710 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
712 EXPORT_API Eina_Bool ewk_settings_paste_image_uri_mode_set(Ewk_Settings *settings, Eina_Bool enabled);
715 * Returns whether paste image as URI mode is enabled
717 * @param settings settings object
719 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
721 EXPORT_API Eina_Bool ewk_settings_paste_image_uri_mode_get(const Ewk_Settings *settings);
724 * Gets the initial position value for the HTML list element <ul></ul>.
726 * @param settings setting object to get the initial position value
728 * @return the initial position value for the HTML list element.
730 EXPORT_API Ewk_List_Style_Position ewk_settings_initial_list_style_position_get(const Ewk_Settings* settings);
733 * Sets the initial position value for the HTML list element <ul></ul>.
735 * This value affect the lists that are going to be created,
736 * does not make sense to manipulate it for existed elements.
738 * @param settings setting object to set the initial list style position
739 * @param style a new style to set
741 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
743 EXPORT_API Eina_Bool ewk_settings_initial_list_style_position_set(Ewk_Settings* settings, Ewk_List_Style_Position style);
746 * Enable or disable supporting of -webkit-text-size-adjust
748 * -webkit-text-size-adjust affects text size adjusting feature.
750 * @param settings setting object to set the support of -webkit-text-size-adjust
751 * @param enable @c EINA_TRUE to support -webkit-text-size-adjust, @c EINA_FALSE not to support
753 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
755 EXPORT_API Eina_Bool ewk_settings_webkit_text_size_adjust_enabled_set(Ewk_Settings* settings, Eina_Bool enabled);
758 * Requests to enable/disable to detect email address when tapping on email address without link property
760 * @param settings settings object to enable/disable to detect email address when tapping on email address without link property
762 * @param enable @c EINA_TRUE to enable to detect email address when tapping on email address without link property
763 * @c EINA_FALSE to disable
765 EXPORT_API void ewk_settings_detect_contents_automatically_set(Ewk_Settings* settings, Eina_Bool enable);
768 * Returns enable/disable to detect email address when tapping on email address without link property
770 * @param settings settings object to get whether email address is detected when tapping on email address without link property
772 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
774 EXPORT_API Eina_Bool ewk_settings_detect_contents_automatically_get(const Ewk_Settings* settings);
777 * Sets cache builder mode enabled.
779 * @param settings settings object
780 * @param enabled cache builder mode
782 EXPORT_API void ewk_settings_cache_builder_enabled_set(Ewk_Settings *settings, Eina_Bool enabled);
785 * Returns the default font size.
787 * @param settings settings object to get the default font size
789 * @return @c the default font size or @c 0 on failure
791 EXPORT_API int ewk_settings_default_font_size_get(const Ewk_Settings *settings);
794 * Sets the default font size.
796 * By default, the default font size is @c 16.
798 * @param settings settings object to set the default font size
799 * @param size a new default font size to set
801 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
803 EXPORT_API Eina_Bool ewk_settings_default_font_size_set(Ewk_Settings *settings, int size);
806 * Gets the default text encoding name.
808 * @param settings settings object to get default text encoding name
810 * @return @c encoding default text encoding name
812 EXPORT_API const char* ewk_settings_default_text_encoding_name_get(Ewk_Settings *settings);
815 * Sets the default text encoding name.
817 * @param settings settings object to set default text encoding name
818 * @param encoding default text encoding name
820 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
822 EXPORT_API Eina_Bool ewk_settings_default_text_encoding_name_set(Ewk_Settings *settings, const char *encoding);
825 * Enables/disables the encoding detector.
827 * By default, the encoding detector is disabled.
829 * @param settings settings object to set the encoding detector
830 * @param enable @c EINA_TRUE to enable the encoding detector,
831 * @c EINA_FALSE to disable
833 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
835 EXPORT_API Eina_Bool ewk_settings_encoding_detector_enabled_set(Ewk_Settings *settings, Eina_Bool enable);
838 * Enables/disables if the scripts can open new windows.
840 * By default, the scripts can open new windows.
842 * @param settings settings object to set if the scripts can open new windows
843 * @param enable @c EINA_TRUE if the scripts can open new windows
844 * @c EINA_FALSE if not
846 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure (scripts are disabled)
848 EXPORT_API Eina_Bool ewk_settings_scripts_can_open_windows_set(Ewk_Settings *settings, Eina_Bool enable);
851 * @brief Returns whether the scripts can open new windows.
855 * @param[in] settings The settingings object to query whether the scripts can open new windows
857 * @return @c EINA_TRUE if the scripts can open new windows\n
858 * otherwise @c EINA_FALSE if not or on failure (scripts are disabled)
860 EXPORT_API Eina_Bool ewk_settings_scripts_can_open_windows_get(const Ewk_Settings *settings);
863 * Requests enables/disables to the specific extra feature
865 * @param settings setting object to enable/disable the specific extra feature
866 * @param feature feature name
867 * @param enable @c EINA_TRUE to enable the specific extra feature
868 * @c EINA_FALSE to disable
870 * @return @c EINA_TRUE on success or @c EINA_FALSE on failure
872 EXPORT_API void ewk_settings_extra_feature_set(Ewk_Settings* settings, const char* feature, Eina_Bool enable);
875 * Returns enable/disable to the specific extra feature
877 * @param settings settings object to get whether the specific extra feature is enabled or not.
878 * @param feature feature name
880 * @return @c EINA_TRUE on enable or @c EINA_FALSE on disable
882 EXPORT_API Eina_Bool ewk_settings_extra_feature_get(const Ewk_Settings* settings, const char* feature);
887 #endif // ewk_settings_h