[vte] vteapp: Implement --border-width option
- From: Christian Persch <chpe src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte] vteapp: Implement --border-width option
- Date: Thu, 27 Mar 2014 18:47:36 +0000 (UTC)
commit c55062b704249adb67538385eae796289fc38004
Author: Christian Persch <chpe gnome org>
Date: Tue May 3 19:33:30 2011 +0200
vteapp: Implement --border-width option
This is to test the condition that the terminal isn't at (0,0) in its
containing widget.
Conflicts:
src/vteapp.c
src/vteapp.c | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
---
diff --git a/src/vteapp.c b/src/vteapp.c
index f1a2db1..8472b03 100644
--- a/src/vteapp.c
+++ b/src/vteapp.c
@@ -567,6 +567,7 @@ main(int argc, char **argv)
char *cursor_blink_mode_string = NULL;
char *cursor_shape_string = NULL;
char *scrollbar_policy_string = NULL;
+ char *border_width_string = NULL;
GdkRGBA fore, back, highlight, cursor, tint;
const GOptionEntry options[]={
{
@@ -710,6 +711,11 @@ main(int argc, char **argv)
G_OPTION_ARG_STRING, &pty_flags_string,
"PTY flags set from default|no-utmp|no-wtmp|no-lastlog|no-helper|no-fallback", NULL
},
+ {
+ "border-width", 0, 0,
+ G_OPTION_ARG_STRING, &border_width_string,
+ "Border with", "WIDTH"
+ },
{ NULL }
};
GOptionContext *context;
@@ -774,6 +780,13 @@ main(int argc, char **argv)
window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
gtk_container_set_resize_mode(GTK_CONTAINER(window),
GTK_RESIZE_IMMEDIATE);
+ if (border_width_string) {
+ guint w;
+
+ w = g_ascii_strtoull (border_width_string, NULL, 10);
+ gtk_container_set_border_width(GTK_CONTAINER(window), w);
+ g_free (border_width_string);
+ }
/* Set ARGB visual */
screen = gtk_widget_get_screen (window);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]