diff --git a/config.c b/config.c index f06f626..5f6079c 100644 --- a/config.c +++ b/config.c @@ -110,6 +110,8 @@ config_load_default(zathura_t* zathura) girara_setting_add(gsession, "recolor", &bool_value, BOOLEAN, false, _("Recolor pages"), cb_setting_recolor_change, NULL); bool_value = false; girara_setting_add(gsession, "scroll-wrap", &bool_value, BOOLEAN, false, _("Wrap scrolling"), NULL, NULL); + bool_value = false; + girara_setting_add(gsession, "advance-pages-per-row", &bool_value, BOOLEAN, false, _("Advance number of pages per row"), NULL, NULL); float_value = 0.5; girara_setting_add(gsession, "highlight-transparency", &float_value, FLOAT, false, _("Transparency for highlighting"), NULL, NULL); bool_value = true; diff --git a/shortcuts.c b/shortcuts.c index be2a8a0..917303c 100644 --- a/shortcuts.c +++ b/shortcuts.c @@ -392,7 +392,15 @@ sc_navigate(girara_session_t* session, girara_argument_t* argument, bool scroll_wrap = false; girara_setting_get(session, "scroll-wrap", &scroll_wrap); - t = (t == 0) ? 1 : t; + bool columns_per_row_offset = false; + girara_setting_get(session, "advance-pages-per-row", &columns_per_row_offset); + + int offset = 1; + if (columns_per_row_offset == true) { + girara_setting_get(session, "pages-per-row", &offset); + } + + t = (t == 0) ? offset : t; if (argument->n == NEXT) { if (scroll_wrap == true) { new_page = new_page + t;