User Tools

Site Tools


This setup will make the uzbl window resize itself to fit the page size, to reduce the need for scrolling.

Add the following line in config.

@on_event LOAD_FINISH  set geometry = \@<+@scripts_dir/page-size.js>\@

Save the following as page-size.js in @scripts_dir.

// Customize the maximum and minimum window sizes here. `wmctrl -lG` may be of help.
var max = {Width: 1024, Height: 740};
var min = {Width: 0,    Height: 0  };
['Width', 'Height'].map(function (property) {
  return Math.max(Math.min(document.documentElement['scroll' + property], max[property]), min[property]);
fit-window.txt · Last modified: 2016/08/31 14:10 (external edit)