logo

badwolf

Minimalist and privacy-oriented WebKitGTK+ browser
commit: 25f7403ecc0f90d89eb87435d65dfca5b612672b
parent: c2c2d5af9eb5b821fc773784654321b7e3c5aef5
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Tue, 12 Mar 2019 05:13:25 +0100

Padding config on browser->{toolbar,box}

Diffstat:

Mbadwolf.c16++++++++--------
Mconfig.h9+++++++--
2 files changed, 15 insertions(+), 10 deletions(-)

diff --git a/badwolf.c b/badwolf.c @@ -324,14 +324,14 @@ new_browser(struct Window *window, gchar *target_url, WebKitWebView *related_web gtk_widget_set_tooltip_text(browser->close, "Close current tab"); gtk_widget_set_tooltip_text(browser->javascript, "Toggle javascript"); - gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->javascript), FALSE, FALSE, 0); - gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->location), TRUE, TRUE, 0); - gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->search), FALSE, FALSE, 0); - gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->close), FALSE, FALSE, 0); - - gtk_box_pack_start(GTK_BOX(browser->box), GTK_WIDGET(browser->toolbar), FALSE, FALSE, 0); - gtk_box_pack_start(GTK_BOX(browser->box), GTK_WIDGET(browser->webView), TRUE, TRUE, 0); - gtk_box_pack_start(GTK_BOX(browser->box), GTK_WIDGET(browser->statusbar), FALSE, FALSE, 0); + gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->javascript), FALSE, FALSE, BADWOLF_TOOLBAR_PADDING); + gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->location), TRUE, TRUE, BADWOLF_TOOLBAR_PADDING); + gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->search), FALSE, FALSE, BADWOLF_TOOLBAR_PADDING); + gtk_box_pack_start(GTK_BOX(browser->toolbar), GTK_WIDGET(browser->close), FALSE, FALSE, BADWOLF_TOOLBAR_PADDING); + + gtk_box_pack_start(GTK_BOX(browser->box), GTK_WIDGET(browser->toolbar), FALSE, FALSE, BADWOLF_BOX_PADDING); + gtk_box_pack_start(GTK_BOX(browser->box), GTK_WIDGET(browser->webView), TRUE, TRUE, BADWOLF_BOX_PADDING); + gtk_box_pack_start(GTK_BOX(browser->box), GTK_WIDGET(browser->statusbar), FALSE, FALSE, BADWOLF_BOX_PADDING); gtk_widget_set_halign(browser->statusbar, GTK_ALIGN_START); gtk_label_set_single_line_mode(GTK_LABEL(browser->statusbar), TRUE); diff --git a/config.h b/config.h @@ -6,4 +6,10 @@ * * See https://developer.gnome.org/gtk3/stable/gtk3-Standard-Enumerations.html#GtkPositionType */ -#define BADWOLF_TAB_POSITION GTK_POS_TOP- \ No newline at end of file +#define BADWOLF_TAB_POSITION GTK_POS_TOP + +// BADWOLF_BOX_PADDING: Amount of padding between browser’s box (tab child) elements +#define BADWOLF_BOX_PADDING 0 + +// BADWOLF_TOOLBAR_PADDING: Amount of padding between toolbar elements +#define BADWOLF_TOOLBAR_PADDING 0