diff options
-rw-r--r-- | config.vala | 2 | ||||
-rw-r--r-- | terminal.vala | 8 | ||||
-rw-r--r-- | weltschmerz.1 | 11 | ||||
-rw-r--r-- | weltschmerz.de.1 | 12 | ||||
-rw-r--r-- | weltschmerz.fi.1 | 11 |
5 files changed, 42 insertions, 2 deletions
diff --git a/config.vala b/config.vala index d972bac..fcbb7ed 100644 --- a/config.vala +++ b/config.vala @@ -13,6 +13,7 @@ class Config { public bool scrollbar; public bool allow_hyperlinks; public bool prefer_osc7; + public bool resize_hints; public Gdk.RGBA? foreground; public Gdk.RGBA? background; @@ -59,6 +60,7 @@ class Config { scrollbar = reader.read_boolean("misc", "scrollbar", true); allow_hyperlinks = reader.read_boolean("misc", "allow-hyperlinks", false); prefer_osc7 = reader.read_boolean("misc", "prefer-osc7", true); + resize_hints = reader.read_boolean("misc", "resize-hints", true); foreground = reader.read_colour("colours", "foreground", null); background = reader.read_colour("colours", "background", null); diff --git a/terminal.vala b/terminal.vala index 6dfe61e..e44889e 100644 --- a/terminal.vala +++ b/terminal.vala @@ -140,9 +140,13 @@ class Terminal : Gtk.Overlay { base_height = base_height, min_width = char_width * 28 + base_width, min_height = char_height * 3 + base_height, - width_inc = char_width, - height_inc = char_height }; + + if (conf.resize_hints) { + geometry.width_inc = char_width; + geometry.height_inc = char_height; + } + window.set_geometry_hints(null, geometry, BASE_SIZE | RESIZE_INC | MIN_SIZE); vte.set_allow_hyperlink(conf.allow_hyperlinks); diff --git a/weltschmerz.1 b/weltschmerz.1 index ed6e76a..487a2eb 100644 --- a/weltschmerz.1 +++ b/weltschmerz.1 @@ -199,6 +199,17 @@ only is used. The default is .Sy true . +.It Sy resize-hints +When set to +.Sy true , +.Nm +will pass geometry hints to the window manager indicating that resizing +should happen at multiples of the cell size. +When set to +.Sy false , +no such hints are passed, and resizing can happen freely. +The default is +.Sy true . .El .Pp The diff --git a/weltschmerz.de.1 b/weltschmerz.de.1 index e2e6d2a..3a8dec7 100644 --- a/weltschmerz.de.1 +++ b/weltschmerz.de.1 @@ -220,6 +220,18 @@ so wird lediglich herangezogen. Der Standardwert ist .Sy true . +.It Sy resize-hints +Ist der Wert +.Sy true , +zeigt +.Nm +dem Fenstermanager an, dass die Fenstergröße nur schrittweise um ein +Vielfaches der Zellgröße verändert werden sollte. +Ist der Wert +.Sy false , +so lässt sich das Fenster frei vergößern. +Der Standardwert ist +.Sy true . .El .Pp Die Schlüsselgruppe diff --git a/weltschmerz.fi.1 b/weltschmerz.fi.1 index e1b28e9..40bdfc0 100644 --- a/weltschmerz.fi.1 +++ b/weltschmerz.fi.1 @@ -211,6 +211,17 @@ Tämän ollessa käyttää vain proc-tiedostojärjestelmää. Oletusarvo on .Sy true . +.It Sy resize-hints +Tämän ollessa +.Sy true , +.Nm +pyytää geometriaehdotuksin ikkunanhallintaohjelmalta, että ikkunan kokoa +muutettaessa se porrastettaisiin merkkikennon koon moninkerraksi. +Tämän ollessa +.Sy false , +ikkuna voi olla minkä tahansa kokoinen. +Oletusarvo on +.Sy true . .El .Pp Ryhmä |