[gtk/wip/baedert/for-master] label: Remove "line" from wrap properties
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/baedert/for-master] label: Remove "line" from wrap properties
- Date: Thu, 22 Aug 2019 10:42:41 +0000 (UTC)
commit 4af0a3a7bb251d28c2a1ad47eca3bc4f13c2d31f
Author: Timm Bäder <mail baedert org>
Date: Thu Aug 22 12:41:39 2019 +0200
label: Remove "line" from wrap properties
The property names are "wrap" and "wrap-mode", so it doesn't make sense
that the accessors refer to line_wrap and line_wrap_mode.
demos/gtk-demo/expander.c | 2 +-
demos/gtk-demo/fishbowl.c | 2 +-
demos/gtk-demo/infobar.c | 10 +++++-----
demos/gtk-demo/main.c | 2 +-
docs/reference/gtk/gtk4-sections.txt | 8 ++++----
gtk/gtkheaderbar.c | 8 ++++----
gtk/gtklabel.c | 34 +++++++++++++++++-----------------
gtk/gtklabel.h | 12 ++++++------
gtk/gtkmountoperation.c | 4 ++--
gtk/gtkprintbackend.c | 2 +-
tests/testadjustsize.c | 4 ++--
tests/testcellarea.c | 4 ++--
tests/testclipboard2.c | 2 +-
tests/testflowbox.c | 4 ++--
tests/testgrid.c | 6 +++---
tests/testgtk.c | 8 ++++----
tests/testscrolledwindow.c | 2 +-
tests/testwindowsize.c | 2 +-
18 files changed, 58 insertions(+), 58 deletions(-)
---
diff --git a/demos/gtk-demo/expander.c b/demos/gtk-demo/expander.c
index 9ea3125511..fc3e7c60f9 100644
--- a/demos/gtk-demo/expander.c
+++ b/demos/gtk-demo/expander.c
@@ -52,7 +52,7 @@ do_expander (GtkWidget *do_widget)
area = gtk_message_dialog_get_message_area (GTK_MESSAGE_DIALOG (window));
label = gtk_widget_get_last_child (area);
- gtk_label_set_line_wrap (GTK_LABEL (label), FALSE);
+ gtk_label_set_wrap (GTK_LABEL (label), FALSE);
gtk_widget_set_vexpand (label, FALSE);
expander = gtk_expander_new ("Details:");
diff --git a/demos/gtk-demo/fishbowl.c b/demos/gtk-demo/fishbowl.c
index e420dc3748..45f63710b0 100644
--- a/demos/gtk-demo/fishbowl.c
+++ b/demos/gtk-demo/fishbowl.c
@@ -124,7 +124,7 @@ create_label (void)
{
GtkWidget *w = gtk_label_new ("pLorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua.");
- gtk_label_set_line_wrap (GTK_LABEL (w), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (w), TRUE);
gtk_label_set_max_width_chars (GTK_LABEL (w), 100);
return w;
diff --git a/demos/gtk-demo/infobar.c b/demos/gtk-demo/infobar.c
index 82d6b7c8b1..a78f2d9f61 100644
--- a/demos/gtk-demo/infobar.c
+++ b/demos/gtk-demo/infobar.c
@@ -68,7 +68,7 @@ do_infobar (GtkWidget *do_widget)
gtk_container_add (GTK_CONTAINER (vbox), bar);
gtk_info_bar_set_message_type (GTK_INFO_BAR (bar), GTK_MESSAGE_INFO);
label = gtk_label_new ("This is an info bar with message type GTK_MESSAGE_INFO");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_xalign (GTK_LABEL (label), 0);
gtk_container_add (GTK_CONTAINER (gtk_info_bar_get_content_area (GTK_INFO_BAR (bar))), label);
@@ -80,7 +80,7 @@ do_infobar (GtkWidget *do_widget)
gtk_container_add (GTK_CONTAINER (vbox), bar);
gtk_info_bar_set_message_type (GTK_INFO_BAR (bar), GTK_MESSAGE_WARNING);
label = gtk_label_new ("This is an info bar with message type GTK_MESSAGE_WARNING");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_xalign (GTK_LABEL (label), 0);
gtk_container_add (GTK_CONTAINER (gtk_info_bar_get_content_area (GTK_INFO_BAR (bar))), label);
@@ -94,7 +94,7 @@ do_infobar (GtkWidget *do_widget)
gtk_container_add (GTK_CONTAINER (vbox), bar);
gtk_info_bar_set_message_type (GTK_INFO_BAR (bar), GTK_MESSAGE_QUESTION);
label = gtk_label_new ("This is an info bar with message type GTK_MESSAGE_QUESTION");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_xalign (GTK_LABEL (label), 0);
gtk_container_add (GTK_CONTAINER (gtk_info_bar_get_content_area (GTK_INFO_BAR (bar))), label);
@@ -106,7 +106,7 @@ do_infobar (GtkWidget *do_widget)
gtk_container_add (GTK_CONTAINER (vbox), bar);
gtk_info_bar_set_message_type (GTK_INFO_BAR (bar), GTK_MESSAGE_ERROR);
label = gtk_label_new ("This is an info bar with message type GTK_MESSAGE_ERROR");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_xalign (GTK_LABEL (label), 0);
gtk_container_add (GTK_CONTAINER (gtk_info_bar_get_content_area (GTK_INFO_BAR (bar))), label);
@@ -119,7 +119,7 @@ do_infobar (GtkWidget *do_widget)
gtk_container_add (GTK_CONTAINER (vbox), bar);
gtk_info_bar_set_message_type (GTK_INFO_BAR (bar), GTK_MESSAGE_OTHER);
label = gtk_label_new ("This is an info bar with message type GTK_MESSAGE_OTHER");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_xalign (GTK_LABEL (label), 0);
gtk_container_add (GTK_CONTAINER (gtk_info_bar_get_content_area (GTK_INFO_BAR (bar))), label);
diff --git a/demos/gtk-demo/main.c b/demos/gtk-demo/main.c
index 6b997f5810..f9edf9d6d7 100644
--- a/demos/gtk-demo/main.c
+++ b/demos/gtk-demo/main.c
@@ -639,7 +639,7 @@ display_nothing (const char *resource)
str = g_strdup_printf ("The lazy GTK developers forgot to add a way to display the resource '%s'",
resource);
widget = gtk_label_new (str);
- gtk_label_set_line_wrap (GTK_LABEL (widget), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (widget), TRUE);
g_free (str);
diff --git a/docs/reference/gtk/gtk4-sections.txt b/docs/reference/gtk/gtk4-sections.txt
index 477c0b4b9c..87906de06d 100644
--- a/docs/reference/gtk/gtk4-sections.txt
+++ b/docs/reference/gtk/gtk4-sections.txt
@@ -1684,8 +1684,8 @@ gtk_label_set_yalign
gtk_label_set_ellipsize
gtk_label_set_width_chars
gtk_label_set_max_width_chars
-gtk_label_set_line_wrap
-gtk_label_set_line_wrap_mode
+gtk_label_set_wrap
+gtk_label_set_wrap_mode
gtk_label_set_lines
gtk_label_get_layout_offsets
gtk_label_get_mnemonic_keyval
@@ -1705,8 +1705,8 @@ gtk_label_get_width_chars
gtk_label_get_max_width_chars
gtk_label_get_label
gtk_label_get_layout
-gtk_label_get_line_wrap
-gtk_label_get_line_wrap_mode
+gtk_label_get_wrap
+gtk_label_get_wrap_mode
gtk_label_get_lines
gtk_label_get_mnemonic_widget
gtk_label_get_selection_bounds
diff --git a/gtk/gtkheaderbar.c b/gtk/gtkheaderbar.c
index d5ba561f61..5785960771 100644
--- a/gtk/gtkheaderbar.c
+++ b/gtk/gtkheaderbar.c
@@ -163,7 +163,7 @@ init_sizing_box (GtkHeaderBar *bar)
context = gtk_widget_get_style_context (w);
gtk_style_context_add_class (context, GTK_STYLE_CLASS_TITLE);
gtk_container_add (GTK_CONTAINER (priv->label_sizing_box), w);
- gtk_label_set_line_wrap (GTK_LABEL (w), FALSE);
+ gtk_label_set_wrap (GTK_LABEL (w), FALSE);
gtk_label_set_single_line_mode (GTK_LABEL (w), TRUE);
gtk_label_set_ellipsize (GTK_LABEL (w), PANGO_ELLIPSIZE_END);
gtk_label_set_width_chars (GTK_LABEL (w), MIN_TITLE_CHARS);
@@ -172,7 +172,7 @@ init_sizing_box (GtkHeaderBar *bar)
context = gtk_widget_get_style_context (w);
gtk_style_context_add_class (context, GTK_STYLE_CLASS_SUBTITLE);
gtk_container_add (GTK_CONTAINER (priv->label_sizing_box), w);
- gtk_label_set_line_wrap (GTK_LABEL (w), FALSE);
+ gtk_label_set_wrap (GTK_LABEL (w), FALSE);
gtk_label_set_single_line_mode (GTK_LABEL (w), TRUE);
gtk_label_set_ellipsize (GTK_LABEL (w), PANGO_ELLIPSIZE_END);
gtk_widget_set_visible (w, priv->has_subtitle || (priv->subtitle && priv->subtitle[0]));
@@ -196,7 +196,7 @@ create_title_box (const char *title,
title_label = gtk_label_new (title);
context = gtk_widget_get_style_context (title_label);
gtk_style_context_add_class (context, GTK_STYLE_CLASS_TITLE);
- gtk_label_set_line_wrap (GTK_LABEL (title_label), FALSE);
+ gtk_label_set_wrap (GTK_LABEL (title_label), FALSE);
gtk_label_set_single_line_mode (GTK_LABEL (title_label), TRUE);
gtk_label_set_ellipsize (GTK_LABEL (title_label), PANGO_ELLIPSIZE_END);
gtk_container_add (GTK_CONTAINER (label_box), title_label);
@@ -205,7 +205,7 @@ create_title_box (const char *title,
subtitle_label = gtk_label_new (subtitle);
context = gtk_widget_get_style_context (subtitle_label);
gtk_style_context_add_class (context, GTK_STYLE_CLASS_SUBTITLE);
- gtk_label_set_line_wrap (GTK_LABEL (subtitle_label), FALSE);
+ gtk_label_set_wrap (GTK_LABEL (subtitle_label), FALSE);
gtk_label_set_single_line_mode (GTK_LABEL (subtitle_label), TRUE);
gtk_label_set_ellipsize (GTK_LABEL (subtitle_label), PANGO_ELLIPSIZE_END);
gtk_container_add (GTK_CONTAINER (label_box), subtitle_label);
diff --git a/gtk/gtklabel.c b/gtk/gtklabel.c
index e5b5419e4f..dde3d4c21a 100644
--- a/gtk/gtklabel.c
+++ b/gtk/gtklabel.c
@@ -208,7 +208,7 @@
* understood by Pango.
*
* Labels can automatically wrap text if you call
- * gtk_label_set_line_wrap().
+ * gtk_label_set_wrap().
*
* gtk_label_set_justify() sets how the lines in a label align
* with one another. If you want to set how the label as a whole
@@ -1205,10 +1205,10 @@ gtk_label_set_property (GObject *object,
gtk_label_set_pattern (label, g_value_get_string (value));
break;
case PROP_WRAP:
- gtk_label_set_line_wrap (label, g_value_get_boolean (value));
+ gtk_label_set_wrap (label, g_value_get_boolean (value));
break;
case PROP_WRAP_MODE:
- gtk_label_set_line_wrap_mode (label, g_value_get_enum (value));
+ gtk_label_set_wrap_mode (label, g_value_get_enum (value));
break;
case PROP_SELECTABLE:
gtk_label_set_selectable (label, g_value_get_boolean (value));
@@ -3116,7 +3116,7 @@ gtk_label_get_max_width_chars (GtkLabel *label)
}
/**
- * gtk_label_set_line_wrap:
+ * gtk_label_set_wrap:
* @label: a #GtkLabel
* @wrap: the setting
*
@@ -3131,8 +3131,8 @@ gtk_label_get_max_width_chars (GtkLabel *label)
* set the label’s width using gtk_widget_set_size_request().
**/
void
-gtk_label_set_line_wrap (GtkLabel *label,
- gboolean wrap)
+gtk_label_set_wrap (GtkLabel *label,
+ gboolean wrap)
{
GtkLabelPrivate *priv = gtk_label_get_instance_private (label);
@@ -3151,16 +3151,16 @@ gtk_label_set_line_wrap (GtkLabel *label,
}
/**
- * gtk_label_get_line_wrap:
+ * gtk_label_get_wrap:
* @label: a #GtkLabel
*
- * Returns whether lines in the label are automatically wrapped.
- * See gtk_label_set_line_wrap().
+ * Returns whether lines in the label are automatically wrapped.
+ * See gtk_label_set_wrap().
*
* Returns: %TRUE if the lines of the label are automatically wrapped.
*/
gboolean
-gtk_label_get_line_wrap (GtkLabel *label)
+gtk_label_get_wrap (GtkLabel *label)
{
GtkLabelPrivate *priv = gtk_label_get_instance_private (label);
@@ -3170,17 +3170,17 @@ gtk_label_get_line_wrap (GtkLabel *label)
}
/**
- * gtk_label_set_line_wrap_mode:
+ * gtk_label_set_wrap_mode:
* @label: a #GtkLabel
* @wrap_mode: the line wrapping mode
*
- * If line wrapping is on (see gtk_label_set_line_wrap()) this controls how
+ * If line wrapping is on (see gtk_label_set_wrap()) this controls how
* the line wrapping is done. The default is %PANGO_WRAP_WORD which means
* wrap on word boundaries.
**/
void
-gtk_label_set_line_wrap_mode (GtkLabel *label,
- PangoWrapMode wrap_mode)
+gtk_label_set_wrap_mode (GtkLabel *label,
+ PangoWrapMode wrap_mode)
{
GtkLabelPrivate *priv = gtk_label_get_instance_private (label);
@@ -3196,15 +3196,15 @@ gtk_label_set_line_wrap_mode (GtkLabel *label,
}
/**
- * gtk_label_get_line_wrap_mode:
+ * gtk_label_get_wrap_mode:
* @label: a #GtkLabel
*
- * Returns line wrap mode used by the label. See gtk_label_set_line_wrap_mode().
+ * Returns line wrap mode used by the label. See gtk_label_set_wrap_mode().
*
* Returns: %TRUE if the lines of the label are automatically wrapped.
*/
PangoWrapMode
-gtk_label_get_line_wrap_mode (GtkLabel *label)
+gtk_label_get_wrap_mode (GtkLabel *label)
{
GtkLabelPrivate *priv = gtk_label_get_instance_private (label);
diff --git a/gtk/gtklabel.h b/gtk/gtklabel.h
index c2b8bfe8e4..2116d79b0e 100644
--- a/gtk/gtklabel.h
+++ b/gtk/gtklabel.h
@@ -118,15 +118,15 @@ GDK_AVAILABLE_IN_ALL
void gtk_label_set_pattern (GtkLabel *label,
const gchar *pattern);
GDK_AVAILABLE_IN_ALL
-void gtk_label_set_line_wrap (GtkLabel *label,
- gboolean wrap);
+void gtk_label_set_wrap (GtkLabel *label,
+ gboolean wrap);
GDK_AVAILABLE_IN_ALL
-gboolean gtk_label_get_line_wrap (GtkLabel *label);
+gboolean gtk_label_get_wrap (GtkLabel *label);
GDK_AVAILABLE_IN_ALL
-void gtk_label_set_line_wrap_mode (GtkLabel *label,
- PangoWrapMode wrap_mode);
+void gtk_label_set_wrap_mode (GtkLabel *label,
+ PangoWrapMode wrap_mode);
GDK_AVAILABLE_IN_ALL
-PangoWrapMode gtk_label_get_line_wrap_mode (GtkLabel *label);
+PangoWrapMode gtk_label_get_wrap_mode (GtkLabel *label);
GDK_AVAILABLE_IN_ALL
void gtk_label_set_selectable (GtkLabel *label,
gboolean setting);
diff --git a/gtk/gtkmountoperation.c b/gtk/gtkmountoperation.c
index 8ae9f76742..4ad02628ab 100644
--- a/gtk/gtkmountoperation.c
+++ b/gtk/gtkmountoperation.c
@@ -622,7 +622,7 @@ gtk_mount_operation_ask_password_do_gtk (GtkMountOperation *operation,
label = gtk_label_new (primary);
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (main_vbox), GTK_WIDGET (label));
g_free (primary);
attrs = pango_attr_list_new ();
@@ -635,7 +635,7 @@ gtk_mount_operation_ask_password_do_gtk (GtkMountOperation *operation,
label = gtk_label_new (secondary);
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (main_vbox), GTK_WIDGET (label));
}
diff --git a/gtk/gtkprintbackend.c b/gtk/gtkprintbackend.c
index 06be0798e6..cc2a733af1 100644
--- a/gtk/gtkprintbackend.c
+++ b/gtk/gtkprintbackend.c
@@ -677,7 +677,7 @@ request_password (GtkPrintBackend *backend,
label = gtk_label_new (NULL);
markup = g_markup_printf_escaped ("<span weight=\"bold\" size=\"large\">%s</span>", prompt);
gtk_label_set_markup (GTK_LABEL (label), markup);
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_widget_set_size_request (GTK_WIDGET (label), 320, -1);
g_free (markup);
diff --git a/tests/testadjustsize.c b/tests/testadjustsize.c
index 40e5e22cc2..7bcb86215f 100644
--- a/tests/testadjustsize.c
+++ b/tests/testadjustsize.c
@@ -46,7 +46,7 @@ create_label (gboolean wrap)
widget = gtk_label_new ("This is a label, label label label");
if (wrap)
- gtk_label_set_line_wrap (GTK_LABEL (widget), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (widget), TRUE);
return widget;
}
@@ -328,7 +328,7 @@ open_valigned_label_window (void)
gtk_container_add (GTK_CONTAINER (box), label);
label = gtk_label_new ("Some wrapping text with width-chars = 15 and max-width-chars = 35");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_width_chars (GTK_LABEL (label), 15);
gtk_label_set_max_width_chars (GTK_LABEL (label), 35);
diff --git a/tests/testcellarea.c b/tests/testcellarea.c
index 4f78f45475..e4d9f19cec 100644
--- a/tests/testcellarea.c
+++ b/tests/testcellarea.c
@@ -524,8 +524,8 @@ background_area (void)
label = gtk_label_new ("In this example, row spacing gets devided into the background area, "
"column spacing is added between each background area, item_padding is "
"prepended space distributed to the background area.");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
- gtk_label_set_width_chars (GTK_LABEL (label), 40);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_width_chars (GTK_LABEL (label), 40);
gtk_container_add (GTK_CONTAINER (main_vbox), label);
iconview = focus_iconview (TRUE, NULL, NULL);
diff --git a/tests/testclipboard2.c b/tests/testclipboard2.c
index 86c0e5dc3f..035afd6b1a 100644
--- a/tests/testclipboard2.c
+++ b/tests/testclipboard2.c
@@ -202,7 +202,7 @@ get_contents_widget (GdkClipboard *clipboard)
gtk_stack_add_titled (GTK_STACK (stack), child, "image", "Image");
child = gtk_label_new (NULL);
- gtk_label_set_line_wrap (GTK_LABEL (child), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (child), TRUE);
gtk_stack_add_titled (GTK_STACK (stack), child, "text", "Text");
return stack;
diff --git a/tests/testflowbox.c b/tests/testflowbox.c
index 980627a9ea..f1e8415aeb 100644
--- a/tests/testflowbox.c
+++ b/tests/testflowbox.c
@@ -147,8 +147,8 @@ populate_flowbox_wrappy (GtkFlowBox *flowbox)
gtk_container_add (GTK_CONTAINER (frame), widget);
- gtk_label_set_line_wrap (GTK_LABEL (widget), TRUE);
- gtk_label_set_line_wrap_mode (GTK_LABEL (widget), PANGO_WRAP_WORD);
+ gtk_label_set_wrap (GTK_LABEL (widget), TRUE);
+ gtk_label_set_wrap_mode (GTK_LABEL (widget), PANGO_WRAP_WORD);
gtk_label_set_width_chars (GTK_LABEL (widget), 10);
g_object_set_data_full (G_OBJECT (frame), "id", (gpointer)g_strdup (strings[i]), g_free);
diff --git a/tests/testgrid.c b/tests/testgrid.c
index a2f85666ac..4b63268895 100644
--- a/tests/testgrid.c
+++ b/tests/testgrid.c
@@ -114,7 +114,7 @@ text_grid (void)
label = gtk_label_new ("Some text that may wrap if it has to");
gtk_label_set_width_chars (GTK_LABEL (label), 10);
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
gtk_grid_attach (GTK_GRID (grid), test_widget ("1", "red"), 1, 0, 1, 1);
@@ -158,7 +158,7 @@ box_comparison (void)
gtk_container_add (GTK_CONTAINER (box), test_widget ("2", "green"));
label = gtk_label_new ("Some text that may wrap if needed");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_width_chars (GTK_LABEL (label), 10);
gtk_container_add (GTK_CONTAINER (box), label);
@@ -180,7 +180,7 @@ box_comparison (void)
gtk_grid_attach (GTK_GRID (grid), test_widget ("2", "green"), 2, 0, 1, 1);
label = gtk_label_new ("Some text that may wrap if needed");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_width_chars (GTK_LABEL (label), 10);
gtk_grid_attach (GTK_GRID (grid), label, 3, 0, 1, 1);
gtk_widget_set_hexpand (label, TRUE);
diff --git a/tests/testgtk.c b/tests/testgtk.c
index 3f6a5b17fb..ad78076865 100644
--- a/tests/testgtk.c
+++ b/tests/testgtk.c
@@ -1,4 +1,4 @@
-/* GTK - The GIMP Toolkit
+ /* GTK - The GIMP Toolkit
* Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
*
* This library is free software; you can redistribute it and/or
@@ -1023,7 +1023,7 @@ void create_labels (GtkWidget *widget)
" It supports multiple paragraphs correctly, and correctly adds "\
"many extra spaces. ");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (frame), label);
gtk_container_add (GTK_CONTAINER (vbox), frame);
@@ -1036,7 +1036,7 @@ void create_labels (GtkWidget *widget)
" This is another newer, longer, better paragraph. It is coming to an end, "\
"unfortunately.");
gtk_label_set_justify (GTK_LABEL (label), GTK_JUSTIFY_FILL);
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (frame), label);
gtk_container_add (GTK_CONTAINER (vbox), frame);
@@ -4916,7 +4916,7 @@ tracking_label (GtkWidget *window)
G_CONNECT_SWAPPED);
label = gtk_label_new ("<no window state events received>");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (hbox), label);
g_object_set_data (G_OBJECT (label), "title", (gpointer)gtk_window_get_title (GTK_WINDOW (window)));
diff --git a/tests/testscrolledwindow.c b/tests/testscrolledwindow.c
index 4bfbbcd8e7..417f172217 100644
--- a/tests/testscrolledwindow.c
+++ b/tests/testscrolledwindow.c
@@ -112,7 +112,7 @@ scrollable_policy (void)
"is enough height to fit the content vertically if the window were "
"to be allocated a width without a vscrollbar present");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_width_chars (GTK_LABEL (label), 40);
gtk_label_set_max_width_chars (GTK_LABEL (label), 100);
diff --git a/tests/testwindowsize.c b/tests/testwindowsize.c
index ef8a5ddc31..e5fb876906 100644
--- a/tests/testwindowsize.c
+++ b/tests/testwindowsize.c
@@ -49,7 +49,7 @@ show_dialog (void)
"mi eu ipsum vestibulum in venenatis enim commodo. "
"Vivamus non malesuada ligula.");
- gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
+ gtk_label_set_wrap (GTK_LABEL (label), TRUE);
gtk_label_set_width_chars (GTK_LABEL (label), width_chars);
gtk_label_set_max_width_chars (GTK_LABEL (label), max_width_chars);
gtk_window_set_default_size (GTK_WINDOW (dialog), default_width, default_height);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]