Some documentation updates

Document gtk_settings_get_for_display instead of for_screen.
This commit is contained in:
Matthias Clasen 2017-10-30 18:58:05 -04:00
parent 154117218c
commit a1a5f556cb
2 changed files with 17 additions and 6 deletions

View File

@ -2642,6 +2642,7 @@ GtkSettings
GtkSettingsValue GtkSettingsValue
gtk_settings_get_default gtk_settings_get_default
gtk_settings_get_for_screen gtk_settings_get_for_screen
gtk_settings_get_for_display
gtk_rc_property_parse_color gtk_rc_property_parse_color
gtk_rc_property_parse_enum gtk_rc_property_parse_enum
gtk_rc_property_parse_flags gtk_rc_property_parse_flags

View File

@ -100,10 +100,10 @@
* g_object_set (gtk_settings_get_default (), "gtk-enable-animations", FALSE, NULL); * g_object_set (gtk_settings_get_default (), "gtk-enable-animations", FALSE, NULL);
* ]| * ]|
* *
* There is one GtkSettings instance per screen. It can be obtained with * There is one GtkSettings instance per display. It can be obtained with
* gtk_settings_get_for_screen(), but in many cases, it is more convenient * gtk_settings_get_for_display(), but in many cases, it is more convenient
* to use gtk_widget_get_settings(). gtk_settings_get_default() returns the * to use gtk_widget_get_settings(). gtk_settings_get_default() returns the
* GtkSettings instance for the default screen. * GtkSettings instance for the default display.
*/ */
@ -1247,6 +1247,16 @@ gtk_settings_create_for_display (GdkDisplay *display)
return settings; return settings;
} }
/**
* gtk_settings_get_for_display:
* @screen: a #GdkDisplay
*
* Gets the #GtkSettings object for @display, creating it if necessary.
*
* Returns: (transfer none): a #GtkSettings object.
*
* Since: 3.94
*/
GtkSettings * GtkSettings *
gtk_settings_get_for_display (GdkDisplay *display) gtk_settings_get_for_display (GdkDisplay *display)
{ {
@ -1288,11 +1298,11 @@ gtk_settings_get_for_screen (GdkScreen *screen)
/** /**
* gtk_settings_get_default: * gtk_settings_get_default:
* *
* Gets the #GtkSettings object for the default GDK screen, creating * Gets the #GtkSettings object for the default display, creating
* it if necessary. See gtk_settings_get_for_screen(). * it if necessary. See gtk_settings_get_for_display().
* *
* Returns: (nullable) (transfer none): a #GtkSettings object. If there is * Returns: (nullable) (transfer none): a #GtkSettings object. If there is
* no default screen, then returns %NULL. * no default display, then returns %NULL.
**/ **/
GtkSettings* GtkSettings*
gtk_settings_get_default (void) gtk_settings_get_default (void)