[gtranslator: 9/15] remove remaining uses of border-width
- From: Daniel Garcia Moreno <danigm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtranslator: 9/15] remove remaining uses of border-width
- Date: Mon, 28 Mar 2022 07:36:15 +0000 (UTC)
commit 11935f9c83175189c31096be9a8ce4230e675fc4
Author: Maximiliano Sandoval R <msandova gnome org>
Date: Wed Mar 16 11:49:40 2022 +0100
remove remaining uses of border-width
src/codeview/gtr-viewer.c | 5 ++++-
src/gtr-context.c | 5 ++++-
src/gtr-header-dialog.c | 12 +++++++++---
src/gtr-jump-dialog.c | 13 +++++++++----
src/gtr-preferences-dialog.c | 13 +++++++++----
src/gtr-profile-dialog.c | 8 +++++---
src/gtr-upload-dialog.c | 8 +++++---
7 files changed, 45 insertions(+), 19 deletions(-)
---
diff --git a/src/codeview/gtr-viewer.c b/src/codeview/gtr-viewer.c
index 58c67e5e..0382e74b 100644
--- a/src/codeview/gtr-viewer.c
+++ b/src/codeview/gtr-viewer.c
@@ -96,7 +96,10 @@ gtr_viewer_init (GtrViewer *dlg)
gtk_widget_set_vexpand (priv->main_box, TRUE);
gtk_box_append (content_area, priv->main_box);
- gtk_container_set_border_width (GTK_CONTAINER (priv->main_box), 5);
+ gtk_widget_set_margin_start (priv->main_box, 6);
+ gtk_widget_set_margin_end (priv->main_box, 6);
+ gtk_widget_set_margin_top (priv->main_box, 6);
+ gtk_widget_set_margin_bottom (priv->main_box, 6);
/* Source view */
priv->view = gtk_source_view_new ();
diff --git a/src/gtr-context.c b/src/gtr-context.c
index d3f36b65..4bc7a36b 100644
--- a/src/gtr-context.c
+++ b/src/gtr-context.c
@@ -124,7 +124,10 @@ setup_notes_edition (GtrContextPanel *panel)
gtk_container_add (GTK_CONTAINER (scrolled_window),
text_view);
- gtk_container_set_border_width (GTK_CONTAINER (scrolled_window), 5);
+ gtk_widget_set_margin_start (scrolled_window, 6);
+ gtk_widget_set_margin_end (scrolled_window, 6);
+ gtk_widget_set_margin_top (scrolled_window, 6);
+ gtk_widget_set_margin_bottom (scrolled_window, 6);
gtk_widget_set_vexpand (scrolled_window, TRUE);
gtk_box_append (dialog_area, scrolled_window);
diff --git a/src/gtr-header-dialog.c b/src/gtr-header-dialog.c
index 051a6a8a..2139a4bd 100644
--- a/src/gtr-header-dialog.c
+++ b/src/gtr-header-dialog.c
@@ -328,8 +328,11 @@ gtr_header_dialog_init (GtrHeaderDialog * dlg)
content_area = GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dlg)));
- gtk_container_set_border_width (GTK_CONTAINER (dlg), 5);
- gtk_box_set_spacing (content_area, 2);
+ gtk_widget_set_margin_start (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_end (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_top (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_bottom (GTK_WIDGET (dlg), 6);
+ gtk_box_set_spacing (content_area, 6);
g_signal_connect (dlg, "response", G_CALLBACK (gtk_widget_destroy), NULL);
@@ -364,7 +367,10 @@ gtr_header_dialog_init (GtrHeaderDialog * dlg)
gtk_box_append (content_area, priv->main_box);
- gtk_container_set_border_width (GTK_CONTAINER (priv->notebook), 5);
+ gtk_widget_set_margin_start (priv->notebook, 6);
+ gtk_widget_set_margin_end (priv->notebook, 6);
+ gtk_widget_set_margin_top (priv->notebook, 6);
+ gtk_widget_set_margin_bottom (priv->notebook, 6);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (priv->take_my_options),
g_settings_get_boolean (priv->settings,
diff --git a/src/gtr-jump-dialog.c b/src/gtr-jump-dialog.c
index d37864ae..4aa36630 100644
--- a/src/gtr-jump-dialog.c
+++ b/src/gtr-jump-dialog.c
@@ -96,9 +96,11 @@ gtr_jump_dialog_init (GtrJumpDialog * dlg)
content_area = GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dlg)));
- /* HIG defaults */
- gtk_container_set_border_width (GTK_CONTAINER (dlg), 5);
- gtk_box_set_spacing (content_area, 2); /* 2 * 5 + 2 = 12 */
+ gtk_widget_set_margin_start (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_end (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_top (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_bottom (GTK_WIDGET (dlg), 6);
+ gtk_box_set_spacing (content_area, 6);
gtk_dialog_set_default_response (GTK_DIALOG (dlg), GTK_RESPONSE_OK);
@@ -116,7 +118,10 @@ gtr_jump_dialog_init (GtrJumpDialog * dlg)
gtk_widget_set_vexpand (priv->main_box, TRUE);
gtk_box_append (content_area, priv->main_box);
- gtk_container_set_border_width (GTK_CONTAINER (priv->main_box), 5);
+ gtk_widget_set_margin_start (priv->main_box, 6);
+ gtk_widget_set_margin_end (priv->main_box, 6);
+ gtk_widget_set_margin_top (priv->main_box, 6);
+ gtk_widget_set_margin_bottom (priv->main_box, 6);
}
static void
diff --git a/src/gtr-preferences-dialog.c b/src/gtr-preferences-dialog.c
index ae0fa1db..584b1b34 100644
--- a/src/gtr-preferences-dialog.c
+++ b/src/gtr-preferences-dialog.c
@@ -656,9 +656,11 @@ gtr_preferences_dialog_init (GtrPreferencesDialog * dlg)
content_area = GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dlg)));
- /* HIG defaults */
- gtk_container_set_border_width (GTK_CONTAINER (dlg), 5);
- gtk_box_set_spacing (content_area, 2); /* 2 * 5 + 2 = 12 */
+ gtk_widget_set_margin_start (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_end (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_top (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_bottom (GTK_WIDGET (dlg), 6);
+ gtk_box_set_spacing (content_area, 6);
g_signal_connect (dlg,
"response", G_CALLBACK (dialog_response_handler), NULL);
@@ -688,7 +690,10 @@ gtr_preferences_dialog_init (GtrPreferencesDialog * dlg)
gtk_box_append (content_area, priv->notebook);
- gtk_container_set_border_width (GTK_CONTAINER (priv->notebook), 5);
+ gtk_widget_set_margin_start (priv->notebook, 6);
+ gtk_widget_set_margin_end (priv->notebook, 6);
+ gtk_widget_set_margin_top (priv->notebook, 6);
+ gtk_widget_set_margin_bottom (priv->notebook, 6);
context = gtk_widget_get_style_context (profiles_scrolled_window);
gtk_style_context_set_junction_sides (context, GTK_JUNCTION_BOTTOM);
diff --git a/src/gtr-profile-dialog.c b/src/gtr-profile-dialog.c
index 4fcdf040..5191e179 100644
--- a/src/gtr-profile-dialog.c
+++ b/src/gtr-profile-dialog.c
@@ -78,9 +78,11 @@ gtr_profile_dialog_init (GtrProfileDialog *dlg)
content_area = GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dlg)));
- /* HIG defaults */
- gtk_container_set_border_width (GTK_CONTAINER (dlg), 5);
- gtk_box_set_spacing (content_area, 2); /* 2 * 5 + 2 = 12 */
+ gtk_widget_set_margin_start (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_end (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_top (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_bottom (GTK_WIDGET (dlg), 6);
+ gtk_box_set_spacing (content_area, 6);
builder = gtk_builder_new ();
GError *error = NULL;
diff --git a/src/gtr-upload-dialog.c b/src/gtr-upload-dialog.c
index f2b46216..560eac05 100644
--- a/src/gtr-upload-dialog.c
+++ b/src/gtr-upload-dialog.c
@@ -67,9 +67,11 @@ gtr_upload_dialog_init (GtrUploadDialog *dlg)
content_area = GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dlg)));
- /* HIG defaults */
- gtk_container_set_border_width (GTK_CONTAINER (dlg), 5);
- gtk_box_set_spacing (content_area, 2); /* 2 * 5 + 2 = 12 */
+ gtk_widget_set_margin_start (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_end (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_top (GTK_WIDGET (dlg), 6);
+ gtk_widget_set_margin_bottom (GTK_WIDGET (dlg), 6);
+ gtk_box_set_spacing (content_area, 6);
builder = gtk_builder_new ();
GError *error = NULL;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]