diff --git a/AUTHORS b/AUTHORS index c577e42..84d768e 100644 --- a/AUTHORS +++ b/AUTHORS @@ -17,3 +17,6 @@ Johannes Meng J. Commelin Julian Orth Roland Schatz +Abdó Roig-Maranges +Benoît Knecht +Rob Cornish diff --git a/Makefile b/Makefile index aa0fc6a..99628a7 100644 --- a/Makefile +++ b/Makefile @@ -78,8 +78,11 @@ clean: ${DOBJECTS} ${PROJECT}-debug .depend ${PROJECT}.pc doc version.h \ *gcda *gcno $(PROJECT).info gcov *.tmp \ girara-version-check - $(QUIET)make -C tests clean - $(QUIET)make -C po clean +ifneq "$(wildcard ${RSTTOMAN})" "" + $(QUIET)rm -f zathura.1 zathurarc.5 +endif + $(QUIET)$(MAKE) -C tests clean + $(QUIET)$(MAKE) -C po clean ${PROJECT}-debug: ${DOBJECTS} $(ECHO) CC -o $@ @@ -141,7 +144,8 @@ update-po: ifneq "$(wildcard ${RSTTOMAN})" "" %.1 %.5: config.mk $(QUIET)sed "s/VERSION/${VERSION}/g" < $@.rst > $@.tmp - $(QUIET)${RSTTOMAN} $@.tmp > $@ + $(QUIET)${RSTTOMAN} $@.tmp > $@.out.tmp + $(QUIET)mv $@.out.tmp $@ $(QUIET)rm $@.tmp ${PROJECT}.1: ${PROJECT}.1.rst diff --git a/README b/README index e9c441a..ce65be2 100644 --- a/README +++ b/README @@ -1,15 +1,16 @@ zathura - a document viewer --------------------- +=========================== zathura is a highly customizable and functional document viewer based on the girara user interface library and several document libraries. Requirements ------------ -gtk2 (>= 2.18.6) +gtk2 (>= 2.28) girara sqlite3 (>= 3.5.9) check (for tests) intltool +python-docutils (for man pages) Please note that you need to have a working pkg-config installation and that the Makefile is only compatible with GNU make. If you don't have a working diff --git a/bookmarks.c b/bookmarks.c index 78081e2..fc109d3 100644 --- a/bookmarks.c +++ b/bookmarks.c @@ -87,7 +87,8 @@ zathura_bookmark_free(zathura_bookmark_t* bookmark) } bool -zathura_bookmarks_load(zathura_t* zathura, const gchar* file) { +zathura_bookmarks_load(zathura_t* zathura, const gchar* file) +{ g_return_val_if_fail(zathura, false); g_return_val_if_fail(file, false); diff --git a/callbacks.c b/callbacks.c index 9e7d208..72fc348 100644 --- a/callbacks.c +++ b/callbacks.c @@ -58,20 +58,23 @@ cb_view_vadjustment_value_changed(GtkAdjustment* GIRARA_UNUSED(adjustment), gpoi GtkAdjustment* view_vadjustment = gtk_scrolled_window_get_vadjustment(GTK_SCROLLED_WINDOW(zathura->ui.session->gtk.view)); GtkAdjustment* view_hadjustment = gtk_scrolled_window_get_hadjustment(GTK_SCROLLED_WINDOW(zathura->ui.session->gtk.view)); - GdkRectangle view_rect; - /* get current adjustment values */ - view_rect.y = 0; - view_rect.height = gtk_adjustment_get_page_size(view_vadjustment); - view_rect.x = 0; - view_rect.width = gtk_adjustment_get_page_size(view_hadjustment); + /* current adjustment values */ + GdkRectangle view_rect = { + .x = 0, + .y = 0, + .width = gtk_adjustment_get_page_size(view_hadjustment), + .height = gtk_adjustment_get_page_size(view_vadjustment) + }; int page_padding = 1; girara_setting_get(zathura->ui.session, "page-padding", &page_padding); - GdkRectangle center; - center.x = (view_rect.width + 1) / 2; - center.y = (view_rect.height + 1) / 2; - center.height = center.width = (2 * page_padding) + 1; + GdkRectangle center = { + .x = (view_rect.width + 1) / 2, + .y = (view_rect.height + 1) / 2, + .width = (2 * page_padding) + 1, + .height = (2 * page_padding) + 1 + }; unsigned int number_of_pages = zathura_document_get_number_of_pages(zathura->document); double scale = zathura_document_get_scale(zathura->document); @@ -81,12 +84,13 @@ cb_view_vadjustment_value_changed(GtkAdjustment* GIRARA_UNUSED(adjustment), gpoi for (unsigned int page_id = 0; page_id < number_of_pages; page_id++) { zathura_page_t* page = zathura_document_get_page(zathura->document, page_id); - GdkRectangle page_rect; + GdkRectangle page_rect = { + .width = zathura_page_get_width(page) * scale, + .height = zathura_page_get_height(page) * scale + }; GtkWidget* page_widget = zathura_page_get_widget(zathura, page); gtk_widget_translate_coordinates(page_widget, - zathura->ui.session->gtk.view, 0, 0, &page_rect.x, &page_rect.y); - page_rect.width = zathura_page_get_width(page) * scale; - page_rect.height = zathura_page_get_height(page) * scale; + zathura->ui.session->gtk.view, 0, 0, &page_rect.x, &page_rect.y); if (gdk_rectangle_intersect(&view_rect, &page_rect, NULL) == TRUE) { zathura_page_set_visibility(page, true); @@ -156,7 +160,7 @@ cb_first_page_column_value_changed(girara_session_t* session, const char* UNUSED void cb_index_row_activated(GtkTreeView* tree_view, GtkTreePath* path, - GtkTreeViewColumn* UNUSED(column), void* data) + GtkTreeViewColumn* UNUSED(column), void* data) { zathura_t* zathura = data; if (tree_view == NULL || zathura == NULL || zathura->ui.session == NULL) { @@ -177,14 +181,24 @@ cb_index_row_activated(GtkTreeView* tree_view, GtkTreePath* path, } sc_toggle_index(zathura->ui.session, NULL, NULL, 0); + + /* zathura_jumplist_save is called when entering index mode */ zathura_link_evaluate(zathura, index_element->link); + zathura_jumplist_add(zathura); } g_object_unref(model); } -bool -cb_sc_follow(GtkEntry* entry, girara_session_t* session) +typedef enum zathura_link_action_e +{ + ZATHURA_LINK_ACTION_FOLLOW, + ZATHURA_LINK_ACTION_DISPLAY +} zathura_link_action_t; + +static bool +handle_link(GtkEntry* entry, girara_session_t* session, + zathura_link_action_t action) { g_return_val_if_fail(session != NULL, FALSE); g_return_val_if_fail(session->global.data != NULL, FALSE); @@ -221,9 +235,19 @@ cb_sc_follow(GtkEntry* entry, girara_session_t* session) if (eval == true) { zathura_link_t* link = zathura_page_widget_link_get(ZATHURA_PAGE(page_widget), index); + if (link != NULL) { - zathura_link_evaluate(zathura, link); invalid_index = false; + switch (action) { + case ZATHURA_LINK_ACTION_FOLLOW: + zathura_jumplist_save(zathura); + zathura_link_evaluate(zathura, link); + zathura_jumplist_add(zathura); + break; + case ZATHURA_LINK_ACTION_DISPLAY: + zathura_link_display(zathura, link); + break; + } } } } @@ -237,6 +261,18 @@ cb_sc_follow(GtkEntry* entry, girara_session_t* session) return (eval == TRUE) ? TRUE : FALSE; } +bool +cb_sc_follow(GtkEntry* entry, girara_session_t* session) +{ + return handle_link(entry, session, ZATHURA_LINK_ACTION_FOLLOW); +} + +bool +cb_sc_display_link(GtkEntry* entry, girara_session_t* session) +{ + return handle_link(entry, session, ZATHURA_LINK_ACTION_DISPLAY); +} + void cb_file_monitor(GFileMonitor* monitor, GFile* file, GFile* UNUSED(other_file), GFileMonitorEvent event, girara_session_t* session) { @@ -263,13 +299,13 @@ password_dialog(gpointer data) if (dialog != NULL) { girara_dialog( - dialog->zathura->ui.session, - "Incorrect password. Enter password:", - true, - NULL, - (girara_callback_inputbar_activate_t) cb_password_dialog, - dialog - ); + dialog->zathura->ui.session, + "Incorrect password. Enter password:", + true, + NULL, + (girara_callback_inputbar_activate_t) cb_password_dialog, + dialog + ); } return FALSE; @@ -317,8 +353,8 @@ cb_password_dialog(GtkEntry* entry, zathura_password_dialog_info_t* dialog) error_free: - g_free(dialog->path); - free(dialog); + g_free(dialog->path); + free(dialog); error_ret: @@ -349,7 +385,7 @@ cb_view_resized(GtkWidget* UNUSED(widget), GtkAllocation* allocation, zathura_t* void cb_setting_recolor_change(girara_session_t* session, const char* name, - girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) + girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) { g_return_if_fail(value != NULL); g_return_if_fail(session != NULL); @@ -367,7 +403,7 @@ cb_setting_recolor_change(girara_session_t* session, const char* name, void cb_setting_recolor_keep_hue_change(girara_session_t* session, const char* name, - girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) + girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) { g_return_if_fail(value != NULL); g_return_if_fail(session != NULL); @@ -404,7 +440,9 @@ cb_unknown_command(girara_session_t* session, const char* input) } } + zathura_jumplist_save(zathura); page_set(zathura, atoi(input) - 1); + zathura_jumplist_add(zathura); return true; } diff --git a/callbacks.h b/callbacks.h index 94feaec..4ce2e2e 100644 --- a/callbacks.h +++ b/callbacks.h @@ -80,6 +80,15 @@ void cb_index_row_activated(GtkTreeView* tree_view, GtkTreePath* path, */ bool cb_sc_follow(GtkEntry* entry, girara_session_t* session); +/** + * Called when input has been passed to the sc_display_link dialog + * + * @param entry The dialog inputbar + * @param session The girara session + * @return true if no error occured and the event has been handled + */ +bool cb_sc_display_link(GtkEntry* entry, girara_session_t* session); + /** * Emitted when file has been changed * diff --git a/commands.c b/commands.c index 5d568f7..b6ad942 100644 --- a/commands.c +++ b/commands.c @@ -165,15 +165,15 @@ cmd_info(girara_session_t* session, girara_list_t* UNUSED(argument_list)) GString* string = g_string_new(NULL); GIRARA_LIST_FOREACH(information, zathura_document_information_entry_t*, iter, entry) - if (entry != NULL) { - for (unsigned int i = 0; i < LENGTH(meta_fields); i++) { - if (meta_fields[i].field == entry->type) { - char* text = g_strdup_printf("%s: %s\n", meta_fields[i].name, entry->value); - g_string_append(string, text); - g_free(text); - } + if (entry != NULL) { + for (unsigned int i = 0; i < LENGTH(meta_fields); i++) { + if (meta_fields[i].field == entry->type) { + char* text = g_strdup_printf("%s: %s\n", meta_fields[i].name, entry->value); + g_string_append(string, text); + g_free(text); } } + } GIRARA_LIST_FOREACH_END(information, zathura_document_information_entry_t*, iter, entry); if (strlen(string->str) > 0) { @@ -190,7 +190,7 @@ cmd_info(girara_session_t* session, girara_list_t* UNUSED(argument_list)) bool cmd_help(girara_session_t* UNUSED(session), girara_list_t* - UNUSED(argument_list)) + UNUSED(argument_list)) { return true; } @@ -340,6 +340,8 @@ cmd_search(girara_session_t* session, const char* input, girara_argument_t* argu bool firsthit = true; zathura_error_t error = ZATHURA_ERROR_OK; + /* set search direction */ + zathura->global.search_direction = argument->n; unsigned int number_of_pages = zathura_document_get_number_of_pages(zathura->document); unsigned int current_page_number = zathura_document_get_current_page_number(zathura->document); @@ -363,7 +365,10 @@ cmd_search(girara_session_t* session, const char* input, girara_argument_t* argu GtkWidget* page_widget = zathura_page_get_widget(zathura, page); g_object_set(page_widget, "draw-links", FALSE, NULL); + render_lock(zathura->sync.render_thread); girara_list_t* result = zathura_page_search_text(page, input, &error); + render_unlock(zathura->sync.render_thread); + if (result == NULL || girara_list_size(result) == 0) { girara_list_free(result); g_object_set(page_widget, "search-results", NULL, NULL); @@ -380,7 +385,12 @@ cmd_search(girara_session_t* session, const char* input, girara_argument_t* argu if (page_id != 0) { page_set_delayed(zathura, zathura_page_get_index(page)); } - g_object_set(page_widget, "search-current", 0, NULL); + if (argument->n == BACKWARD) { + /* start at bottom hit in page */ + g_object_set(page_widget, "search-current", girara_list_size(result) - 1, NULL); + } else { + g_object_set(page_widget, "search-current", 0, NULL); + } firsthit = false; } } @@ -423,7 +433,7 @@ cmd_export(girara_session_t* session, girara_list_t* argument_list) } else { girara_notify(session, GIRARA_INFO, _("Wrote attachment '%s' to '%s'."), file_identifier, export_path); } - /* image */ + /* image */ } else if (strncmp(file_identifier, "image-p", strlen("image-p")) == 0 && strlen(file_identifier) >= 10) { /* parse page id */ const char* input = file_identifier + strlen("image-p"); @@ -476,7 +486,7 @@ image_error: girara_notify(session, GIRARA_ERROR, _("Unknown image '%s'."), file_identifier); goto error_ret; - /* unknown */ + /* unknown */ } else { girara_notify(session, GIRARA_ERROR, _("Unknown attachment or image '%s'."), file_identifier); } @@ -499,10 +509,10 @@ cmd_exec(girara_session_t* session, girara_list_t* argument_list) const char* path = zathura_document_get_path(zathura->document); GIRARA_LIST_FOREACH(argument_list, char*, iter, value) - char* r = NULL; - if ((r = replace_substring(value, "$FILE", path)) != NULL) { - girara_list_iterator_set(iter, r); - } + char* r = NULL; + if ((r = replace_substring(value, "$FILE", path)) != NULL) { + girara_list_iterator_set(iter, r); + } GIRARA_LIST_FOREACH_END(argument_list, char*, iter, value); } @@ -550,9 +560,9 @@ cmd_version(girara_session_t* session, girara_list_t* UNUSED(argument_list)) zathura_t* zathura = session->global.data; char* string = zathura_get_version_string(zathura, true); - if (string == NULL) { - return false; - } + if (string == NULL) { + return false; + } /* display information */ girara_notify(session, GIRARA_INFO, "%s", string); diff --git a/completion.c b/completion.c index 3fd0611..d558fd0 100644 --- a/completion.c +++ b/completion.c @@ -32,7 +32,7 @@ compare_case_insensitive(const char* str1, const char* str2) static girara_list_t* list_files(zathura_t* zathura, const char* current_path, const char* current_file, - unsigned int current_file_length, bool is_dir, bool check_file_ext) + unsigned int current_file_length, bool is_dir, bool check_file_ext) { if (zathura == NULL || zathura->ui.session == NULL || current_path == NULL) { return NULL; @@ -45,7 +45,7 @@ list_files(zathura_t* zathura, const char* current_path, const char* current_fil } girara_list_t* res = girara_sorted_list_new2((girara_compare_function_t)compare_case_insensitive, - (girara_free_function_t)g_free); + (girara_free_function_t)g_free); bool show_hidden = false; girara_setting_get(zathura->ui.session, "show-hidden", &show_hidden); @@ -179,7 +179,7 @@ list_files_for_cc(zathura_t* zathura, const char* input, bool check_file_ext) } GIRARA_LIST_FOREACH(names, const char*, iter, file) - girara_completion_group_add_element(group, file, NULL); + girara_completion_group_add_element(group, file, NULL); GIRARA_LIST_FOREACH_END(names, const char*, iter, file); girara_list_free(names); } @@ -246,11 +246,11 @@ cc_bookmarks(girara_session_t* session, const char* input) const size_t input_length = strlen(input); GIRARA_LIST_FOREACH(zathura->bookmarks.bookmarks, zathura_bookmark_t*, iter, bookmark) - if (input_length <= strlen(bookmark->id) && !strncmp(input, bookmark->id, input_length)) { - gchar* paged = g_strdup_printf(_("Page %d"), bookmark->page); - girara_completion_group_add_element(group, bookmark->id, paged); - g_free(paged); - } + if (input_length <= strlen(bookmark->id) && !strncmp(input, bookmark->id, input_length)) { + gchar* paged = g_strdup_printf(_("Page %d"), bookmark->page); + girara_completion_group_add_element(group, bookmark->id, paged); + g_free(paged); + } GIRARA_LIST_FOREACH_END(zathura->bookmarks.bookmarks, zathura_bookmark_t*, iter, bookmark); girara_completion_add_group(completion, group); @@ -302,12 +302,12 @@ cc_export(girara_session_t* session, const char* input) bool added = false; GIRARA_LIST_FOREACH(attachments, const char*, iter, attachment) - if (input_length <= strlen(attachment) && !strncmp(input, attachment, input_length)) { - char* attachment_string = g_strdup_printf("attachment-%s", attachment); - girara_completion_group_add_element(attachment_group, attachment_string, NULL); - g_free(attachment_string); - added = true; - } + if (input_length <= strlen(attachment) && !strncmp(input, attachment, input_length)) { + char* attachment_string = g_strdup_printf("attachment-%s", attachment); + girara_completion_group_add_element(attachment_group, attachment_string, NULL); + g_free(attachment_string); + added = true; + } GIRARA_LIST_FOREACH_END(zathura->bookmarks.bookmarks, zathura_bookmark_t*, iter, bookmark); if (added == true) { @@ -339,12 +339,12 @@ cc_export(girara_session_t* session, const char* input) if (images != NULL) { unsigned int image_number = 1; GIRARA_LIST_FOREACH(images, zathura_image_t*, iter, UNUSED(image)) - char* image_string = g_strdup_printf("image-p%d-%d", page_id + 1, image_number); - girara_completion_group_add_element(image_group, image_string, NULL); - g_free(image_string); + char* image_string = g_strdup_printf("image-p%d-%d", page_id + 1, image_number); + girara_completion_group_add_element(image_group, image_string, NULL); + g_free(image_string); - added = true; - image_number++; + added = true; + image_number++; GIRARA_LIST_FOREACH_END(images, zathura_image_t*, iter, image); girara_list_free(images); } diff --git a/config.c b/config.c index dbed831..1753594 100644 --- a/config.c +++ b/config.c @@ -18,9 +18,24 @@ #include #include +static void +cb_jumplist_change(girara_session_t* session, const char* name, + girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) +{ + g_return_if_fail(value != NULL); + g_return_if_fail(session != NULL); + g_return_if_fail(session->global.data != NULL); + g_return_if_fail(name != NULL); + zathura_t* zathura = session->global.data; + if (g_strcmp0(name, "jumplist-size") == 0) { + int* max_size = (int*) value; + zathura->jumplist.max_size = *max_size; + } +} + static void cb_color_change(girara_session_t* session, const char* name, - girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) + girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) { g_return_if_fail(value != NULL); g_return_if_fail(session != NULL); @@ -44,7 +59,7 @@ cb_color_change(girara_session_t* session, const char* name, static void cb_page_padding_changed(girara_session_t* session, const char* UNUSED(name), - girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) + girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) { g_return_if_fail(value != NULL); g_return_if_fail(session != NULL); @@ -65,7 +80,7 @@ cb_page_padding_changed(girara_session_t* session, const char* UNUSED(name), static void cb_nohlsearch_changed(girara_session_t* session, const char* UNUSED(name), - girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) + girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) { g_return_if_fail(value != NULL); g_return_if_fail(session != NULL); @@ -76,6 +91,20 @@ cb_nohlsearch_changed(girara_session_t* session, const char* UNUSED(name), render_all(zathura); } +static void +cb_incsearch_changed(girara_session_t* session, const char* UNUSED(name), + girara_setting_type_t UNUSED(type), void* value, void* UNUSED(data)) +{ + g_return_if_fail(value != NULL); + g_return_if_fail(session != NULL); + g_return_if_fail(session->global.data != NULL); + + bool inc_search = *(bool*) value; + girara_special_command_add(session, '/', cmd_search, inc_search, FORWARD, NULL); + girara_special_command_add(session, '?', cmd_search, inc_search, BACKWARD, NULL); +} + + void config_load_default(zathura_t* zathura) { @@ -86,6 +115,7 @@ config_load_default(zathura_t* zathura) int int_value = 0; float float_value = 0; bool bool_value = false; + bool inc_search = true; girara_session_t* gsession = zathura->ui.session; /* mode settings */ @@ -115,6 +145,8 @@ config_load_default(zathura_t* zathura) girara_setting_add(gsession, "scroll-step", &float_value, FLOAT, false, _("Scroll step"), NULL, NULL); float_value = -1; girara_setting_add(gsession, "scroll-hstep", &float_value, FLOAT, false, _("Horizontal scroll step"), NULL, NULL); + float_value = 0.0; + girara_setting_add(gsession, "scroll-full-overlap", &float_value, FLOAT, false, _("Full page scroll overlap"), NULL, NULL); int_value = 10; girara_setting_add(gsession, "zoom-min", &int_value, INT, false, _("Zoom minimum"), NULL, NULL); int_value = 1000; @@ -122,6 +154,8 @@ config_load_default(zathura_t* zathura) int_value = 20; girara_setting_add(gsession, "page-store-threshold", &int_value, INT, false, _("Life time (in seconds) of a hidden page"), NULL, NULL); girara_setting_add(gsession, "page-store-interval", &int_value, INT, true, _("Amount of seconds between each cache purge"), NULL, NULL); + int_value = 20; + girara_setting_add(gsession, "jumplist-size", &int_value, INT, false, _("Number of positions to remember in the jumplist"), cb_jumplist_change, NULL); girara_setting_add(gsession, "recolor-darkcolor", NULL, STRING, false, _("Recoloring (dark color)"), cb_color_change, NULL); girara_setting_set(gsession, "recolor-darkcolor", "#FFFFFF"); @@ -139,6 +173,8 @@ config_load_default(zathura_t* zathura) bool_value = false; girara_setting_add(gsession, "scroll-wrap", &bool_value, BOOLEAN, false, _("Wrap scrolling"), NULL, NULL); bool_value = false; + girara_setting_add(gsession, "scroll-page-aware", &bool_value, BOOLEAN, false, _("Page aware 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); bool_value = false; girara_setting_add(gsession, "zoom-center", &bool_value, BOOLEAN, false, _("Horizontally centered zoom"), NULL, NULL); @@ -157,6 +193,8 @@ config_load_default(zathura_t* zathura) girara_setting_add(gsession, "open-first-page", &bool_value, BOOLEAN, false, _("Always open on first page"), NULL, NULL); bool_value = false; girara_setting_add(gsession, "nohlsearch", &bool_value, BOOLEAN, false, _("Highlight search results"), cb_nohlsearch_changed, NULL); + inc_search = false; + girara_setting_add(gsession, "incremental-search", &inc_search, BOOLEAN, false, _("Enable incremental search"), cb_incsearch_changed, NULL); bool_value = true; girara_setting_add(gsession, "abort-clear-search", &bool_value, BOOLEAN, false, _("Clear search results on abort"), NULL, NULL); bool_value = false; @@ -171,6 +209,8 @@ config_load_default(zathura_t* zathura) girara_shortcut_add(gsession, 0, GDK_KEY_a, NULL, sc_adjust_window, NORMAL, ZATHURA_ADJUST_BESTFIT, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_s, NULL, sc_adjust_window, NORMAL, ZATHURA_ADJUST_WIDTH, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_F, NULL, sc_display_link, NORMAL, 0, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_slash, NULL, sc_focus_inputbar, NORMAL, 0, &("/")); girara_shortcut_add(gsession, GDK_SHIFT_MASK, GDK_KEY_slash, NULL, sc_focus_inputbar, NORMAL, 0, &("/")); girara_shortcut_add(gsession, 0, GDK_KEY_question, NULL, sc_focus_inputbar, NORMAL, 0, &("?")); @@ -195,13 +235,15 @@ config_load_default(zathura_t* zathura) girara_shortcut_add(gsession, 0, GDK_KEY_Page_Down, NULL, sc_navigate, NORMAL, NEXT, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_Page_Up, NULL, sc_navigate, NORMAL, PREVIOUS, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_J, NULL, sc_navigate, FULLSCREEN, NEXT, NULL); - girara_shortcut_add(gsession, 0, GDK_KEY_K, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); - girara_shortcut_add(gsession, 0, GDK_KEY_Left, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); - girara_shortcut_add(gsession, 0, GDK_KEY_Up, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_Down, NULL, sc_navigate, FULLSCREEN, NEXT, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_Right, NULL, sc_navigate, FULLSCREEN, NEXT, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_Page_Down, NULL, sc_navigate, FULLSCREEN, NEXT, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_space, NULL, sc_navigate, FULLSCREEN, NEXT, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_K, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_Left, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_Up, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_Page_Up, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); + girara_shortcut_add(gsession, GDK_SHIFT_MASK, GDK_KEY_space, NULL, sc_navigate, FULLSCREEN, PREVIOUS, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_k, NULL, sc_navigate_index, INDEX, UP, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_j, NULL, sc_navigate_index, INDEX, DOWN, NULL); @@ -218,7 +260,7 @@ config_load_default(zathura_t* zathura) girara_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_p, NULL, sc_print, NORMAL, 0, NULL); - girara_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_i, NULL, sc_recolor, NORMAL, 0, NULL); + girara_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_r, NULL, sc_recolor, NORMAL, 0, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_R, NULL, sc_reload, NORMAL, 0, NULL); @@ -242,6 +284,8 @@ config_load_default(zathura_t* zathura) girara_shortcut_add(gsession, 0, GDK_KEY_y, NULL, sc_scroll, NORMAL, FULL_RIGHT, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_space, NULL, sc_scroll, NORMAL, FULL_DOWN, NULL); girara_shortcut_add(gsession, GDK_SHIFT_MASK, GDK_KEY_space, NULL, sc_scroll, NORMAL, FULL_UP, NULL); + girara_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_o, NULL, sc_jumplist, NORMAL, BACKWARD, NULL); + girara_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_i, NULL, sc_jumplist, NORMAL, FORWARD, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_n, NULL, sc_search, NORMAL, FORWARD, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_N, NULL, sc_search, NORMAL, BACKWARD, NULL); @@ -252,15 +296,20 @@ config_load_default(zathura_t* zathura) girara_shortcut_add(gsession, 0, GDK_KEY_F5, NULL, sc_toggle_fullscreen, FULLSCREEN, 0, NULL); girara_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_n, NULL, girara_sc_toggle_statusbar, NORMAL, 0, NULL); girara_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_m, NULL, girara_sc_toggle_inputbar, NORMAL, 0, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_d, NULL, sc_toggle_page_mode, NORMAL, 0, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_q, NULL, sc_quit, NORMAL, 0, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_plus, NULL, sc_zoom, NORMAL, ZOOM_IN, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_KP_Add, NULL, sc_zoom, NORMAL, ZOOM_IN, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_plus, NULL, sc_zoom, FULLSCREEN, ZOOM_IN, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_KP_Add, NULL, sc_zoom, FULLSCREEN, ZOOM_IN, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_minus, NULL, sc_zoom, NORMAL, ZOOM_OUT, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_KP_Subtract,NULL, sc_zoom, NORMAL, ZOOM_OUT, NULL); girara_shortcut_add(gsession, 0, GDK_KEY_minus, NULL, sc_zoom, FULLSCREEN, ZOOM_OUT, NULL); - girara_shortcut_add(gsession, 0, GDK_KEY_equal, NULL, sc_zoom, NORMAL, ZOOM_ORIGINAL, NULL); - girara_shortcut_add(gsession, 0, GDK_KEY_equal, NULL, sc_zoom, FULLSCREEN, ZOOM_ORIGINAL, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_KP_Subtract,NULL, sc_zoom, FULLSCREEN, ZOOM_OUT, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_equal, NULL, sc_zoom, NORMAL, ZOOM_SPECIFIC, NULL); + girara_shortcut_add(gsession, 0, GDK_KEY_equal, NULL, sc_zoom, FULLSCREEN, ZOOM_SPECIFIC, NULL); girara_shortcut_add(gsession, 0, 0, "zi", sc_zoom, NORMAL, ZOOM_IN, NULL); girara_shortcut_add(gsession, 0, 0, "zi", sc_zoom, FULLSCREEN, ZOOM_IN, NULL); girara_shortcut_add(gsession, 0, 0, "zI", sc_zoom, NORMAL, ZOOM_IN, NULL); @@ -276,11 +325,28 @@ config_load_default(zathura_t* zathura) girara_shortcut_add(gsession, 0, 0, "zZ", sc_zoom, NORMAL, ZOOM_SPECIFIC, NULL); girara_shortcut_add(gsession, 0, 0, "zZ", sc_zoom, FULLSCREEN, ZOOM_SPECIFIC, NULL); + /* inputbar shortcuts */ + girara_inputbar_shortcut_add(gsession, 0, GDK_KEY_Escape, sc_abort, 0, NULL); + girara_inputbar_shortcut_add(gsession, GDK_CONTROL_MASK, GDK_KEY_c, sc_abort, 0, NULL); + /* mouse events */ - girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_UP, UP, NULL); - girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_UP, UP, NULL); - girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_DOWN, DOWN, NULL); - girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_DOWN, DOWN, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_UP, UP, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_UP, UP, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_DOWN, DOWN, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_DOWN, DOWN, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_LEFT, LEFT, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_LEFT, LEFT, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_RIGHT, RIGHT, NULL); + girara_mouse_event_add(gsession, 0, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_RIGHT, RIGHT, NULL); + + girara_mouse_event_add(gsession, 0, GIRARA_MOUSE_BUTTON1, sc_navigate, FULLSCREEN, GIRARA_EVENT_BUTTON_PRESS, NEXT, NULL); + girara_mouse_event_add(gsession, 0, GIRARA_MOUSE_BUTTON3, sc_navigate, FULLSCREEN, GIRARA_EVENT_BUTTON_PRESS, PREVIOUS, NULL); + + girara_mouse_event_add(gsession, GDK_SHIFT_MASK, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_UP, LEFT, NULL); + girara_mouse_event_add(gsession, GDK_SHIFT_MASK, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_UP, LEFT, NULL); + girara_mouse_event_add(gsession, GDK_SHIFT_MASK, 0, sc_mouse_scroll, NORMAL, GIRARA_EVENT_SCROLL_DOWN, RIGHT, NULL); + girara_mouse_event_add(gsession, GDK_SHIFT_MASK, 0, sc_mouse_scroll, FULLSCREEN, GIRARA_EVENT_SCROLL_DOWN, RIGHT, NULL); + girara_mouse_event_add(gsession, GDK_CONTROL_MASK, 0, sc_mouse_zoom, NORMAL, GIRARA_EVENT_SCROLL_UP, UP, NULL); girara_mouse_event_add(gsession, GDK_CONTROL_MASK, 0, sc_mouse_zoom, FULLSCREEN, GIRARA_EVENT_SCROLL_UP, UP, NULL); girara_mouse_event_add(gsession, GDK_CONTROL_MASK, 0, sc_mouse_zoom, NORMAL, GIRARA_EVENT_SCROLL_DOWN, DOWN, NULL); @@ -310,17 +376,20 @@ config_load_default(zathura_t* zathura) girara_inputbar_command_add(gsession, "hlsearch", NULL, cmd_hlsearch, NULL, _("Highlight current search results")); girara_inputbar_command_add(gsession, "version", NULL, cmd_version, NULL, _("Show version information")); - girara_special_command_add(gsession, '/', cmd_search, true, FORWARD, NULL); - girara_special_command_add(gsession, '?', cmd_search, true, BACKWARD, NULL); + girara_special_command_add(gsession, '/', cmd_search, inc_search, FORWARD, NULL); + girara_special_command_add(gsession, '?', cmd_search, inc_search, BACKWARD, NULL); /* add shortcut mappings */ girara_shortcut_mapping_add(gsession, "abort", sc_abort); girara_shortcut_mapping_add(gsession, "adjust_window", sc_adjust_window); girara_shortcut_mapping_add(gsession, "change_mode", sc_change_mode); + girara_shortcut_mapping_add(gsession, "display_link", sc_display_link); + girara_shortcut_mapping_add(gsession, "focus_inputbar", sc_focus_inputbar); girara_shortcut_mapping_add(gsession, "follow", sc_follow); girara_shortcut_mapping_add(gsession, "goto", sc_goto); - girara_shortcut_mapping_add(gsession, "navigate_index", sc_navigate_index); + girara_shortcut_mapping_add(gsession, "jumplist", sc_jumplist); girara_shortcut_mapping_add(gsession, "navigate", sc_navigate); + girara_shortcut_mapping_add(gsession, "navigate_index", sc_navigate_index); girara_shortcut_mapping_add(gsession, "print", sc_print); girara_shortcut_mapping_add(gsession, "quit", sc_quit); girara_shortcut_mapping_add(gsession, "recolor", sc_recolor); @@ -331,10 +400,12 @@ config_load_default(zathura_t* zathura) girara_shortcut_mapping_add(gsession, "toggle_fullscreen", sc_toggle_fullscreen); girara_shortcut_mapping_add(gsession, "toggle_index", sc_toggle_index); girara_shortcut_mapping_add(gsession, "toggle_inputbar", girara_sc_toggle_inputbar); + girara_shortcut_mapping_add(gsession, "toggle_page_mode", sc_toggle_page_mode); girara_shortcut_mapping_add(gsession, "toggle_statusbar", girara_sc_toggle_statusbar); girara_shortcut_mapping_add(gsession, "zoom", sc_zoom); /* add argument mappings */ + girara_argument_mapping_add(gsession, "backward", BACKWARD); girara_argument_mapping_add(gsession, "bottom", BOTTOM); girara_argument_mapping_add(gsession, "default", DEFAULT); girara_argument_mapping_add(gsession, "collapse", COLLAPSE); @@ -342,6 +413,7 @@ config_load_default(zathura_t* zathura) girara_argument_mapping_add(gsession, "down", DOWN); girara_argument_mapping_add(gsession, "expand", EXPAND); girara_argument_mapping_add(gsession, "expand-all", EXPAND_ALL); + girara_argument_mapping_add(gsession, "forward", FORWARD); girara_argument_mapping_add(gsession, "full-down", FULL_DOWN); girara_argument_mapping_add(gsession, "full-up", FULL_UP); girara_argument_mapping_add(gsession, "half-down", HALF_DOWN); diff --git a/config.mk b/config.mk index 705ebce..bd20747 100644 --- a/config.mk +++ b/config.mk @@ -3,7 +3,7 @@ ZATHURA_VERSION_MAJOR = 0 ZATHURA_VERSION_MINOR = 2 -ZATHURA_VERSION_REV = 1 +ZATHURA_VERSION_REV = 2 # If the API changes, the API version and the ABI version have to be bumped. ZATHURA_API_VERSION = 2 # If the ABI breaks for any reason, this has to be bumped. @@ -16,7 +16,7 @@ ZATHURA_GTK_VERSION ?= 2 # minimum required zathura version # If you want to disable the check, set GIRARA_VERSION_CHECK to 0. -GIRARA_MIN_VERSION = 0.1.4 +GIRARA_MIN_VERSION = 0.1.5 GIRARA_VERSION_CHECK ?= $(shell pkg-config --atleast-version=$(GIRARA_MIN_VERSION) girara-gtk${ZATHURA_GTK_VERSION}; echo $$?) # database diff --git a/database-plain.c b/database-plain.c index dfc8776..fcc0558 100644 --- a/database-plain.c +++ b/database-plain.c @@ -39,28 +39,28 @@ static void zathura_database_interface_init(ZathuraDatabaseInterface* iface); G_DEFINE_TYPE_WITH_CODE(ZathuraPlainDatabase, zathura_plaindatabase, G_TYPE_OBJECT, - G_IMPLEMENT_INTERFACE(ZATHURA_TYPE_DATABASE, zathura_database_interface_init)) + G_IMPLEMENT_INTERFACE(ZATHURA_TYPE_DATABASE, zathura_database_interface_init)) static void plain_finalize(GObject* object); static bool plain_add_bookmark(zathura_database_t* db, const char* file, - zathura_bookmark_t* bookmark); + zathura_bookmark_t* bookmark); static bool plain_remove_bookmark(zathura_database_t* db, const char* file, - const char* id); + const char* id); static girara_list_t* plain_load_bookmarks(zathura_database_t* db, const char* file); static bool plain_set_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info); + zathura_fileinfo_t* file_info); static bool plain_get_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info); + zathura_fileinfo_t* file_info); static void plain_set_property(GObject* object, guint prop_id, - const GValue* value, GParamSpec* pspec); + const GValue* value, GParamSpec* pspec); /* forward declaration */ static bool zathura_db_check_file(const char* path); static GKeyFile* zathura_db_read_key_file_from_file(const char* path); static void zathura_db_write_key_file_to_file(const char* file, GKeyFile* key_file); static void cb_zathura_db_watch_file(GFileMonitor* monitor, GFile* file, GFile* - other_file, GFileMonitorEvent event, zathura_database_t* database); + other_file, GFileMonitorEvent event, zathura_database_t* database); typedef struct zathura_plaindatabase_private_s { char* bookmark_path; @@ -75,8 +75,7 @@ typedef struct zathura_plaindatabase_private_s { #define ZATHURA_PLAINDATABASE_GET_PRIVATE(obj) \ (G_TYPE_INSTANCE_GET_PRIVATE ((obj), ZATHURA_TYPE_PLAINDATABASE, zathura_plaindatabase_private_t)) -enum -{ +enum { PROP_0, PROP_PATH }; @@ -118,8 +117,8 @@ zathura_plaindatabase_class_init(ZathuraPlainDatabaseClass* class) object_class->set_property = plain_set_property; g_object_class_install_property(object_class, PROP_PATH, - g_param_spec_string("path", "path", "path to directory where the bookmarks and history are locates", - NULL, G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); + g_param_spec_string("path", "path", "path to directory where the bookmarks and history are locates", + NULL, G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); } static void @@ -171,10 +170,10 @@ plain_db_init(ZathuraPlainDatabase* db, const char* dir) g_object_unref(bookmark_file); g_signal_connect( - G_OBJECT(priv->bookmark_monitor), - "changed", - G_CALLBACK(cb_zathura_db_watch_file), - db + G_OBJECT(priv->bookmark_monitor), + "changed", + G_CALLBACK(cb_zathura_db_watch_file), + db ); priv->bookmarks = zathura_db_read_key_file_from_file(priv->bookmark_path); @@ -198,10 +197,10 @@ plain_db_init(ZathuraPlainDatabase* db, const char* dir) g_object_unref(history_file); g_signal_connect( - G_OBJECT(priv->history_monitor), - "changed", - G_CALLBACK(cb_zathura_db_watch_file), - db + G_OBJECT(priv->history_monitor), + "changed", + G_CALLBACK(cb_zathura_db_watch_file), + db ); priv->history = zathura_db_read_key_file_from_file(priv->history_path); @@ -289,7 +288,7 @@ plain_finalize(GObject* object) static bool plain_add_bookmark(zathura_database_t* db, const char* file, - zathura_bookmark_t* bookmark) + zathura_bookmark_t* bookmark) { zathura_plaindatabase_private_t* priv = ZATHURA_PLAINDATABASE_GET_PRIVATE(db); if (priv->bookmarks == NULL || priv->bookmark_path == NULL || @@ -308,7 +307,7 @@ plain_add_bookmark(zathura_database_t* db, const char* file, static bool plain_remove_bookmark(zathura_database_t* db, const char* file, const char* - GIRARA_UNUSED(id)) + GIRARA_UNUSED(id)) { zathura_plaindatabase_private_t* priv = ZATHURA_PLAINDATABASE_GET_PRIVATE(db); if (priv->bookmarks == NULL || priv->bookmark_path == NULL) { @@ -344,8 +343,8 @@ plain_load_bookmarks(zathura_database_t* db, const char* file) } girara_list_t* result = girara_sorted_list_new2((girara_compare_function_t) - zathura_bookmarks_compare, (girara_free_function_t) - zathura_bookmark_free); + zathura_bookmarks_compare, (girara_free_function_t) + zathura_bookmark_free); gsize length; char** keys = g_key_file_get_keys(priv->bookmarks, name, &length, NULL); @@ -372,7 +371,7 @@ plain_load_bookmarks(zathura_database_t* db, const char* file) static bool plain_set_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* - file_info) + file_info) { zathura_plaindatabase_private_t* priv = ZATHURA_PLAINDATABASE_GET_PRIVATE(db); if (priv->history == NULL || file_info == NULL || file == NULL) { @@ -409,7 +408,7 @@ plain_set_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* static bool plain_get_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* - file_info) + file_info) { if (db == NULL || file == NULL || file_info == NULL) { return false; @@ -519,9 +518,9 @@ zathura_db_read_key_file_from_file(const char* path) GError* error = NULL; if (g_key_file_load_from_data(key_file, content, contentlen, - G_KEY_FILE_KEEP_COMMENTS | G_KEY_FILE_KEEP_TRANSLATIONS, &error) == + G_KEY_FILE_KEEP_COMMENTS | G_KEY_FILE_KEEP_TRANSLATIONS, &error) == FALSE) { - if (error->code != 1) /* ignore empty file */ { + if (error->code != 1) { /* ignore empty file */ free(content); g_key_file_free(key_file); g_error_free(error); @@ -568,7 +567,7 @@ zathura_db_write_key_file_to_file(const char* file, GKeyFile* key_file) static void cb_zathura_db_watch_file(GFileMonitor* UNUSED(monitor), GFile* file, GFile* UNUSED(other_file), - GFileMonitorEvent event, zathura_database_t* database) + GFileMonitorEvent event, zathura_database_t* database) { if (event != G_FILE_MONITOR_EVENT_CHANGES_DONE_HINT || database == NULL) { return; diff --git a/database-sqlite.c b/database-sqlite.c index 56969e2..a9f0a6d 100644 --- a/database-sqlite.c +++ b/database-sqlite.c @@ -10,21 +10,21 @@ static void zathura_database_interface_init(ZathuraDatabaseInterface* iface); G_DEFINE_TYPE_WITH_CODE(ZathuraSQLDatabase, zathura_sqldatabase, G_TYPE_OBJECT, - G_IMPLEMENT_INTERFACE(ZATHURA_TYPE_DATABASE, zathura_database_interface_init)) + G_IMPLEMENT_INTERFACE(ZATHURA_TYPE_DATABASE, zathura_database_interface_init)) static void sqlite_finalize(GObject* object); static bool sqlite_add_bookmark(zathura_database_t* db, const char* file, - zathura_bookmark_t* bookmark); + zathura_bookmark_t* bookmark); static bool sqlite_remove_bookmark(zathura_database_t* db, const char* file, - const char* id); + const char* id); static girara_list_t* sqlite_load_bookmarks(zathura_database_t* db, const char* file); static bool sqlite_set_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info); + zathura_fileinfo_t* file_info); static bool sqlite_get_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info); + zathura_fileinfo_t* file_info); static void sqlite_set_property(GObject* object, guint prop_id, - const GValue* value, GParamSpec* pspec); + const GValue* value, GParamSpec* pspec); typedef struct zathura_sqldatabase_private_s { sqlite3* session; @@ -33,8 +33,7 @@ typedef struct zathura_sqldatabase_private_s { #define ZATHURA_SQLDATABASE_GET_PRIVATE(obj) \ (G_TYPE_INSTANCE_GET_PRIVATE ((obj), ZATHURA_TYPE_SQLDATABASE, zathura_sqldatabase_private_t)) -enum -{ +enum { PROP_0, PROP_PATH }; @@ -62,7 +61,7 @@ zathura_sqldatabase_class_init(ZathuraSQLDatabaseClass* class) object_class->set_property = sqlite_set_property; g_object_class_install_property(object_class, PROP_PATH, - g_param_spec_string("path", "path", "path to the database", NULL, G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); + g_param_spec_string("path", "path", "path to the database", NULL, G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); } static void @@ -107,23 +106,23 @@ sqlite_db_init(ZathuraSQLDatabase* db, const char* path) /* create bookmarks database */ static const char SQL_BOOKMARK_INIT[] = "CREATE TABLE IF NOT EXISTS bookmarks (" - "file TEXT," - "id TEXT," - "page INTEGER," - "PRIMARY KEY(file, id));"; + "file TEXT," + "id TEXT," + "page INTEGER," + "PRIMARY KEY(file, id));"; static const char SQL_FILEINFO_INIT[] = "CREATE TABLE IF NOT EXISTS fileinfo (" - "file TEXT PRIMARY KEY," - "page INTEGER," - "offset INTEGER," - "scale FLOAT," - "rotation INTEGER," - "pages_per_row INTEGER," - "first_page_column INTEGER," - "position_x FLOAT," - "position_y FLOAT" - ");"; + "file TEXT PRIMARY KEY," + "page INTEGER," + "offset INTEGER," + "scale FLOAT," + "rotation INTEGER," + "pages_per_row INTEGER," + "first_page_column INTEGER," + "position_x FLOAT," + "position_y FLOAT" + ");"; static const char SQL_FILEINFO_ALTER[] = "ALTER TABLE fileinfo ADD COLUMN pages_per_row INTEGER;" @@ -211,7 +210,7 @@ prepare_statement(sqlite3* session, const char* statement) static bool sqlite_add_bookmark(zathura_database_t* db, const char* file, - zathura_bookmark_t* bookmark) + zathura_bookmark_t* bookmark) { zathura_sqldatabase_private_t* priv = ZATHURA_SQLDATABASE_GET_PRIVATE(db); @@ -239,7 +238,7 @@ sqlite_add_bookmark(zathura_database_t* db, const char* file, static bool sqlite_remove_bookmark(zathura_database_t* db, const char* file, const char* - id) + id) { zathura_sqldatabase_private_t* priv = ZATHURA_SQLDATABASE_GET_PRIVATE(db); @@ -284,7 +283,7 @@ sqlite_load_bookmarks(zathura_database_t* db, const char* file) } girara_list_t* result = girara_sorted_list_new2((girara_compare_function_t) zathura_bookmarks_compare, - (girara_free_function_t) zathura_bookmark_free); + (girara_free_function_t) zathura_bookmark_free); while (sqlite3_step(stmt) == SQLITE_ROW) { zathura_bookmark_t* bookmark = g_malloc0(sizeof(zathura_bookmark_t)); @@ -302,7 +301,7 @@ sqlite_load_bookmarks(zathura_database_t* db, const char* file) static bool sqlite_set_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info) + zathura_fileinfo_t* file_info) { if (db == NULL || file == NULL || file_info == NULL) { return false; @@ -340,7 +339,7 @@ sqlite_set_fileinfo(zathura_database_t* db, const char* file, static bool sqlite_get_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info) + zathura_fileinfo_t* file_info) { if (db == NULL || file == NULL || file_info == NULL) { return false; diff --git a/database.c b/database.c index 5d481e7..d042747 100644 --- a/database.c +++ b/database.c @@ -21,7 +21,7 @@ zathura_db_free(zathura_database_t* db) bool zathura_db_add_bookmark(zathura_database_t* db, const char* file, - zathura_bookmark_t* bookmark) + zathura_bookmark_t* bookmark) { g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && bookmark != NULL, false); @@ -30,7 +30,7 @@ zathura_db_add_bookmark(zathura_database_t* db, const char* file, bool zathura_db_remove_bookmark(zathura_database_t* db, const char* file, const char* - id) + id) { g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && id != NULL, false); @@ -45,9 +45,9 @@ zathura_db_load_bookmarks(zathura_database_t* db, const char* file) return ZATHURA_DATABASE_GET_INTERFACE(db)->load_bookmarks(db, file); } -bool +bool zathura_db_set_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info) + zathura_fileinfo_t* file_info) { g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && file_info != NULL, false); @@ -56,7 +56,7 @@ zathura_db_set_fileinfo(zathura_database_t* db, const char* file, bool zathura_db_get_fileinfo(zathura_database_t* db, const char* file, - zathura_fileinfo_t* file_info) + zathura_fileinfo_t* file_info) { g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && file_info != NULL, false); diff --git a/document.c b/document.c index 1dc6637..ae85aa9 100644 --- a/document.c +++ b/document.c @@ -36,8 +36,7 @@ static const gchar* guess_type(const char* path); /** * Document */ -struct zathura_document_s -{ +struct zathura_document_s { char* file_path; /**< File path of the document */ const char* password; /**< Password of the document */ unsigned int current_page_number; /**< Current page number */ @@ -62,7 +61,7 @@ struct zathura_document_s zathura_document_t* zathura_document_open(zathura_plugin_manager_t* plugin_manager, const char* - path, const char* password, zathura_error_t* error) + path, const char* password, zathura_error_t* error) { if (path == NULL) { return NULL; @@ -390,6 +389,34 @@ zathura_document_set_page_offset(zathura_document_t* document, unsigned int page } } +void +zathura_document_get_cell_size(zathura_document_t* document, + unsigned int* height, unsigned int* width) +{ + g_return_if_fail(document != NULL && height != NULL && width != NULL); + + unsigned int number_of_pages = + zathura_document_get_number_of_pages(document); + *width = 0; + *height = 0; + + /* Get the size of each cell of the table/grid, assuming it is homogeneous + * (i.e. each cell has the same dimensions. */ + for (unsigned int page_id = 0; page_id < number_of_pages; page_id++) { + zathura_page_t* page = zathura_document_get_page(document, page_id); + if (page == NULL) + continue; + + unsigned int page_width = 0, page_height = 0; + page_calc_height_width(page, &page_height, &page_width, true); + + if (*width < page_width) + *width = page_width; + if (*height < page_height) + *height = page_height; + } +} + zathura_error_t zathura_document_save_as(zathura_document_t* document, const char* path) { @@ -511,17 +538,18 @@ guess_type(const char* path) const int fd = fileno(f); guchar* content = NULL; size_t length = 0u; - while (uncertain == TRUE && length < GT_MAX_READ) { + ssize_t bytes_read = -1; + while (uncertain == TRUE && length < GT_MAX_READ && bytes_read != 0) { g_free((void*)content_type); content_type = NULL; content = g_realloc(content, length + BUFSIZ); - const ssize_t r = read(fd, content + length, BUFSIZ); - if (r == -1) { + bytes_read = read(fd, content + length, BUFSIZ); + if (bytes_read == -1) { break; } - length += r; + length += bytes_read; content_type = g_content_type_guess(NULL, content, length, &uncertain); girara_debug("new guess: %s uncertain: %d, read: %zu\n", content_type, uncertain, length); } diff --git a/document.h b/document.h index b72e4ac..113344e 100644 --- a/document.h +++ b/document.h @@ -93,7 +93,7 @@ void zathura_document_set_current_page_number(zathura_document_t* document, unsi * Returns the current scale value of the document * * @param document The document - * @return The current scale value + * @return The current scale value */ double zathura_document_get_scale(zathura_document_t* document); @@ -125,7 +125,7 @@ void zathura_document_set_rotation(zathura_document_t* document, unsigned int ro * Returns the adjust mode of the document * * @param document The document - * @return The adjust mode + * @return The adjust mode */ zathura_adjust_mode_t zathura_document_get_adjust_mode(zathura_document_t* document); @@ -169,6 +169,17 @@ void* zathura_document_get_data(zathura_document_t* document); */ void zathura_document_set_data(zathura_document_t* document, void* data); +/** + * Computes the size of a cell in the document's layout table, assuming that + * the table is homogeneous (i.e. every cell has the same dimensions). It takes + * the current scale into account. + * + * @param[in] document The document instance + * @param[out] height,width The computed height and width of the cell + */ +void zathura_document_get_cell_size(zathura_document_t* document, + unsigned int* height, unsigned int* width); + /** * Save the document * diff --git a/links.c b/links.c index a43e84f..0e2c400 100644 --- a/links.c +++ b/links.c @@ -10,8 +10,7 @@ #include "document.h" #include "utils.h" -struct zathura_link_s -{ +struct zathura_link_s { zathura_rectangle_t position; /**< Position of the link */ zathura_link_type_t type; /**< Link type */ zathura_link_target_t target; /**< Link target */ @@ -23,7 +22,7 @@ static void link_launch(zathura_t* zathura, zathura_link_t* link); zathura_link_t* zathura_link_new(zathura_link_type_t type, zathura_rectangle_t position, - zathura_link_target_t target) + zathura_link_target_t target) { zathura_link_t* link = g_malloc0(sizeof(zathura_link_t)); @@ -122,23 +121,25 @@ zathura_link_evaluate(zathura_t* zathura, zathura_link_t* link) switch (link->type) { case ZATHURA_LINK_GOTO_DEST: - switch (link->target.destination_type) { - case ZATHURA_LINK_DESTINATION_XYZ: { - if (link->target.scale != 0) { - zathura_document_set_scale(zathura->document, link->target.scale); - } + if (link->target.destination_type != ZATHURA_LINK_DESTINATION_UNKNOWN) { + if (link->target.scale != 0) { + zathura_document_set_scale(zathura->document, link->target.scale); + } - /* get page */ - zathura_page_t* page = zathura_document_get_page(zathura->document, - link->target.page_number); - if (page == NULL) { - return; - } + /* get page */ + zathura_page_t* page = zathura_document_get_page(zathura->document, + link->target.page_number); + if (page == NULL) { + return; + } - /* get page offset */ - page_offset_t offset; - page_calculate_offset(zathura, page, &offset); + zathura_document_set_current_page_number(zathura->document, link->target.page_number); + /* get page offset */ + page_offset_t offset; + page_calculate_offset(zathura, page, &offset); + + if (link->target.destination_type == ZATHURA_LINK_DESTINATION_XYZ) { if (link->target.left != -1) { offset.x += link->target.left * zathura_document_get_scale(zathura->document); } @@ -146,12 +147,10 @@ zathura_link_evaluate(zathura_t* zathura, zathura_link_t* link) if (link->target.top != -1) { offset.y += link->target.top * zathura_document_get_scale(zathura->document); } + } - position_set_delayed(zathura, offset.x, offset.y); - } - break; - default: - break; + position_set_delayed(zathura, offset.x, offset.y); + statusbar_page_number_update(zathura); } break; case ZATHURA_LINK_GOTO_REMOTE: @@ -170,6 +169,28 @@ zathura_link_evaluate(zathura_t* zathura, zathura_link_t* link) } } +void +zathura_link_display(zathura_t* zathura, zathura_link_t* link) +{ + zathura_link_type_t type = zathura_link_get_type(link); + zathura_link_target_t target = zathura_link_get_target(link); + switch (type) { + case ZATHURA_LINK_GOTO_DEST: + girara_notify(zathura->ui.session, GIRARA_INFO, _("Link: page %d"), + target.page_number); + break; + case ZATHURA_LINK_GOTO_REMOTE: + case ZATHURA_LINK_URI: + case ZATHURA_LINK_LAUNCH: + case ZATHURA_LINK_NAMED: + girara_notify(zathura->ui.session, GIRARA_INFO, _("Link: %s"), + target.value); + break; + default: + girara_notify(zathura->ui.session, GIRARA_ERROR, _("Link: Invalid")); + } +} + static void link_remote(zathura_t* zathura, const char* file) { diff --git a/links.h b/links.h index 3dbf8df..8d8728e 100644 --- a/links.h +++ b/links.h @@ -56,4 +56,12 @@ zathura_link_target_t zathura_link_get_target(zathura_link_t* link); */ void zathura_link_evaluate(zathura_t* zathura, zathura_link_t* link); +/** + * Display a link using girara_notify + * + * @param zathura Zathura instance + * @param link The link + */ +void zathura_link_display(zathura_t* zathura, zathura_link_t* link); + #endif // LINK_H diff --git a/main.c b/main.c index 86ea05b..0920adb 100644 --- a/main.c +++ b/main.c @@ -111,7 +111,7 @@ main(int argc, char* argv[]) } /* Enable/Disable synctex support */ - zathura_set_syntex(zathura, synctex); + zathura_set_synctex(zathura, synctex); /* Print version */ if (print_version == true) { diff --git a/marks.c b/marks.c index 84e67f2..d5e4d47 100644 --- a/marks.c +++ b/marks.c @@ -28,7 +28,7 @@ struct zathura_mark_s { bool sc_mark_add(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, FALSE); g_return_val_if_fail(session->gtk.view != NULL, FALSE); @@ -36,14 +36,14 @@ sc_mark_add(girara_session_t* session, girara_argument_t* UNUSED(argument), /* redirect signal handler */ g_signal_handler_disconnect(G_OBJECT(session->gtk.view), session->signals.view_key_pressed); session->signals.view_key_pressed = g_signal_connect(G_OBJECT(session->gtk.view), "key-press-event", - G_CALLBACK(cb_marks_view_key_press_event_add), session); + G_CALLBACK(cb_marks_view_key_press_event_add), session); return true; } bool sc_mark_evaluate(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, FALSE); g_return_val_if_fail(session->gtk.view != NULL, FALSE); @@ -51,14 +51,14 @@ sc_mark_evaluate(girara_session_t* session, girara_argument_t* UNUSED(argument), /* redirect signal handler */ g_signal_handler_disconnect(G_OBJECT(session->gtk.view), session->signals.view_key_pressed); session->signals.view_key_pressed = g_signal_connect(G_OBJECT(session->gtk.view), "key-press-event", - G_CALLBACK(cb_marks_view_key_press_event_evaluate), session); + G_CALLBACK(cb_marks_view_key_press_event_evaluate), session); return true; } bool cb_marks_view_key_press_event_add(GtkWidget* UNUSED(widget), GdkEventKey* event, - girara_session_t* session) + girara_session_t* session) { g_return_val_if_fail(session != NULL, FALSE); g_return_val_if_fail(session->gtk.view != NULL, FALSE); @@ -68,11 +68,11 @@ cb_marks_view_key_press_event_add(GtkWidget* UNUSED(widget), GdkEventKey* event, /* reset signal handler */ g_signal_handler_disconnect(G_OBJECT(session->gtk.view), session->signals.view_key_pressed); session->signals.view_key_pressed = g_signal_connect(G_OBJECT(session->gtk.view), "key-press-event", - G_CALLBACK(girara_callback_view_key_press_event), session); + G_CALLBACK(girara_callback_view_key_press_event), session); /* evaluate key */ if (((event->keyval >= 0x41 && event->keyval <= 0x5A) || (event->keyval >= - 0x61 && event->keyval <= 0x7A)) == false) { + 0x61 && event->keyval <= 0x7A)) == false) { return false; } @@ -92,11 +92,11 @@ bool cb_marks_view_key_press_event_evaluate(GtkWidget* UNUSED(widget), GdkEventK /* reset signal handler */ g_signal_handler_disconnect(G_OBJECT(session->gtk.view), session->signals.view_key_pressed); session->signals.view_key_pressed = g_signal_connect(G_OBJECT(session->gtk.view), "key-press-event", - G_CALLBACK(girara_callback_view_key_press_event), session); + G_CALLBACK(girara_callback_view_key_press_event), session); /* evaluate key */ if (((event->keyval >= 0x41 && event->keyval <= 0x5A) || (event->keyval >= - 0x61 && event->keyval <= 0x7A)) == false) { + 0x61 && event->keyval <= 0x7A)) == false) { return true; } @@ -129,7 +129,7 @@ cmd_marks_add(girara_session_t* session, girara_list_t* argument_list) char key = key_string[0]; if (((key >= 0x41 && key <= 0x5A) || (key >= - 0x61 && key <= 0x7A)) == false) { + 0x61 && key <= 0x7A)) == false) { return false; } @@ -154,32 +154,32 @@ cmd_marks_delete(girara_session_t* session, girara_list_t* argument_list) } GIRARA_LIST_FOREACH(argument_list, char*, iter, key_string) - if (key_string == NULL) { + if (key_string == NULL) { + continue; + } + + for (unsigned int i = 0; i < strlen(key_string); i++) { + char key = key_string[i]; + if (((key >= 0x41 && key <= 0x5A) || (key >= + 0x61 && key <= 0x7A)) == false) { continue; } - for (unsigned int i = 0; i < strlen(key_string); i++) { - char key = key_string[i]; - if (((key >= 0x41 && key <= 0x5A) || (key >= - 0x61 && key <= 0x7A)) == false) { + /* search for existing mark */ + girara_list_iterator_t* mark_iter = girara_list_iterator(zathura->global.marks); + do { + zathura_mark_t* mark = (zathura_mark_t*) girara_list_iterator_data(mark_iter); + if (mark == NULL) { continue; } - /* search for existing mark */ - girara_list_iterator_t* mark_iter = girara_list_iterator(zathura->global.marks); - do { - zathura_mark_t* mark = (zathura_mark_t*) girara_list_iterator_data(mark_iter); - if (mark == NULL) { - continue; - } - - if (mark->key == key) { - girara_list_remove(zathura->global.marks, mark); - continue; - } - } while (girara_list_iterator_next(mark_iter) != NULL); - girara_list_iterator_free(mark_iter); - } + if (mark->key == key) { + girara_list_remove(zathura->global.marks, mark); + continue; + } + } while (girara_list_iterator_next(mark_iter) != NULL); + girara_list_iterator_free(mark_iter); + } GIRARA_LIST_FOREACH_END(argument_list, char*, iter, key_string); return true; @@ -206,12 +206,12 @@ mark_add(zathura_t* zathura, int key) /* search for existing mark */ GIRARA_LIST_FOREACH(zathura->global.marks, zathura_mark_t*, iter, mark) - if (mark->key == key) { - mark->position_x = position_x; - mark->position_y = position_y; - mark->scale = scale; - return; - } + if (mark->key == key) { + mark->position_x = position_x; + mark->position_y = position_y; + mark->scale = scale; + return; + } GIRARA_LIST_FOREACH_END(zathura->global.marks, zathura_mark_t*, iter, mark); /* add new mark */ @@ -234,19 +234,19 @@ mark_evaluate(zathura_t* zathura, int key) /* search for existing mark */ GIRARA_LIST_FOREACH(zathura->global.marks, zathura_mark_t*, iter, mark) - if (mark != NULL && mark->key == key) { - double old_scale = zathura_document_get_scale(zathura->document); - zathura_document_set_scale(zathura->document, mark->scale); - readjust_view_after_zooming(zathura, old_scale, true); - render_all(zathura); + if (mark != NULL && mark->key == key) { + double old_scale = zathura_document_get_scale(zathura->document); + zathura_document_set_scale(zathura->document, mark->scale); + readjust_view_after_zooming(zathura, old_scale, true); + render_all(zathura); - position_set_delayed(zathura, mark->position_x, mark->position_y); + position_set_delayed(zathura, mark->position_x, mark->position_y); - cb_view_vadjustment_value_changed(NULL, zathura); + cb_view_vadjustment_value_changed(NULL, zathura); - zathura->global.update_page_number = true; - return; - } + zathura->global.update_page_number = true; + return; + } GIRARA_LIST_FOREACH_END(zathura->global.marks, zathura_mark_t*, iter, mark); } diff --git a/page-widget.c b/page-widget.c index 2f1f530..ac7e93d 100644 --- a/page-widget.c +++ b/page-widget.c @@ -74,8 +74,7 @@ static gboolean cb_zathura_page_widget_popup_menu(GtkWidget* widget); static void cb_menu_image_copy(GtkMenuItem* item, ZathuraPage* page); static void cb_menu_image_save(GtkMenuItem* item, ZathuraPage* page); -enum properties_e -{ +enum properties_e { PROP_0, PROP_PAGE, PROP_ZATHURA, @@ -115,25 +114,25 @@ zathura_page_widget_class_init(ZathuraPageClass* class) /* add properties */ g_object_class_install_property(object_class, PROP_PAGE, - g_param_spec_pointer("page", "page", "the page to draw", G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); + g_param_spec_pointer("page", "page", "the page to draw", G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); g_object_class_install_property(object_class, PROP_ZATHURA, - g_param_spec_pointer("zathura", "zathura", "the zathura instance", G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); + g_param_spec_pointer("zathura", "zathura", "the zathura instance", G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY)); g_object_class_install_property(object_class, PROP_DRAW_LINKS, - g_param_spec_boolean("draw-links", "draw-links", "Set to true if links should be drawn", FALSE, G_PARAM_WRITABLE)); + g_param_spec_boolean("draw-links", "draw-links", "Set to true if links should be drawn", FALSE, G_PARAM_WRITABLE)); g_object_class_install_property(object_class, PROP_LINKS_OFFSET, - g_param_spec_int("offset-links", "offset-links", "Offset for the link numbers", 0, INT_MAX, 0, G_PARAM_WRITABLE)); + g_param_spec_int("offset-links", "offset-links", "Offset for the link numbers", 0, INT_MAX, 0, G_PARAM_WRITABLE)); g_object_class_install_property(object_class, PROP_LINKS_NUMBER, - g_param_spec_int("number-of-links", "number-of-links", "Number of links", 0, INT_MAX, 0, G_PARAM_READABLE)); + g_param_spec_int("number-of-links", "number-of-links", "Number of links", 0, INT_MAX, 0, G_PARAM_READABLE)); g_object_class_install_property(object_class, PROP_SEARCH_RESULTS, - g_param_spec_pointer("search-results", "search-results", "Set to the list of search results", G_PARAM_WRITABLE | G_PARAM_READABLE)); + g_param_spec_pointer("search-results", "search-results", "Set to the list of search results", G_PARAM_WRITABLE | G_PARAM_READABLE)); g_object_class_install_property(object_class, PROP_SEARCH_RESULTS_CURRENT, - g_param_spec_int("search-current", "search-current", "The current search result", -1, INT_MAX, 0, G_PARAM_WRITABLE | G_PARAM_READABLE)); + g_param_spec_int("search-current", "search-current", "The current search result", -1, INT_MAX, 0, G_PARAM_WRITABLE | G_PARAM_READABLE)); g_object_class_install_property(object_class, PROP_SEARCH_RESULTS_LENGTH, - g_param_spec_int("search-length", "search-length", "The number of search results", -1, INT_MAX, 0, G_PARAM_READABLE)); + g_param_spec_int("search-length", "search-length", "The number of search results", -1, INT_MAX, 0, G_PARAM_READABLE)); g_object_class_install_property(object_class, PROP_DRAW_SEACH_RESULTS, - g_param_spec_boolean("draw-search-results", "draw-search-results", "Set to true if search results should be drawn", FALSE, G_PARAM_WRITABLE)); + g_param_spec_boolean("draw-search-results", "draw-search-results", "Set to true if search results should be drawn", FALSE, G_PARAM_WRITABLE)); g_object_class_install_property(object_class, PROP_LAST_VIEW, - g_param_spec_int("last-view", "last-view", "Last time the page has been viewed", -1, INT_MAX, 0, G_PARAM_READABLE)); + g_param_spec_int("last-view", "last-view", "Last time the page has been viewed", -1, INT_MAX, 0, G_PARAM_READABLE)); } static void @@ -167,7 +166,7 @@ zathura_page_widget_init(ZathuraPage* widget) /* we want mouse events */ gtk_widget_add_events(GTK_WIDGET(widget), - GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_POINTER_MOTION_MASK); + GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_POINTER_MOTION_MASK); } GtkWidget* @@ -225,10 +224,10 @@ zathura_page_widget_set_property(GObject* object, guint prop_id, const GValue* v if (priv->links.retrieved == true && priv->links.list != NULL) { GIRARA_LIST_FOREACH(priv->links.list, zathura_link_t*, iter, link) - if (link != NULL) { - zathura_rectangle_t rectangle = recalc_rectangle(priv->page, zathura_link_get_position(link)); - redraw_rect(pageview, &rectangle); - } + if (link != NULL) { + zathura_rectangle_t rectangle = recalc_rectangle(priv->page, zathura_link_get_position(link)); + redraw_rect(pageview, &rectangle); + } GIRARA_LIST_FOREACH_END(priv->links.list, zathura_link_t*, iter, link); } break; @@ -381,24 +380,24 @@ zathura_page_widget_draw(GtkWidget* widget, cairo_t* cairo) if (priv->links.draw == true && priv->links.n != 0) { unsigned int link_counter = 0; GIRARA_LIST_FOREACH(priv->links.list, zathura_link_t*, iter, link) - if (link != NULL) { - zathura_rectangle_t rectangle = recalc_rectangle(priv->page, zathura_link_get_position(link)); + if (link != NULL) { + zathura_rectangle_t rectangle = recalc_rectangle(priv->page, zathura_link_get_position(link)); - /* draw position */ - GdkColor color = priv->zathura->ui.colors.highlight_color; - cairo_set_source_rgba(cairo, color.red/65535.0, color.green/65535.0, color.blue/65535.0, transparency); - cairo_rectangle(cairo, rectangle.x1, rectangle.y1, - (rectangle.x2 - rectangle.x1), (rectangle.y2 - rectangle.y1)); - cairo_fill(cairo); + /* draw position */ + GdkColor color = priv->zathura->ui.colors.highlight_color; + cairo_set_source_rgba(cairo, color.red/65535.0, color.green/65535.0, color.blue/65535.0, transparency); + cairo_rectangle(cairo, rectangle.x1, rectangle.y1, + (rectangle.x2 - rectangle.x1), (rectangle.y2 - rectangle.y1)); + cairo_fill(cairo); - /* draw text */ - cairo_set_source_rgba(cairo, 0, 0, 0, 1); - cairo_set_font_size(cairo, 10); - cairo_move_to(cairo, rectangle.x1 + 1, rectangle.y2 - 1); - char* link_number = g_strdup_printf("%i", priv->links.offset + ++link_counter); - cairo_show_text(cairo, link_number); - g_free(link_number); - } + /* draw text */ + cairo_set_source_rgba(cairo, 0, 0, 0, 1); + cairo_set_font_size(cairo, 10); + cairo_move_to(cairo, rectangle.x1 + 1, rectangle.y2 - 1); + char* link_number = g_strdup_printf("%i", priv->links.offset + ++link_counter); + cairo_show_text(cairo, link_number); + g_free(link_number); + } GIRARA_LIST_FOREACH_END(priv->links.list, zathura_link_t*, iter, link); } @@ -406,20 +405,20 @@ zathura_page_widget_draw(GtkWidget* widget, cairo_t* cairo) if (priv->search.list != NULL && priv->search.draw == true) { int idx = 0; GIRARA_LIST_FOREACH(priv->search.list, zathura_rectangle_t*, iter, rect) - zathura_rectangle_t rectangle = recalc_rectangle(priv->page, *rect); + zathura_rectangle_t rectangle = recalc_rectangle(priv->page, *rect); - /* draw position */ - if (idx == priv->search.current) { - GdkColor color = priv->zathura->ui.colors.highlight_color_active; - cairo_set_source_rgba(cairo, color.red/65535.0, color.green/65535.0, color.blue/65535.0, transparency); - } else { - GdkColor color = priv->zathura->ui.colors.highlight_color; - cairo_set_source_rgba(cairo, color.red/65535.0, color.green/65535.0, color.blue/65535.0, transparency); - } - cairo_rectangle(cairo, rectangle.x1, rectangle.y1, - (rectangle.x2 - rectangle.x1), (rectangle.y2 - rectangle.y1)); - cairo_fill(cairo); - ++idx; + /* draw position */ + if (idx == priv->search.current) { + GdkColor color = priv->zathura->ui.colors.highlight_color_active; + cairo_set_source_rgba(cairo, color.red/65535.0, color.green/65535.0, color.blue/65535.0, transparency); + } else { + GdkColor color = priv->zathura->ui.colors.highlight_color; + cairo_set_source_rgba(cairo, color.red/65535.0, color.green/65535.0, color.blue/65535.0, transparency); + } + cairo_rectangle(cairo, rectangle.x1, rectangle.y1, + (rectangle.x2 - rectangle.x1), (rectangle.y2 - rectangle.y1)); + cairo_fill(cairo); + ++idx; GIRARA_LIST_FOREACH_END(priv->search.list, zathura_rectangle_t*, iter, rect); } /* draw selection */ @@ -427,7 +426,7 @@ zathura_page_widget_draw(GtkWidget* widget, cairo_t* cairo) GdkColor color = priv->zathura->ui.colors.highlight_color; cairo_set_source_rgba(cairo, color.red/65535.0, color.green/65535.0, color.blue/65535.0, transparency); cairo_rectangle(cairo, priv->mouse.selection.x1, priv->mouse.selection.y1, - (priv->mouse.selection.x2 - priv->mouse.selection.x1), (priv->mouse.selection.y2 - priv->mouse.selection.y1)); + (priv->mouse.selection.x2 - priv->mouse.selection.x1), (priv->mouse.selection.y2 - priv->mouse.selection.y1)); cairo_fill(cairo); } } else { @@ -503,12 +502,12 @@ zathura_page_widget_size_allocate(GtkWidget* widget, GdkRectangle* allocation) static void redraw_rect(ZathuraPage* widget, zathura_rectangle_t* rectangle) { - /* cause the rect to be drawn */ + /* cause the rect to be drawn */ GdkRectangle grect; grect.x = rectangle->x1; grect.y = rectangle->y1; - grect.width = rectangle->x2 - rectangle->x1; - grect.height = rectangle->y2 - rectangle->y1; + grect.width = (rectangle->x2 + 1) - rectangle->x1; + grect.height = (rectangle->y2 + 1) - rectangle->y1; #if (GTK_MAJOR_VERSION == 3) gtk_widget_queue_draw_area(GTK_WIDGET(widget), grect.x, grect.y, grect.width, grect.height); #else @@ -522,8 +521,8 @@ redraw_all_rects(ZathuraPage* widget, girara_list_t* rectangles) zathura_page_widget_private_t* priv = ZATHURA_PAGE_GET_PRIVATE(widget); GIRARA_LIST_FOREACH(rectangles, zathura_rectangle_t*, iter, rect) - zathura_rectangle_t rectangle = recalc_rectangle(priv->page, *rect); - redraw_rect(widget, &rectangle); + zathura_rectangle_t rectangle = recalc_rectangle(priv->page, *rect); + redraw_rect(widget, &rectangle); GIRARA_LIST_FOREACH_END(rectangles, zathura_recantgle_t*, iter, rect); } @@ -550,6 +549,10 @@ cb_zathura_page_widget_button_press_event(GtkWidget* widget, GdkEventButton* but zathura_page_widget_private_t* priv = ZATHURA_PAGE_GET_PRIVATE(widget); + if (girara_callback_view_button_press_event(widget, button, priv->zathura->ui.session) == true) { + return true; + } + if (button->button == 1) { /* left click */ if (button->type == GDK_BUTTON_PRESS) { /* start the selection */ @@ -603,11 +606,11 @@ cb_zathura_page_widget_button_release_event(GtkWidget* widget, GdkEventButton* b if (priv->links.list != NULL && priv->links.n > 0) { GIRARA_LIST_FOREACH(priv->links.list, zathura_link_t*, iter, link) - zathura_rectangle_t rect = recalc_rectangle(priv->page, zathura_link_get_position(link)); - if (rect.x1 <= button->x && rect.x2 >= button->x - && rect.y1 <= button->y && rect.y2 >= button->y) { - zathura_link_evaluate(priv->zathura, link); - } + zathura_rectangle_t rect = recalc_rectangle(priv->page, zathura_link_get_position(link)); + if (rect.x1 <= button->x && rect.x2 >= button->x + && rect.y1 <= button->y && rect.y2 >= button->y) { + zathura_link_evaluate(priv->zathura, link); + } GIRARA_LIST_FOREACH_END(priv->links.list, zathura_link_t*, iter, link); } } else { @@ -717,10 +720,10 @@ zathura_page_widget_popup_menu(GtkWidget* widget, GdkEventButton* event) /* search for underlaying image */ zathura_image_t* image = NULL; GIRARA_LIST_FOREACH(priv->images.list, zathura_image_t*, iter, image_it) - zathura_rectangle_t rect = recalc_rectangle(priv->page, image_it->position); - if (rect.x1 <= event->x && rect.x2 >= event->x && rect.y1 <= event->y && rect.y2 >= event->y) { - image = image_it; - } + zathura_rectangle_t rect = recalc_rectangle(priv->page, image_it->position); + if (rect.x1 <= event->x && rect.x2 >= event->x && rect.y1 <= event->y && rect.y2 >= event->y) { + image = image_it; + } GIRARA_LIST_FOREACH_END(priv->images.list, zathura_image_t*, iter, image_it); if (image == NULL) { @@ -795,7 +798,7 @@ cb_menu_image_copy(GtkMenuItem* item, ZathuraPage* page) cairo_destroy(cairo); GdkPixbuf* pixbuf = gdk_pixbuf_get_from_drawable(NULL, pixmap, NULL, 0, 0, 0, - 0, width, height); + 0, width, height); gtk_clipboard_set_image(gtk_clipboard_get(GDK_SELECTION_CLIPBOARD), pixbuf); gtk_clipboard_set_image(gtk_clipboard_get(GDK_SELECTION_PRIMARY), pixbuf); @@ -819,11 +822,11 @@ cb_menu_image_save(GtkMenuItem* item, ZathuraPage* page) unsigned int image_id = 1; GIRARA_LIST_FOREACH(priv->images.list, zathura_image_t*, iter, image_it) - if (image_it == priv->images.current) { - break; - } + if (image_it == priv->images.current) { + break; + } - image_id++; + image_id++; GIRARA_LIST_FOREACH_END(priv->images.list, zathura_image_t*, iter, image_it); /* set command */ diff --git a/plugin.c b/plugin.c index 870b796..91433e7 100644 --- a/plugin.c +++ b/plugin.c @@ -14,8 +14,7 @@ /** * Document plugin structure */ -struct zathura_plugin_s -{ +struct zathura_plugin_s { girara_list_t* content_types; /**< List of supported content types */ zathura_plugin_register_function_t register_function; /**< Document open function */ zathura_plugin_functions_t functions; /**< Document functions */ @@ -28,8 +27,7 @@ struct zathura_plugin_s /** * Plugin mapping */ -typedef struct zathura_type_plugin_mapping_s -{ +typedef struct zathura_type_plugin_mapping_s { const gchar* type; /**< Plugin type */ zathura_plugin_t* plugin; /**< Mapped plugin */ } zathura_type_plugin_mapping_t; @@ -37,8 +35,7 @@ typedef struct zathura_type_plugin_mapping_s /** * Plugin manager */ -struct zathura_plugin_manager_s -{ +struct zathura_plugin_manager_s { girara_list_t* plugins; /**< List of plugins */ girara_list_t* path; /**< List of plugin paths */ girara_list_t* type_plugin_mapping; /**< List of type -> plugin mappings */ @@ -91,120 +88,117 @@ zathura_plugin_manager_load(zathura_plugin_manager_t* plugin_manager) } GIRARA_LIST_FOREACH(plugin_manager->path, char*, iter, plugindir) - /* read all files in the plugin directory */ - GDir* dir = g_dir_open(plugindir, 0, NULL); - if (dir == NULL) { - girara_error("could not open plugin directory: %s", plugindir); - girara_list_iterator_next(iter); + /* read all files in the plugin directory */ + GDir* dir = g_dir_open(plugindir, 0, NULL); + if (dir == NULL) { + girara_error("could not open plugin directory: %s", plugindir); + girara_list_iterator_next(iter); + continue; + } + + char* name = NULL; + while ((name = (char*) g_dir_read_name(dir)) != NULL) { + char* path = g_build_filename(plugindir, name, NULL); + if (g_file_test(path, G_FILE_TEST_IS_REGULAR) == 0) { + girara_debug("%s is not a regular file. Skipping.", path); + g_free(path); continue; } - char* name = NULL; - while ((name = (char*) g_dir_read_name(dir)) != NULL) { - char* path = g_build_filename(plugindir, name, NULL); - if (g_file_test(path, G_FILE_TEST_IS_REGULAR) == 0) { - girara_info("%s is not a regular file. Skipping.", path); - g_free(path); - continue; - } + zathura_plugin_t* plugin = NULL; - zathura_plugin_t* plugin = NULL; + /* load plugin */ + GModule* handle = g_module_open(path, G_MODULE_BIND_LOCAL); + if (handle == NULL) { + girara_error("could not load plugin %s (%s)", path, g_module_error()); + g_free(path); + continue; + } - /* load plugin */ - GModule* handle = g_module_open(path, G_MODULE_BIND_LOCAL); - if (handle == NULL) { - girara_error("could not load plugin %s (%s)", path, g_module_error()); - g_free(path); - continue; - } + /* resolve symbols and check API and ABI version*/ + zathura_plugin_api_version_t api_version = NULL; + if (g_module_symbol(handle, PLUGIN_API_VERSION_FUNCTION, (gpointer*) &api_version) == FALSE || + api_version == NULL) { + girara_error("could not find '%s' function in plugin %s", PLUGIN_API_VERSION_FUNCTION, path); + g_free(path); + g_module_close(handle); + continue; + } - /* resolve symbols and check API and ABI version*/ - zathura_plugin_api_version_t api_version = NULL; - if (g_module_symbol(handle, PLUGIN_API_VERSION_FUNCTION, (gpointer*) &api_version) == FALSE || - api_version == NULL) - { - girara_error("could not find '%s' function in plugin %s", PLUGIN_API_VERSION_FUNCTION, path); - g_free(path); - g_module_close(handle); - continue; - } + if (api_version() != ZATHURA_API_VERSION) { + girara_error("plugin %s has been built againt zathura with a different API version (plugin: %d, zathura: %d)", + path, api_version(), ZATHURA_API_VERSION); + g_free(path); + g_module_close(handle); + continue; + } - if (api_version() != ZATHURA_API_VERSION) { - girara_error("plugin %s has been built againt zathura with a different API version (plugin: %d, zathura: %d)", - path, api_version(), ZATHURA_API_VERSION); - g_free(path); - g_module_close(handle); - continue; - } + zathura_plugin_abi_version_t abi_version = NULL; + if (g_module_symbol(handle, PLUGIN_ABI_VERSION_FUNCTION, (gpointer*) &abi_version) == FALSE || + abi_version == NULL) { + girara_error("could not find '%s' function in plugin %s", PLUGIN_ABI_VERSION_FUNCTION, path); + g_free(path); + g_module_close(handle); + continue; + } - zathura_plugin_abi_version_t abi_version = NULL; - if (g_module_symbol(handle, PLUGIN_ABI_VERSION_FUNCTION, (gpointer*) &abi_version) == FALSE || - abi_version == NULL) - { - girara_error("could not find '%s' function in plugin %s", PLUGIN_ABI_VERSION_FUNCTION, path); - g_free(path); - g_module_close(handle); - continue; - } + if (abi_version() != ZATHURA_ABI_VERSION) { + girara_error("plugin %s has been built againt zathura with a different ABI version (plugin: %d, zathura: %d)", + path, abi_version(), ZATHURA_ABI_VERSION); + g_free(path); + g_module_close(handle); + continue; + } - if (abi_version() != ZATHURA_ABI_VERSION) { - girara_error("plugin %s has been built againt zathura with a different ABI version (plugin: %d, zathura: %d)", - path, abi_version(), ZATHURA_ABI_VERSION); - g_free(path); - g_module_close(handle); - continue; - } + zathura_plugin_register_service_t register_service = NULL; + if (g_module_symbol(handle, PLUGIN_REGISTER_FUNCTION, (gpointer*) ®ister_service) == FALSE || + register_service == NULL) { + girara_error("could not find '%s' function in plugin %s", PLUGIN_REGISTER_FUNCTION, path); + g_free(path); + g_module_close(handle); + continue; + } - zathura_plugin_register_service_t register_service = NULL; - if (g_module_symbol(handle, PLUGIN_REGISTER_FUNCTION, (gpointer*) ®ister_service) == FALSE || - register_service == NULL) - { - girara_error("could not find '%s' function in plugin %s", PLUGIN_REGISTER_FUNCTION, path); - g_free(path); - g_module_close(handle); - continue; - } + plugin = g_malloc0(sizeof(zathura_plugin_t)); + plugin->content_types = girara_list_new2(g_free); + plugin->handle = handle; - plugin = g_malloc0(sizeof(zathura_plugin_t)); - plugin->content_types = girara_list_new2(g_free); - plugin->handle = handle; + register_service(plugin); - register_service(plugin); + /* register functions */ + if (plugin->register_function == NULL) { + girara_error("plugin has no document functions register function"); + g_free(path); + g_free(plugin); + g_module_close(handle); + continue; + } - /* register functions */ - if (plugin->register_function == NULL) { - girara_error("plugin has no document functions register function"); - g_free(path); - g_free(plugin); - g_module_close(handle); - continue; - } + plugin->register_function(&(plugin->functions)); + plugin->path = path; - plugin->register_function(&(plugin->functions)); - plugin->path = path; + bool ret = register_plugin(plugin_manager, plugin); + if (ret == false) { + girara_error("could not register plugin %s", path); + zathura_plugin_free(plugin); + } else { + girara_debug("successfully loaded plugin %s", path); - bool ret = register_plugin(plugin_manager, plugin); - if (ret == false) { - girara_error("could not register plugin %s", path); - zathura_plugin_free(plugin); - } else { - girara_info("successfully loaded plugin %s", path); - - zathura_plugin_version_function_t plugin_major = NULL, plugin_minor = NULL, plugin_rev = NULL; - g_module_symbol(handle, PLUGIN_VERSION_MAJOR_FUNCTION, (gpointer*) &plugin_major); - g_module_symbol(handle, PLUGIN_VERSION_MINOR_FUNCTION, (gpointer*) &plugin_minor); - g_module_symbol(handle, PLUGIN_VERSION_REVISION_FUNCTION, (gpointer*) &plugin_rev); - if (plugin_major != NULL && plugin_minor != NULL && plugin_rev != NULL) { - plugin->version.major = plugin_major(); - plugin->version.minor = plugin_minor(); - plugin->version.rev = plugin_rev(); - girara_debug("plugin '%s': version %u.%u.%u", path, - plugin->version.major, plugin->version.minor, - plugin->version.rev); - } + zathura_plugin_version_function_t plugin_major = NULL, plugin_minor = NULL, plugin_rev = NULL; + g_module_symbol(handle, PLUGIN_VERSION_MAJOR_FUNCTION, (gpointer*) &plugin_major); + g_module_symbol(handle, PLUGIN_VERSION_MINOR_FUNCTION, (gpointer*) &plugin_minor); + g_module_symbol(handle, PLUGIN_VERSION_REVISION_FUNCTION, (gpointer*) &plugin_rev); + if (plugin_major != NULL && plugin_minor != NULL && plugin_rev != NULL) { + plugin->version.major = plugin_major(); + plugin->version.minor = plugin_minor(); + plugin->version.rev = plugin_rev(); + girara_debug("plugin '%s': version %u.%u.%u", path, + plugin->version.major, plugin->version.minor, + plugin->version.rev); } } - g_dir_close(dir); + } + g_dir_close(dir); GIRARA_LIST_FOREACH_END(zathura->plugins.path, char*, iter, plugindir); } @@ -217,10 +211,10 @@ zathura_plugin_manager_get_plugin(zathura_plugin_manager_t* plugin_manager, cons zathura_plugin_t* plugin = NULL; GIRARA_LIST_FOREACH(plugin_manager->type_plugin_mapping, zathura_type_plugin_mapping_t*, iter, mapping) - if (g_content_type_equals(type, mapping->type)) { - plugin = mapping->plugin; - break; - } + if (g_content_type_equals(type, mapping->type)) { + plugin = mapping->plugin; + break; + } GIRARA_LIST_FOREACH_END(plugin_manager->type_plugin_mapping, zathura_type_plugin_mapping_t*, iter, mapping); return plugin; @@ -272,11 +266,11 @@ register_plugin(zathura_plugin_manager_t* plugin_manager, zathura_plugin_t* plug bool at_least_one = false; GIRARA_LIST_FOREACH(plugin->content_types, gchar*, iter, type) - if (plugin_mapping_new(plugin_manager, type, plugin) == false) { - girara_error("plugin: already registered for filetype %s\n", type); - } else { - at_least_one = true; - } + if (plugin_mapping_new(plugin_manager, type, plugin) == false) { + girara_error("plugin: already registered for filetype %s\n", type); + } else { + at_least_one = true; + } GIRARA_LIST_FOREACH_END(plugin->content_types, gchar*, iter, type); if (at_least_one == true) { @@ -294,10 +288,10 @@ plugin_mapping_new(zathura_plugin_manager_t* plugin_manager, const gchar* type, g_return_val_if_fail(plugin != NULL, false); GIRARA_LIST_FOREACH(plugin_manager->type_plugin_mapping, zathura_type_plugin_mapping_t*, iter, mapping) - if (g_content_type_equals(type, mapping->type)) { - girara_list_iterator_free(iter); - return false; - } + if (g_content_type_equals(type, mapping->type)) { + girara_list_iterator_free(iter); + return false; + } GIRARA_LIST_FOREACH_END(plugin_manager->type_plugin_mapping, zathura_type_plugin_mapping_t*, iter, mapping); zathura_type_plugin_mapping_t* mapping = g_malloc(sizeof(zathura_type_plugin_mapping_t)); diff --git a/po/Makefile b/po/Makefile index c1a2498..4bff663 100644 --- a/po/Makefile +++ b/po/Makefile @@ -4,10 +4,13 @@ PROJECT = zathura GETTEXT_PACKAGE = $(PROJECT) CATALOGS = $(wildcard *.po) LINGUAS ?= $(patsubst %.po, %, $(CATALOGS)) -ALINGUAS = $(shell find $(patsubst %, %.po, $(LINGUAS)) 2>/dev/null) +ifeq ($(LINGUAS),) +ALINGUAS = +else +ALINGUAS = $(shell find $(patsubst %, %.po, $(LINGUAS)) 2>/dev/null) +endif MOS = $(patsubst %, %/LC_MESSAGES/${GETTEXT_PACKAGE}.mo, $(patsubst %.po, %, $(ALINGUAS))) - include ../config.mk include ../common.mk @@ -31,6 +34,7 @@ update-po: ${PROJECT}.pot $(ECHO) updating po: files ${CATALOGS} $(QUIET)set -e && for f in ${CATALOGS} ; do \ intltool-update --dist --gettext-package=${PROJECT} `echo $$f | sed 's/\.po//'` ; \ + sed -i 's/Report-Msgid-Bugs-To: \\n/Report-Msgid-Bugs-To: http:\/\/bugs.pwmt.org\\n/' "$$f" ; \ done %/LC_MESSAGES/${PROJECT}.mo: %.po diff --git a/po/cs.po b/po/cs.po index 6b94549..d148050 100644 --- a/po/cs.po +++ b/po/cs.po @@ -4,8 +4,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-06-19 23:59+0200\n" "Last-Translator: Martin Pelikan \n" "Language-Team: pwmt.org \n" @@ -14,23 +14,24 @@ msgstr "" "Content-Type: text/plain; charset=utf-8\n" "Content-Transfer-Encoding: 8bit\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Neplatný vstup: %s" -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Neplatný index: %s" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Není otevřený žádný dokument." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Špatný počet argumentů." @@ -57,7 +58,7 @@ msgstr "Záložka smazána: %s" #: ../commands.c:84 #, c-format msgid "Failed to remove bookmark: %s" -msgstr "Nem¿¿u smazat zálo¿ku: %s" +msgstr "Nemůžu smazat záložku: %s" #: ../commands.c:110 #, c-format @@ -88,37 +89,37 @@ msgstr "Nepovedlo se uložit dokument." msgid "Invalid number of arguments." msgstr "Špatný počet argumentů." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." -msgstr "Nepovedlo se zapsat p¿ílohu '%s' do '%s'." +msgstr "Nepovedlo se zapsat přílohu '%s' do '%s'." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Příloha '%s' zapsána do '%s'." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "Obrázek '%s' zapsán do '%s'." -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "Nepovedlo se zapsat obrázek '%s' do '%s'." -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "Neznámý obrázek '%s'." -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "Neznámá příloha nebo obrázek '%s'." -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Argumentem musí být číslo." @@ -137,211 +138,241 @@ msgid "Images" msgstr "Obrázky" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Databázový backend" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Zoom step" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Mezery mezi stránkami" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Počet stránek na řádek" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Scroll step" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Oddálit" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Přiblížit" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Délka života skryté stránky v sekundách" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "Počet sekund mezi čištěními cache" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Přebarvuji do tmava" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" -msgstr "Přebarvuji do sv¿tla" +msgstr "Přebarvuji do světla" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Barva zvýrazňovače" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Barva zvýrazňovače (aktivní)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Přebarvit stránky" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Scrollovat přes konce" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Průhlednost při zvýrazňování" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Vypisovat 'Načítám ...'" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Přiblížení po otevření souboru" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Zobrazovat skryté soubory" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Zobrazovat adresáře" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Vždy otevírat na první straně" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "Zvýrazňovat výsledky hledání" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "Při abortu smazat výsledky hledání" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Přidat záložku" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Smazat záložku" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Vypsat záložky" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Zavřít tenhle soubor" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Zobrazit informace o souboru" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Zobrazit nápovědu" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Otevřít dokument" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Zavřít zathuru" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Tisknout dokument" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Uložit dokument" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Uložit a přepsat dokument" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Uložit přílohy" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "Označit současnou pozici v dokumentu" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "Smazat vybrané značky" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "Nezvýrazňovat výsledky tohoto hledání" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "Zvýrazňovat výsledky tohoto hledání" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Nepovedlo se spustit xdg-open." +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "" @@ -378,27 +409,27 @@ msgstr "Zobrazit informace o souboru" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Načítám ..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Vybraný text zkopírován do schránky: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Zkopíruj obrázek" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "Ulož obrázek jako" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Tenhle dokument neobsahuje žádné indexy" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Nepojmenovaný]" diff --git a/po/de.po b/po/de.po index ddc3c2c..22d0860 100644 --- a/po/de.po +++ b/po/de.po @@ -5,8 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-08-05 16:08+0100\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: pwmt.org \n" @@ -16,23 +16,24 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Ungültige Eingabe '%s' angegeben." -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Ungültiger Index '%s' angegeben." #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Kein Dokument geöffnet." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Ungültige Anzahl an Argumenten angegeben." @@ -90,37 +91,37 @@ msgstr "Konnte Dokument nicht speichern." msgid "Invalid number of arguments." msgstr "Ungültige Anzahl an Argumenten." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "Konnte Anhang '%s' nicht nach '%s' schreiben." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Anhang '%s' nach '%s' geschrieben." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "Anhang '%s' nach '%s' geschrieben." -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "Konnte Anhang '%s' nicht nach '%s' schreiben." -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "Unbekanntes Bild '%s'." -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "Unbekannter Anhanng oder Bild '%s'." -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Das Argument ist keine Zahl." @@ -139,214 +140,244 @@ msgid "Images" msgstr "Bilder" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Datenbank Backend" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Vergrößerungsstufe" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Abstand zwischen den Seiten" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Anzahl der Seiten in einer Reihe" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "Spalte der ersten Seite" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Schrittgröße beim Scrollen" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "Horizontale Schrittgröße beim Scrollen" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Minimale Vergrößerungsstufe" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Maximale Vergrößerungsstufe" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Zeit (in Sekunden) bevor nicht sichtbare Seiten gelöscht werden" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "" "Anzahl der Sekunden zwischen jeder Prüfung von nicht angezeigten Seiten" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Neufärben (Dunkle Farbe)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Neufärben (Helle Farbe)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Farbe für eine Markierung" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Farbe für die aktuelle Markierung" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Färbe die Seiten ein" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" "Behalte beim Neuzeichnen den ursprünglichen Hue-Wert bei und stimme nur die " "Helligkeit ab" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Scroll-Umbruch" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "Gehe Anzahl der Seiten in einer Reihe weiter" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "Horizontal zentrierter Zoom" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "Zentriere Ergebnis horizontal" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Transparenz einer Markierung" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Zeige 'Lädt...'-Text beim Zeichnen einer Seite" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Seite einpassen" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Zeige versteckte Dateien und Ordner an" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Zeige Ordner an" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Öffne Dokument immer auf der ersten Seite" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "Hebe Suchergebnisse hervor" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "Lösche Suchergebnisse bei Abbruch" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "Verwende den Dateinamen der Datei im Fenstertitel" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Füge Lesezeichen hinzu" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Lösche ein Lesezeichen" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Liste all Lesezeichen auf" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Schließe das aktuelle Dokument" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Zeige Dokumentinformationen an" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Zeige Hilfe an" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Öffne Dokument" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Beende zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Drucke Dokument" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Speichere Dokument" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Speichere Dokument (und überschreibe bestehende)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Speichere Anhänge" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Setze den Seitenabstand" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "Markiere aktuelle Position im Doukument" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "Lösche angegebene Markierung" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "Hebe aktuelle Suchergebnisse nicht hervor" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "Hebe aktuelle Suchergebnisse hervor" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "Zeige Versionsinformationen an" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Konnte xdg-open nicht ausführen." +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "Verknüpfung: Seite %d" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "Verknüpfung: %s" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "Verknüpfung: ungültig" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "Reparentiert zathura an das Fenster mit der xid" @@ -383,27 +414,27 @@ msgstr "Zeige Versionsinformationen an" msgid "Synctex editor (forwarded to the synctex command)" msgstr "Synctex Editor (wird an synctex weitergeleitet)" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Lädt..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Der gewählte Text wurde in die Zwischenablage kopiert: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Bild kopieren" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "Bild speichern als" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Dieses Dokument beinhaltet kein Inhaltsverzeichnis." -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Kein Name]" diff --git a/po/eo.po b/po/eo.po index 9b91157..8de9d95 100644 --- a/po/eo.po +++ b/po/eo.po @@ -6,34 +6,36 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: http://bt.pwmt.org/\n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-08-09 13:21+0000\n" "Last-Translator: norbux \n" -"Language-Team: Esperanto (http://www.transifex.com/projects/p/zathura/language/eo/)\n" +"Language-Team: Esperanto (http://www.transifex.com/projects/p/zathura/" +"language/eo/)\n" +"Language: eo\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Language: eo\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Nevalida enigo '%s' uzata." -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Nevalida indekso '%s' uzata." #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Neniu dokumento malfermita." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Nevalida nombro da argumentoj uzata." @@ -91,37 +93,37 @@ msgstr "Neeble konservi dokumenton." msgid "Invalid number of arguments." msgstr "Nevalida nombro da argumentoj." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "Neeble skribi kunsendaĵon '%s' en '%s'." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Skribis kunsendaĵon '%s' en '%s'." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "Skribis kunsendaĵon '%s' en '%s'." -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "Neeble skribi kunsendaĵon '%s' en '%s'." -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "Nekonata bildo '%s'." -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Argumento devas esti nombro." @@ -140,211 +142,241 @@ msgid "Images" msgstr "Bildoj" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Zompaŝo" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Interpaĝa plenigo" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Nombro da paĝoj po vico" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Rulumpaŝo" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Mimimuma zomo" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Maksimuma zomo" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Vivdaŭro (sekunda) de kaŝita paĝo" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "Nombro da sekundoj inter repurigo de kaŝmemoro" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Rekolorigo (malhela koloro)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Rekolorigo (hela koloro)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Koloro por fonlumo" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Koloro por fonlumo (aktiva)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Rekoloru paĝojn" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Ĉirkaŭflua rulumado" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Travidebleco por fonlumo" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Bildigu 'Ŝargado ...'" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Adaptaĵo ĉe malfermo de dosiero" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Montru kaŝitajn dosierojn kaj -ujojn" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Montru dosierujojn" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Ĉiam malfermu ĉe unua paĝo" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Aldonu paĝosignon" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Forigu paĝosignon" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Listigu ĉiujn paĝosignojn" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Fermu nunan dosieron" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Montru dosiera informacio" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Montru helpon" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Malfermu dokumenton" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Fermu zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Presu dokumenton" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Konservu dokumenton" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Konservu dokumenton (deviga anstataŭo)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Konservu kunsendaĵojn" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Agordu paĝdelokado" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Fiaskis iro de xdg-open" +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "" @@ -381,27 +413,27 @@ msgstr "Montru dosiera informacio" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Ŝargado ..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Selektita teksto estas kopiita en la poŝo: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Kopiu bildon" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "Savi bildojn kiel" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Ĉi-tiu dokumento enhavas neniam indekson." -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Neniu nomo]" diff --git a/po/es.po b/po/es.po index a841636..eea55de 100644 --- a/po/es.po +++ b/po/es.po @@ -5,8 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-04-03 15:25+0000\n" "Last-Translator: Moritz Lipp \n" "Language-Team: Spanish (Castilian) (http://www.transifex.net/projects/p/" @@ -17,23 +17,24 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Entrada inválida: '%s'." -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Índice invalido: '%s'." #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Ningún documento abierto." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Número de argumentos inválido." @@ -91,44 +92,44 @@ msgstr "Error al guardar el documento." msgid "Invalid number of arguments." msgstr "Número de argumentos inválido." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "No se pudo escribir el fichero adjunto '%s' a '%s'." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Escrito fichero adjunto '%s' a '%s'." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "Escrito fichero adjunto '%s' a '%s'." -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "No se pudo escribir el fichero adjunto '%s' a '%s'." -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." -msgstr "" +msgstr "Imagen desconocida '%s'." -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." -msgstr "" +msgstr "Adjunto o imagen desconocidos '%s'." -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "El argumento ha de ser un número." #: ../completion.c:250 #, c-format msgid "Page %d" -msgstr "" +msgstr "Página %d" #: ../completion.c:293 msgid "Attachments" @@ -137,215 +138,246 @@ msgstr "Guardar ficheros adjuntos" #. add images #: ../completion.c:324 msgid "Images" -msgstr "" +msgstr "Imágenes" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Base de datos" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Unidad de zoom" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Separación entre páginas" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Número de páginas por fila" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" -msgstr "" +msgstr "Columna de la primera página" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" -msgstr "Unidad de desplazamiento" +msgstr "Paso de desplazamiento" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" -msgstr "" +msgstr "Paso de desplazamiento horizontal" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "Solapamiento del desplazamiento de página" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Zoom mínimo" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Zoom máximo" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" -msgstr "" +msgstr "Tiempo de vida (en segundos) de una página oculta" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" -msgstr "" -"Cantidad de segundos entre las comprobaciones de las páginas invisibles" +msgstr "Cantidad de segundos entre limpieza de caché" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "Número de posiciones a recordar en la lista de saltos" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Recoloreado (color oscuro)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Recoloreado (color claro)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Color para destacar" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Color para destacar (activo)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Recolorear páginas" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" +"Cuando se recoloree, mantener el tono original y ajustar únicamente la " +"luminosidad" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Navegación/Scroll cíclica/o" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" -msgstr "" +msgstr "Zoom centrado horizontalmente" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" -msgstr "" +msgstr "Centrar el resultado horizontalmente" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Transparencia para el destacado" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Renderizado 'Cargando ...'" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Ajustarse al abrir un fichero" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Mostrar directorios y ficheros ocultos" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Mostrar directorios" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Abrir siempre la primera página" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" -msgstr "" +msgstr "Destacar los resultados de búsqueda" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "Habilitar la búsqueda incremental" + +#: ../config.c:199 msgid "Clear search results on abort" -msgstr "" +msgstr "Borrar resultados de búsqueda al abortar" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" -msgstr "" +msgstr "Usar el nombre del archivo en el título de la ventana" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" -msgstr "" +msgstr "Habilitar soporte synctex" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Añadir Favorito" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Eliminar Favorito" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Listar favoritos" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Cerrar fichero actual" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Mostrar información del fichero" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" -msgstr "" +msgstr "Ejecutar un comando" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Mostrar ayuda" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Abrir documento" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Salir de zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Imprimir documento" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Guardar documento" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Guardar documento (y sobreescribir)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Guardar ficheros adjuntos" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Asignar el desplazamiento de página" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" -msgstr "" +msgstr "Marcar la posición actual en el documento" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" -msgstr "" +msgstr "Borrar las marcas especificadas" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" -msgstr "" +msgstr "No destacar los resultados de la búsqueda actual" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" -msgstr "" +msgstr "Destacar los resultados de la búsqueda actual" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" -msgstr "" +msgstr "Mostrar versión" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Error al tratar de ejecutar xdg-open" +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "Reasignar a la ventana especificada por xid" @@ -368,7 +400,7 @@ msgstr "Fork, ejecutándose en background" #: ../main.c:57 msgid "Document password" -msgstr "" +msgstr "Contraseña del documento" #: ../main.c:58 msgid "Log level (debug, info, warning, error)" @@ -380,29 +412,29 @@ msgstr "Mostrar información del fichero" #: ../main.c:61 msgid "Synctex editor (forwarded to the synctex command)" -msgstr "" +msgstr "Editor de Synctex (reenvíado al commando synctex)" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Cargando ..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Se ha copiado el texto seleccionado al portapapeles: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Copiar imagen" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" -msgstr "" +msgstr "Salvar imagen como" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Este documento no contiene ningún índice" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Sin nombre]" diff --git a/po/es_CL.po b/po/es_CL.po index f2a7f1e..9adfe02 100644 --- a/po/es_CL.po +++ b/po/es_CL.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-04-03 15:26+0000\n" "Last-Translator: watsh1ken \n" "Language-Team: Spanish (Chile) (http://www.transifex.net/projects/p/zathura/" @@ -18,23 +18,24 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Entrada inválida: '%s'." -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Índice invalido: '%s'." #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Ningún documento abierto." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Número de argumentos inválido." @@ -92,37 +93,37 @@ msgstr "Error al guardar el documento." msgid "Invalid number of arguments." msgstr "Número de argumentos inválido." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "No se pudo escribir el fichero adjunto '%s' a '%s'." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Fichero adjunto escrito '%s' a '%s'." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "Fichero adjunto escrito '%s' a '%s'." -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "No se pudo escribir el fichero adjunto '%s' a '%s'." -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "" -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "El argumento debe ser un número." @@ -141,212 +142,242 @@ msgid "Images" msgstr "" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Fin de la base de datos." -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Unidad de zoom" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Separación entre páginas" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Numero de páginas por fila" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Unidad de desplazamiento" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Zoom mínimo" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Zoom máximo" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "" "Cantidad de segundos entre las comprobaciones de las páginas invisibles" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Recolorando (color oscuro)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Recolorando (color claro)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Color para destacar" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Color para destacar (activo)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Recolorar páginas" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Scroll cíclico" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Transparencia para lo destacado" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Renderizando 'Cargando...'" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Ajustar al abrirse un archivo" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Mostrar archivos ocultos y directorios" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Mostrar directorios" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Siempre abrir en primera página" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Agregar un marcador" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Eliminar un marcador" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Listar todos los marcadores" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Cerrar archivo actual" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Mostrar información del archivo" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Mostrar ayuda" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Abrir documento" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Cerrar zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Imprimir documento" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Guardar documento" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Guardar documento (y forzar sobreescritura)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Guardar archivos adjuntos" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Asignar desplazamiento de la página" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Error al ejecutar xdg-open." +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "Reasignar a la ventana especificada por xid" @@ -383,27 +414,27 @@ msgstr "Mostrar información del archivo" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Cargando..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Texto seleccionado copiado al portapapeles: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Copiar imagen" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Este document no contiene índice" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Sin nombre]" diff --git a/po/et.po b/po/et.po index 6651841..46e67ea 100644 --- a/po/et.po +++ b/po/et.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-04-03 15:25+0000\n" "Last-Translator: Rivo Zängov \n" "Language-Team: Estonian (http://www.transifex.net/projects/p/zathura/" @@ -18,23 +18,24 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "" -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "" -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "" @@ -92,37 +93,37 @@ msgstr "" msgid "Invalid number of arguments." msgstr "" -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "" -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "" -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "" -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "" -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "" -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "" @@ -141,211 +142,241 @@ msgid "Images" msgstr "" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 -msgid "Zoom minimum" -msgstr "" - -#: ../config.c:121 -msgid "Zoom maximum" -msgstr "" - -#: ../config.c:123 -msgid "Life time (in seconds) of a hidden page" -msgstr "" - -#: ../config.c:124 -msgid "Amount of seconds between each cache purge" -msgstr "" - -#: ../config.c:126 -msgid "Recoloring (dark color)" -msgstr "" - -#: ../config.c:128 -msgid "Recoloring (light color)" -msgstr "" - -#: ../config.c:130 -msgid "Color for highlighting" -msgstr "Esiletõstmise värv" - -#: ../config.c:132 -msgid "Color for highlighting (active)" -msgstr "Esiletõstmise värv (aktiivne)" - -#: ../config.c:136 -msgid "Recolor pages" -msgstr "" - -#: ../config.c:138 -msgid "When recoloring keep original hue and adjust lightness only" -msgstr "" - -#: ../config.c:140 -msgid "Wrap scrolling" -msgstr "" - -#: ../config.c:142 -msgid "Advance number of pages per row" -msgstr "" - -#: ../config.c:144 -msgid "Horizontally centered zoom" -msgstr "" - -#: ../config.c:146 -msgid "Center result horizontally" -msgstr "" - -#: ../config.c:148 -msgid "Transparency for highlighting" -msgstr "" - -#: ../config.c:150 -msgid "Render 'Loading ...'" +#: ../config.c:149 +msgid "Full page scroll overlap" msgstr "" #: ../config.c:151 -msgid "Adjust to when opening file" +msgid "Zoom minimum" msgstr "" #: ../config.c:153 -msgid "Show hidden files and directories" +msgid "Zoom maximum" msgstr "" #: ../config.c:155 +msgid "Life time (in seconds) of a hidden page" +msgstr "" + +#: ../config.c:156 +msgid "Amount of seconds between each cache purge" +msgstr "" + +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 +msgid "Recoloring (dark color)" +msgstr "" + +#: ../config.c:162 +msgid "Recoloring (light color)" +msgstr "" + +#: ../config.c:164 +msgid "Color for highlighting" +msgstr "Esiletõstmise värv" + +#: ../config.c:166 +msgid "Color for highlighting (active)" +msgstr "Esiletõstmise värv (aktiivne)" + +#: ../config.c:170 +msgid "Recolor pages" +msgstr "" + +#: ../config.c:172 +msgid "When recoloring keep original hue and adjust lightness only" +msgstr "" + +#: ../config.c:174 +msgid "Wrap scrolling" +msgstr "" + +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 +msgid "Advance number of pages per row" +msgstr "" + +#: ../config.c:180 +msgid "Horizontally centered zoom" +msgstr "" + +#: ../config.c:182 +msgid "Center result horizontally" +msgstr "" + +#: ../config.c:184 +msgid "Transparency for highlighting" +msgstr "" + +#: ../config.c:186 +msgid "Render 'Loading ...'" +msgstr "" + +#: ../config.c:187 +msgid "Adjust to when opening file" +msgstr "" + +#: ../config.c:189 +msgid "Show hidden files and directories" +msgstr "" + +#: ../config.c:191 msgid "Show directories" msgstr "Näita kaustasid" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Ava alati esimene leht" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Lisa järjehoidja" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Kustuta järjehoidja" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Näita kõiki järjehoidjaid" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Sulge praegune fail" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Näita faili infot" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Näita abiinfot" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Ava dokument" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Sule zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Prindi dokument" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Salvesta dokument" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Salvesta manused" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "" +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "" @@ -382,27 +413,27 @@ msgstr "Näita faili infot" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "" -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Kopeeri pilt" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Nime pole]" diff --git a/po/fr.po b/po/fr.po index 8cd0643..5d248ef 100644 --- a/po/fr.po +++ b/po/fr.po @@ -4,37 +4,40 @@ # Translators: # Quentin Stiévenart , 2012. # Stéphane Aulery , 2012. +# Benoît Knecht , 2012. msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: http://bt.pwmt.org/\n" -"POT-Creation-Date: 2012-08-05 15:45+0200\n" -"PO-Revision-Date: 2012-08-07 22:54+0000\n" -"Last-Translator: Stéphane Aulery \n" -"Language-Team: French (http://www.transifex.com/projects/p/zathura/language/fr/)\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" +"PO-Revision-Date: 2012-12-14 00:08+0100\n" +"Last-Translator: Benoît Knecht \n" +"Language-Team: French (http://www.transifex.com/projects/p/zathura/language/" +"fr/)\n" +"Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Language: fr\n" "Plural-Forms: nplurals=2; plural=(n > 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Entrée invalide : '%s'" -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Index invalide : '%s'" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Aucun document ouvert." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Nombre d'arguments invalide." @@ -46,7 +49,7 @@ msgstr "Marque page mis à jour avec succès : %s" #: ../commands.c:55 #, c-format msgid "Could not create bookmark: %s" -msgstr "Impossible de créer le marque page: %s" +msgstr "Impossible de créer le marque-page : %s" #: ../commands.c:59 #, c-format @@ -61,12 +64,12 @@ msgstr "Marque page supprimé : %s" #: ../commands.c:84 #, c-format msgid "Failed to remove bookmark: %s" -msgstr "Échec lors de la suppression du marque page : %s" +msgstr "Échec lors de la suppression du marque-page : %s" #: ../commands.c:110 #, c-format msgid "No such bookmark: %s" -msgstr "Aucun marque page : %s" +msgstr "Aucun marque-page correspondant : %s" #: ../commands.c:161 ../commands.c:183 msgid "No information available." @@ -92,37 +95,37 @@ msgstr "Échec lors de l'enregistrement du document." msgid "Invalid number of arguments." msgstr "Nombre d'arguments invalide." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "Impossible d'écrire la pièce jointe '%s' dans '%s'." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." -msgstr "Ecriture de la pièce jointe '%s' dans '%s'." +msgstr "Pièce jointe '%s' écrite dans '%s'." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." -msgstr "Écriture de l'image '%s' dans '%s'." +msgstr "Image '%s' écrite dans '%s'." -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "Impossible d'écrire l'image '%s' dans '%s'." -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." -msgstr "Image '%s' inconnue" +msgstr "Image '%s' inconnue." -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "Pièce jointe ou image '%s' inconnue." -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "L'argument doit être un nombre." @@ -141,212 +144,242 @@ msgid "Images" msgstr "Images" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Gestionnaire de base de données" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" -msgstr "Facteur de zoom" +msgstr "Incrément de zoom" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Espacement entre les pages" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Nombre de page par rangée" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "Colonne de la première page" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" -msgstr "Facteur de défilement" +msgstr "Incrément de défilement" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" -msgstr "Pas de défilement horizontal" +msgstr "Incrément de défilement horizontal" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "Recouvrement lors du défilement par page entière" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Zoom minimum" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Zoom maximum" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Durée de vie (en secondes) d'une page cachée" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" -msgstr "Délai en secondes entre chaque purge du cache." +msgstr "Délai en secondes entre chaque purge du cache" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "Nombre de positions à mémoriser dans la liste de sauts" + +#: ../config.c:160 msgid "Recoloring (dark color)" -msgstr "Recolorisation (couleurs sombres)" +msgstr "Recoloration (couleur sombre)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" -msgstr "Recolorisation (couleurs claires)" +msgstr "Recoloration (couleur claire)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Couleur de surbrillance" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Couleur de surbrillance (active)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Recoloriser les pages" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -"Lors du recalibrage des couleurs garder la teinte d'origine et ajuster " -"seulement la luminosité" +"Lors de la recoloration garder la teinte d'origine et ajuster seulement la " +"luminosité" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" -msgstr "Défiler lors du renvoi à la ligne" +msgstr "Défiler en boucle" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "Défilement tenant compte des limites de page" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "Augmenter le nombre de pages par rangée" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "Zoom centré horizontalement" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "Centrer le résultat horizontalement" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Transparence de la surbrillance" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" -msgstr "Rendu 'Chargement...'" +msgstr "Afficher 'Chargement...'" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Ajuster à l'ouverture du fichier" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Montrer les fichiers et dossiers cachés" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Montrer les dossiers" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Toujours ouvrir à la première page" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "Surligner les résultats de la recherche" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "Activer la recherche incrémentale" + +#: ../config.c:199 msgid "Clear search results on abort" -msgstr "Effacer les résultats de recherche en cas d'abandon" +msgstr "Effacer les résultats de recherche en cas d'annulation" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" -msgstr "Utiliser le nom de base dans le titre de la fenêtre" +msgstr "Utiliser le nom de base du fichier dans le titre de la fenêtre" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" -msgstr "" +msgstr "Activer la prise en charge de synctex" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Ajouter un marque-page" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Supprimer un marque-page" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Lister tous les marque-pages" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Fermer le fichier actuel" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Montrer les informations sur le fichier" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" -msgstr "" +msgstr "Exécuter une commande" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Afficher l'aide" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Ouvrir un document" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" -msgstr "Quitter Zathura" +msgstr "Quitter zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" -msgstr "Imprimer un document" +msgstr "Imprimer le document" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" -msgstr "Sauver un document" +msgstr "Sauver le document" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" -msgstr "Sauver un document (et forcer l'écrasement)" +msgstr "Sauver le document (et forcer l'écrasement)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Enregistrer les pièces jointes" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" -msgstr "Régler le décalage de page" +msgstr "Définir le décalage de page" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "Marquer l'emplacement actuel dans le document" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "Supprimer les marques indiquées" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" -msgstr "Ne pas surligner les résultats de la recherche actuelle" +msgstr "Ne pas surligner les résultats de la recherche en cours" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" -msgstr "Surligner les résultats de la recherche actuelle" +msgstr "Surligner les résultats de la recherche en cours" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" -msgstr "Afficher les informations de version " +msgstr "Afficher les informations de version" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." -msgstr "Échec lors du lancement de xdg-open" +msgstr "Échec lors du lancement de xdg-open." + +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "Lien : page %d" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "Lien : %s" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "Lien : Invalide" #: ../main.c:52 msgid "Reparents to window specified by xid" @@ -366,7 +399,7 @@ msgstr "Chemin vers le dossier de plugins" #: ../main.c:56 msgid "Fork into the background" -msgstr "Forker en arrière-plan" +msgstr "Détacher en arrière-plan" #: ../main.c:57 msgid "Document password" @@ -374,37 +407,37 @@ msgstr "Mot de passe du document" #: ../main.c:58 msgid "Log level (debug, info, warning, error)" -msgstr "Niveau d'affichage (debug, info, warning, error)" +msgstr "Niveau de journalisation (debug, info, warning, error)" #: ../main.c:59 msgid "Print version information" -msgstr "Afficher les informations de version " +msgstr "Afficher les informations de version" #: ../main.c:61 msgid "Synctex editor (forwarded to the synctex command)" -msgstr "Éditeur Synctex (transférer à la commande synctex)" +msgstr "Éditeur synctex (transféré à la commande synctex)" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Chargement..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" -msgstr "Copie du texte sélectionné dans le presse-papiers : %s" +msgstr "Texte sélectionné copié dans le presse-papiers : %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Copier l'image" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "Enregistrer l'image sous" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Ce document ne contient pas d'index" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Sans nom]" diff --git a/po/it.po b/po/it.po index 446e77b..6db739e 100644 --- a/po/it.po +++ b/po/it.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-06-20 14:58+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Italian (http://www.transifex.com/projects/p/zathura/language/" @@ -18,23 +18,24 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Input inserito '%s' non valido." -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Indice inserito '%s' non valido." #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Nessun documento aperto." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Numero di argomenti errato." @@ -92,37 +93,37 @@ msgstr "Impossibile salvare il documento." msgid "Invalid number of arguments." msgstr "Numero di argomenti non valido." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "Impossibile salvare l' allegato '%s' in '%s'" -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Allegato '%s' salvato in '%s'" -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "" -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "" -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "" -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "L' argomento dev' essere un numero." @@ -141,211 +142,241 @@ msgid "Images" msgstr "" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Backend del database" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Spaziatura tra le pagine" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Numero di pagine per riga" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 -msgid "Zoom minimum" -msgstr "Zoom minimo" - -#: ../config.c:121 -msgid "Zoom maximum" -msgstr "Zoom massimo" - -#: ../config.c:123 -msgid "Life time (in seconds) of a hidden page" -msgstr "Durata (in secondi) di una pagina nascosta" - -#: ../config.c:124 -msgid "Amount of seconds between each cache purge" -msgstr "Tempo in secondi tra le invalidazioni della cache" - -#: ../config.c:126 -msgid "Recoloring (dark color)" -msgstr "" - -#: ../config.c:128 -msgid "Recoloring (light color)" -msgstr "" - -#: ../config.c:130 -msgid "Color for highlighting" -msgstr "" - -#: ../config.c:132 -msgid "Color for highlighting (active)" -msgstr "" - -#: ../config.c:136 -msgid "Recolor pages" -msgstr "Ricolora le pagine" - -#: ../config.c:138 -msgid "When recoloring keep original hue and adjust lightness only" -msgstr "" - -#: ../config.c:140 -msgid "Wrap scrolling" -msgstr "Scrolling continuo" - -#: ../config.c:142 -msgid "Advance number of pages per row" -msgstr "" - -#: ../config.c:144 -msgid "Horizontally centered zoom" -msgstr "" - -#: ../config.c:146 -msgid "Center result horizontally" -msgstr "" - -#: ../config.c:148 -msgid "Transparency for highlighting" -msgstr "" - -#: ../config.c:150 -msgid "Render 'Loading ...'" +#: ../config.c:149 +msgid "Full page scroll overlap" msgstr "" #: ../config.c:151 +msgid "Zoom minimum" +msgstr "Zoom minimo" + +#: ../config.c:153 +msgid "Zoom maximum" +msgstr "Zoom massimo" + +#: ../config.c:155 +msgid "Life time (in seconds) of a hidden page" +msgstr "Durata (in secondi) di una pagina nascosta" + +#: ../config.c:156 +msgid "Amount of seconds between each cache purge" +msgstr "Tempo in secondi tra le invalidazioni della cache" + +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 +msgid "Recoloring (dark color)" +msgstr "" + +#: ../config.c:162 +msgid "Recoloring (light color)" +msgstr "" + +#: ../config.c:164 +msgid "Color for highlighting" +msgstr "" + +#: ../config.c:166 +msgid "Color for highlighting (active)" +msgstr "" + +#: ../config.c:170 +msgid "Recolor pages" +msgstr "Ricolora le pagine" + +#: ../config.c:172 +msgid "When recoloring keep original hue and adjust lightness only" +msgstr "" + +#: ../config.c:174 +msgid "Wrap scrolling" +msgstr "Scrolling continuo" + +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 +msgid "Advance number of pages per row" +msgstr "" + +#: ../config.c:180 +msgid "Horizontally centered zoom" +msgstr "" + +#: ../config.c:182 +msgid "Center result horizontally" +msgstr "" + +#: ../config.c:184 +msgid "Transparency for highlighting" +msgstr "" + +#: ../config.c:186 +msgid "Render 'Loading ...'" +msgstr "" + +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Mostra file e cartelle nascosti" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Mostra cartelle" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Apri sempre alla prima pagina" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Aggiungi un segnalibro" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Elimina un segnalibro" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Mostra i segnalibri" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Chiudi il file corrente" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Mostra le informazioni sul file" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Mostra l' aiuto" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Apri un documento" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Chiudi zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Stampa il documento" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Salva il documento" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Salva il documento (e sovrascrivi)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Salva allegati" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Imposta l' offset della pagina" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Impossibile eseguire xdg-open." +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "" @@ -382,27 +413,27 @@ msgstr "Mostra le informazioni sul file" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "" -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "La selezione è stato copiata negli appunti:%s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Copia immagine" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Questo documento non contiene l' indice" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Nessun nome]" diff --git a/po/pl.po b/po/pl.po index fd69fd0..7bf8d44 100644 --- a/po/pl.po +++ b/po/pl.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-04-03 16:07+0000\n" "Last-Translator: p \n" "Language-Team: Polish (http://www.transifex.net/projects/p/zathura/language/" @@ -19,23 +19,24 @@ msgstr "" "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 " "|| n%100>=20) ? 1 : 2)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Nieprawidłowy argument: %s" -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Nieprawidłowy indeks: %s" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Nie otwarto żadnego pliku" -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Nieprawidłowa liczba parametrów polecenia" @@ -93,37 +94,37 @@ msgstr "Błąd zapisu" msgid "Invalid number of arguments." msgstr "Niewłaściwa liczba parametrów polecenia" -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "Nie można dodać załącznika %s do pliku %s" -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Zapisano załącznik %s do pliku %s" -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "Zapisano obrazek %s do pliku %s" -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "Nie można dodać obrazka %s do pliku %s" -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "Nieznany obrazek '%s'." -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "Nieznany załącznik lub obrazek '%s'." -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Parametr polecenia musi być liczbą" @@ -142,211 +143,241 @@ msgid "Images" msgstr "Obrazki" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Baza danych" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Skok powiększenia" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Odstęp pomiędzy stronami" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Liczba stron w wierszu" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Skok przewijania" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Minimalne powiększenie" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Maksymalne powiększenie" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Czas życia niewidocznej strony (w sekundach)" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "Okres sprawdzania widoczności stron (w sekundach)" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Ciemny kolor negatywu" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Jasny kolor negatywu" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Kolor wyróżnienia" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Kolor wyróżnienia bieżącego elementu" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Negatyw" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Zawijanie dokumentu" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "Liczba stron w wierszu" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Przezroczystość wyróżnienia" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Wyświetlaj: „Wczytywanie pliku...”" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Dopasowanie widoku pliku" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Wyświetl ukryte pliki i katalogi" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Wyświetl katalogi" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Zawsze otwieraj na pierwszej stronie" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "Podświetl wyniki wyszukiwania" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "Wyczyść wyniki wyszukiwania po przerwaniu" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Dodaj zakładkę" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Usuń zakładkę" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Wyświetl zakładki" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Zamknij plik" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Wyświetl informacje o pliku" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Wyświetl pomoc" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Otwórz plik" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Zakończ" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Wydrukuj" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Zapisz" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Zapisz (nadpisując istniejący plik)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Zapisz załączniki" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Ustaw przesunięcie numerów stron" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "Zaznacz aktualną pozycję w dokumencie" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "Skasuj określone zakładki" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "Nie podświetlaj aktualnych wyników wyszukiwania " -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "Podświetl aktualne wyniki wyszukiwania" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "Wyświetl informacje o wersji" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Wystąpił problem z uruchomieniem xdg-open" +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "Przypisz proces do rodzica o danym xid" @@ -383,27 +414,27 @@ msgstr "Wyświetl informacje o wersji" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Wczytywanie pliku..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Zaznaczony tekst skopiowano do schowka: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Skopiuj obrazek" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "Zapisz obrazek jako" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Dokument nie zawiera indeksu" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[bez nazwy]" diff --git a/po/ru.po b/po/ru.po index 3183a67..affdc88 100644 --- a/po/ru.po +++ b/po/ru.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-06-20 14:58+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Russian (http://www.transifex.com/projects/p/zathura/language/" @@ -19,23 +19,24 @@ msgstr "" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Неправильный ввод: %s" -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Получен неверный индекс %s" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Документ не открыт" -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Неверное число аргументов" @@ -93,37 +94,37 @@ msgstr "Не удалось сохранить документ" msgid "Invalid number of arguments." msgstr "Неверное количество аргументов" -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "Не могу сохранить приложенный файл %s в %s" -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Файл %s сохранён в %s" -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "" -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "" -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "" -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Аргумент должен быть числом" @@ -142,211 +143,241 @@ msgid "Images" msgstr "" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Бэкэнд базы данных" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Шаг увеличения" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Разрыв между страницами" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Количество страниц в ряд" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Шаг прокрутки" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Минимальное увеличение" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Максимальное увеличение" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Время жизни (секунды) скрытой страницы" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "Время (в секундах) между очисткой кэшей" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Перекрашивание (тёмные тона)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Перекрашивание (светлые тона)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Цвет для подсветки" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Цвет для подсветки (активной)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Перекрасить страницы" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Плавная прокрутка" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "Увеличить количество страниц в ряду" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Прозрачность подсветки" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Рендер 'Загружается ...'" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Показывать скрытые файлы и директории" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Показывать директории" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Всегда открывать на первой странице" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Добавить закладку" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Удалить закладку" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Показать все закладки" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Закрыть текущий файл" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Показать информацию о файле" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Помощь" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Открыть документ" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Выход" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Печать" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Сохранить документ" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Сохранить документ (с перезапиьсю)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Сохранить прикреплённые файлы" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Сохранить смещение страницы" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "Пометить текущую позицию в документе" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "Удалить указанные пометки" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Не удалось запустить xdg-open" +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "Сменить материнское окно на окно, указанное в xid" @@ -383,27 +414,27 @@ msgstr "Показать информацию о файле" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "" -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Выделенный текст скопирован в буфер: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Скопировать изображение" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "В документе нету индекса" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[No name]" diff --git a/po/ta_IN.po b/po/ta_IN.po index fa31ead..4451aed 100644 --- a/po/ta_IN.po +++ b/po/ta_IN.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-04-03 15:25+0000\n" "Last-Translator: mankand007 \n" "Language-Team: Tamil (India) (http://www.transifex.net/projects/p/zathura/" @@ -18,23 +18,24 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "கொடுக்கப்பட்ட உள்ளீடு(input) '%s' தவறு" -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "கொடுக்கப்பட்ட index '%s' தவறு" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "எந்தக் ஆவணமும் திறக்கப்படவில்லை" -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "கொடுக்கப்பட்ட arguments-களின் எண்ணிக்கை தவறு" @@ -92,37 +93,37 @@ msgstr "ஆவணத்தை சேமிக்க இயலவில்லை" msgid "Invalid number of arguments." msgstr "கொடுக்கப்பட்ட argument-களின் எண்ணிக்கை தவறு" -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "" -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "" -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "" -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "" -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "" -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Argument ஒரு எண்ணாக இருக்க வேண்டும்" @@ -141,211 +142,241 @@ msgid "Images" msgstr "" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Zoom அமைப்பு" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "இரு பக்கங்களுக்கிடையில் உள்ள நிரப்பல்(padding)" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "ஒரு வரிசையில் எத்தனை பக்கங்களைக் காட்ட வேண்டும்" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "திரை உருளல்(scroll) அளவு" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 -msgid "Zoom minimum" -msgstr "முடிந்தவரை சிறியதாகக் காட்டு" - -#: ../config.c:121 -msgid "Zoom maximum" -msgstr "முடிந்தவரை பெரிதாகக் காட்டு" - -#: ../config.c:123 -msgid "Life time (in seconds) of a hidden page" -msgstr "" - -#: ../config.c:124 -msgid "Amount of seconds between each cache purge" -msgstr "" - -#: ../config.c:126 -msgid "Recoloring (dark color)" -msgstr "" - -#: ../config.c:128 -msgid "Recoloring (light color)" -msgstr "" - -#: ../config.c:130 -msgid "Color for highlighting" -msgstr "" - -#: ../config.c:132 -msgid "Color for highlighting (active)" -msgstr "" - -#: ../config.c:136 -msgid "Recolor pages" -msgstr "" - -#: ../config.c:138 -msgid "When recoloring keep original hue and adjust lightness only" -msgstr "" - -#: ../config.c:140 -msgid "Wrap scrolling" -msgstr "" - -#: ../config.c:142 -msgid "Advance number of pages per row" -msgstr "" - -#: ../config.c:144 -msgid "Horizontally centered zoom" -msgstr "" - -#: ../config.c:146 -msgid "Center result horizontally" -msgstr "" - -#: ../config.c:148 -msgid "Transparency for highlighting" -msgstr "" - -#: ../config.c:150 -msgid "Render 'Loading ...'" +#: ../config.c:149 +msgid "Full page scroll overlap" msgstr "" #: ../config.c:151 +msgid "Zoom minimum" +msgstr "முடிந்தவரை சிறியதாகக் காட்டு" + +#: ../config.c:153 +msgid "Zoom maximum" +msgstr "முடிந்தவரை பெரிதாகக் காட்டு" + +#: ../config.c:155 +msgid "Life time (in seconds) of a hidden page" +msgstr "" + +#: ../config.c:156 +msgid "Amount of seconds between each cache purge" +msgstr "" + +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 +msgid "Recoloring (dark color)" +msgstr "" + +#: ../config.c:162 +msgid "Recoloring (light color)" +msgstr "" + +#: ../config.c:164 +msgid "Color for highlighting" +msgstr "" + +#: ../config.c:166 +msgid "Color for highlighting (active)" +msgstr "" + +#: ../config.c:170 +msgid "Recolor pages" +msgstr "" + +#: ../config.c:172 +msgid "When recoloring keep original hue and adjust lightness only" +msgstr "" + +#: ../config.c:174 +msgid "Wrap scrolling" +msgstr "" + +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 +msgid "Advance number of pages per row" +msgstr "" + +#: ../config.c:180 +msgid "Horizontally centered zoom" +msgstr "" + +#: ../config.c:182 +msgid "Center result horizontally" +msgstr "" + +#: ../config.c:184 +msgid "Transparency for highlighting" +msgstr "" + +#: ../config.c:186 +msgid "Render 'Loading ...'" +msgstr "" + +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "புதிய bookmark உருவாக்கு" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Bookmark-ஐ அழித்துவிடு" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "அனைத்து bookmark-களையும் பட்டியலிடு" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "ஆவணம் பற்றிய தகவல்களைக் காட்டு" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "உதவியைக் காட்டு" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "ஒரு ஆவணத்தைத் திற" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "zathura-வை விட்டு வெளியேறு" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "ஆவணத்தை அச்சிடு" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "ஆவணத்தை சேமிக்கவும்" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "இணைப்புகளைச் சேமிக்கவும்" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "xdg-open-ஐ இயக்க முடியவில்லை" +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "" @@ -382,27 +413,27 @@ msgstr "ஆவணம் பற்றிய தகவல்களைக் கா msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "" -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "படத்தை ஒரு பிரதியெடு" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "இந்த ஆவணத்தில் எந்த index-ம் இல்லை" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "பெயரற்ற ஆவணம்" diff --git a/po/tr.po b/po/tr.po index 092445a..f61f75f 100644 --- a/po/tr.po +++ b/po/tr.po @@ -7,8 +7,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-05-01 20:38+0000\n" "Last-Translator: hsngrms \n" "Language-Team: Turkish (http://www.transifex.net/projects/p/zathura/language/" @@ -19,23 +19,24 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Hatalı girdi '%s'" -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Hatalı dizin '%s'" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Açık belge yok." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Yanlış sayıda argüman" @@ -93,37 +94,37 @@ msgstr "Belge kaydedilemedi." msgid "Invalid number of arguments." msgstr "Yanlış sayıda argüman." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "'%s' eki '%s' konumuna yazılamadı." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "'%s' eki '%s' konumuna yazıldı." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "'%s' eki '%s' konumuna yazıldı." -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "'%s' eki '%s' konumuna yazılamadı." -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "" -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Argüman bir sayı olmalı." @@ -142,211 +143,241 @@ msgid "Images" msgstr "" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Veritabanı arkayüzü" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Yakınlaşma/uzaklaşma aralığı" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Sayfalar arasındaki boşluk" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Satır başına sayfa sayısı" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Kaydırma aralığı" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "En fazla uzaklaşma" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "En fazla yakınlaşma" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Gizli pencerenin açık kalma süresi (saniye)" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "Önbellek temizliği yapılma sıklığı, saniye cinsinden" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Renk değişimi (koyu renk)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Renk değişimi (açık renk)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "İşaretleme rengi" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "İşaretleme rengi (etkin)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Sayga rengini değiştir" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Kaydırmayı sarmala" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "Satır başına sayfa sayısı" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Ön plana çıkarmak için saydamlaştır" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "'Yüklüyor ...' yazısını göster" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Dosya açarken ayarla" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Gizli dosyaları ve dizinleri göster" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Dizinleri göster" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Her zaman ilk sayfayı aç" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Yer imi ekle" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Yer imi sil" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Yer imlerini listele" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Geçerli dosyayı kapat" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Dosya bilgisi göster" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Yardım bilgisi göster" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Belge aç" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Zathura'yı kapat" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Belge yazdır" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Belgeyi kaydet" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Belgeyi kaydet (ve sormadan üzerine yaz)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Ekleri kaydet" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Sayfa derinliğini ayarla" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "Bu belgede bu konumu işaretle" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "Seçilen işaretlemeleri sil" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "xdg-open çalıştırılamadı" +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "Xid tarafından belirlendiği gibi bir üst seviye pencereye bağlı" @@ -383,27 +414,27 @@ msgstr "Dosya bilgisi göster" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "Yüklüyor ..." -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Seçili metin panoya kopyalandı: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Resim kopyala" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Bu belge fihrist içermiyor" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[İsimsiz]" diff --git a/po/uk_UA.po b/po/uk_UA.po index 7fbbbaa..1b0fa8b 100644 --- a/po/uk_UA.po +++ b/po/uk_UA.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-08-30 19:46+0200\n" +"Report-Msgid-Bugs-To: http://bugs.pwmt.org\n" +"POT-Creation-Date: 2013-01-13 15:08+0100\n" "PO-Revision-Date: 2012-06-20 14:58+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Ukrainian (Ukraine) (http://www.transifex.com/projects/p/" @@ -19,23 +19,24 @@ msgstr "" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2)\n" -#: ../callbacks.c:204 +#: ../callbacks.c:218 #, c-format msgid "Invalid input '%s' given." msgstr "Вказано невірний аргумент: %s." -#: ../callbacks.c:232 +#: ../callbacks.c:256 #, c-format msgid "Invalid index '%s' given." msgstr "Вказано невірний індекс: %s" #: ../commands.c:35 ../commands.c:70 ../commands.c:97 ../commands.c:139 -#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:400 -#: ../commands.c:521 ../shortcuts.c:454 ../shortcuts.c:919 +#: ../commands.c:253 ../commands.c:283 ../commands.c:309 ../commands.c:408 +#: ../commands.c:529 ../shortcuts.c:475 ../shortcuts.c:1053 +#: ../shortcuts.c:1082 msgid "No document opened." msgstr "Документ не відкрито." -#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:405 +#: ../commands.c:41 ../commands.c:76 ../commands.c:103 ../commands.c:413 msgid "Invalid number of arguments given." msgstr "Вказана невірна кількість аргументів." @@ -93,37 +94,37 @@ msgstr "Документ не вдалося зберегти." msgid "Invalid number of arguments." msgstr "Невірна кількість аргументів." -#: ../commands.c:424 +#: ../commands.c:432 #, c-format msgid "Couldn't write attachment '%s' to '%s'." msgstr "Неможливо записати прикріплення '%s' до '%s'." -#: ../commands.c:426 +#: ../commands.c:434 #, c-format msgid "Wrote attachment '%s' to '%s'." msgstr "Прикріплення записано %s до %s." -#: ../commands.c:470 +#: ../commands.c:478 #, c-format msgid "Wrote image '%s' to '%s'." msgstr "" -#: ../commands.c:472 +#: ../commands.c:480 #, c-format msgid "Couldn't write image '%s' to '%s'." msgstr "" -#: ../commands.c:479 +#: ../commands.c:487 #, c-format msgid "Unknown image '%s'." msgstr "" -#: ../commands.c:483 +#: ../commands.c:491 #, c-format msgid "Unknown attachment or image '%s'." msgstr "" -#: ../commands.c:534 +#: ../commands.c:542 msgid "Argument must be a number." msgstr "Аргумент повинен бути цифрою." @@ -142,211 +143,241 @@ msgid "Images" msgstr "" #. zathura settings -#: ../config.c:105 +#: ../config.c:135 msgid "Database backend" msgstr "Буфер бази" -#: ../config.c:107 +#: ../config.c:137 msgid "Zoom step" msgstr "Збільшення" -#: ../config.c:109 +#: ../config.c:139 msgid "Padding between pages" msgstr "Заповнення між сторінками" -#: ../config.c:111 +#: ../config.c:141 msgid "Number of pages per row" msgstr "Кількість сторінок в одному рядку" -#: ../config.c:113 +#: ../config.c:143 msgid "Column of the first page" msgstr "" -#: ../config.c:115 +#: ../config.c:145 msgid "Scroll step" msgstr "Прокручування" -#: ../config.c:117 +#: ../config.c:147 msgid "Horizontal scroll step" msgstr "" -#: ../config.c:119 +#: ../config.c:149 +msgid "Full page scroll overlap" +msgstr "" + +#: ../config.c:151 msgid "Zoom minimum" msgstr "Максимальне зменшення" -#: ../config.c:121 +#: ../config.c:153 msgid "Zoom maximum" msgstr "Максимальне збільшення" -#: ../config.c:123 +#: ../config.c:155 msgid "Life time (in seconds) of a hidden page" msgstr "Час (у сек) схованої сторінки" -#: ../config.c:124 +#: ../config.c:156 msgid "Amount of seconds between each cache purge" msgstr "Кількість секунд між кожним очищенням кешу" -#: ../config.c:126 +#: ../config.c:158 +msgid "Number of positions to remember in the jumplist" +msgstr "" + +#: ../config.c:160 msgid "Recoloring (dark color)" msgstr "Перефарбування (темний колір)" -#: ../config.c:128 +#: ../config.c:162 msgid "Recoloring (light color)" msgstr "Перефарбування (світлий колір)" -#: ../config.c:130 +#: ../config.c:164 msgid "Color for highlighting" msgstr "Колір для виділення" -#: ../config.c:132 +#: ../config.c:166 msgid "Color for highlighting (active)" msgstr "Колір для виділення (активний)" -#: ../config.c:136 +#: ../config.c:170 msgid "Recolor pages" msgstr "Змінити кольори" -#: ../config.c:138 +#: ../config.c:172 msgid "When recoloring keep original hue and adjust lightness only" msgstr "" -#: ../config.c:140 +#: ../config.c:174 msgid "Wrap scrolling" msgstr "Плавне прокручування" -#: ../config.c:142 +#: ../config.c:176 +msgid "Page aware scrolling" +msgstr "" + +#: ../config.c:178 msgid "Advance number of pages per row" msgstr "" -#: ../config.c:144 +#: ../config.c:180 msgid "Horizontally centered zoom" msgstr "" -#: ../config.c:146 +#: ../config.c:182 msgid "Center result horizontally" msgstr "" -#: ../config.c:148 +#: ../config.c:184 msgid "Transparency for highlighting" msgstr "Прозорість для виділення" -#: ../config.c:150 +#: ../config.c:186 msgid "Render 'Loading ...'" msgstr "Рендер 'Завантажується ...'" -#: ../config.c:151 +#: ../config.c:187 msgid "Adjust to when opening file" msgstr "Підлаштовутись при відкритті файлу" -#: ../config.c:153 +#: ../config.c:189 msgid "Show hidden files and directories" msgstr "Показати приховані файли та директорії" -#: ../config.c:155 +#: ../config.c:191 msgid "Show directories" msgstr "Показати диреторії" -#: ../config.c:157 +#: ../config.c:193 msgid "Always open on first page" msgstr "Завжди відкривати на першій сторінці" -#: ../config.c:159 +#: ../config.c:195 msgid "Highlight search results" msgstr "" -#: ../config.c:161 +#: ../config.c:197 +msgid "Enable incremental search" +msgstr "" + +#: ../config.c:199 msgid "Clear search results on abort" msgstr "" -#: ../config.c:163 +#: ../config.c:201 msgid "Use basename of the file in the window title" msgstr "" -#: ../config.c:165 ../main.c:60 +#: ../config.c:203 ../main.c:60 msgid "Enable synctex support" msgstr "" #. define default inputbar commands -#: ../config.c:293 +#: ../config.c:359 msgid "Add a bookmark" msgstr "Додати закладку" -#: ../config.c:294 +#: ../config.c:360 msgid "Delete a bookmark" msgstr "Вилучити закладку" -#: ../config.c:295 +#: ../config.c:361 msgid "List all bookmarks" msgstr "Дивитись усі закладки" -#: ../config.c:296 +#: ../config.c:362 msgid "Close current file" msgstr "Закрити документ" -#: ../config.c:297 +#: ../config.c:363 msgid "Show file information" msgstr "Показати інформацію файлу" -#: ../config.c:298 +#: ../config.c:364 msgid "Execute a command" msgstr "" -#: ../config.c:299 +#: ../config.c:365 msgid "Show help" msgstr "Показати довідку" -#: ../config.c:300 +#: ../config.c:366 msgid "Open document" msgstr "Відкрити документ" -#: ../config.c:301 +#: ../config.c:367 msgid "Close zathura" msgstr "Вийти із zathura" -#: ../config.c:302 +#: ../config.c:368 msgid "Print document" msgstr "Друкувати документ" -#: ../config.c:303 +#: ../config.c:369 msgid "Save document" msgstr "Зберегти документ" -#: ../config.c:304 +#: ../config.c:370 msgid "Save document (and force overwriting)" msgstr "Зберегти документ (форсувати перезапис)" -#: ../config.c:305 +#: ../config.c:371 msgid "Save attachments" msgstr "Зберегти прикріплення" -#: ../config.c:306 +#: ../config.c:372 msgid "Set page offset" msgstr "Встановити зміщення сторінки" -#: ../config.c:307 +#: ../config.c:373 msgid "Mark current location within the document" msgstr "" -#: ../config.c:308 +#: ../config.c:374 msgid "Delete the specified marks" msgstr "" -#: ../config.c:309 +#: ../config.c:375 msgid "Don't highlight current search results" msgstr "" -#: ../config.c:310 +#: ../config.c:376 msgid "Highlight current search results" msgstr "" -#: ../config.c:311 +#: ../config.c:377 msgid "Show version information" msgstr "" -#: ../links.c:162 ../links.c:219 +#: ../links.c:161 ../links.c:240 msgid "Failed to run xdg-open." msgstr "Запуск xdg-open не вдався." +#: ../links.c:179 +#, c-format +msgid "Link: page %d" +msgstr "" + +#: ../links.c:186 +#, c-format +msgid "Link: %s" +msgstr "" + +#: ../links.c:190 +msgid "Link: Invalid" +msgstr "" + #: ../main.c:52 msgid "Reparents to window specified by xid" msgstr "Вертатися до вікна, вказаного xid" @@ -383,27 +414,27 @@ msgstr "Показати інформацію файлу" msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: ../page-widget.c:456 +#: ../page-widget.c:455 msgid "Loading..." msgstr "" -#: ../page-widget.c:643 +#: ../page-widget.c:646 #, c-format msgid "Copied selected text to clipboard: %s" msgstr "Вибраний текст скопійовано до буферу: %s" -#: ../page-widget.c:741 +#: ../page-widget.c:744 msgid "Copy image" msgstr "Копіювати картинку" -#: ../page-widget.c:742 +#: ../page-widget.c:745 msgid "Save image as" msgstr "" -#: ../shortcuts.c:825 +#: ../shortcuts.c:956 msgid "This document does not contain any index" msgstr "Індекс відсутній в цьому документі" -#: ../zathura.c:189 ../zathura.c:843 +#: ../zathura.c:193 ../zathura.c:865 msgid "[No name]" msgstr "[Без назви]" diff --git a/print.c b/print.c index f404738..b32e5b3 100644 --- a/print.c +++ b/print.c @@ -9,12 +9,12 @@ #include static void cb_print_draw_page(GtkPrintOperation* print_operation, - GtkPrintContext* context, gint page_number, zathura_t* zathura); + GtkPrintContext* context, gint page_number, zathura_t* zathura); static void cb_print_end(GtkPrintOperation* print_operation, GtkPrintContext* - context, zathura_t* zathura); + context, zathura_t* zathura); static void cb_print_request_page_setup(GtkPrintOperation* print_operation, - GtkPrintContext* context, gint page_number, GtkPageSetup* setup, zathura_t* - zathura); + GtkPrintContext* context, gint page_number, GtkPageSetup* setup, zathura_t* + zathura); void print(zathura_t* zathura) @@ -37,6 +37,7 @@ print(zathura_t* zathura) gtk_print_operation_set_n_pages(print_operation, zathura_document_get_number_of_pages(zathura->document)); gtk_print_operation_set_current_page(print_operation, zathura_document_get_current_page_number(zathura->document)); gtk_print_operation_set_use_full_page(print_operation, TRUE); + gtk_print_operation_set_embed_page_setup(print_operation, TRUE); /* print operation signals */ g_signal_connect(print_operation, "draw-page", G_CALLBACK(cb_print_draw_page), zathura); @@ -45,7 +46,7 @@ print(zathura_t* zathura) /* print */ GtkPrintOperationResult result = gtk_print_operation_run(print_operation, - GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG, NULL, NULL); + GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG, NULL, NULL); if (result == GTK_PRINT_OPERATION_RESULT_APPLY) { if (zathura->print.settings != NULL) { @@ -67,7 +68,7 @@ print(zathura_t* zathura) static void cb_print_end(GtkPrintOperation* UNUSED(print_operation), GtkPrintContext* - UNUSED(context), zathura_t* zathura) + UNUSED(context), zathura_t* zathura) { if (zathura == NULL || zathura->ui.session == NULL || zathura->document == NULL) { return; @@ -77,42 +78,97 @@ cb_print_end(GtkPrintOperation* UNUSED(print_operation), GtkPrintContext* if (file_path != NULL) { girara_statusbar_item_set_text(zathura->ui.session, - zathura->ui.statusbar.file, file_path); + zathura->ui.statusbar.file, file_path); } } static void -cb_print_draw_page(GtkPrintOperation* UNUSED(print_operation), GtkPrintContext* - context, gint page_number, zathura_t* zathura) +cb_print_draw_page(GtkPrintOperation* print_operation, GtkPrintContext* + context, gint page_number, zathura_t* zathura) { if (context == NULL || zathura == NULL || zathura->document == NULL || zathura->ui.session == NULL || zathura->ui.statusbar.file == NULL) { + gtk_print_operation_cancel(print_operation); return; } - /* update statusbar */ + /* Update statusbar. */ char* tmp = g_strdup_printf("Printing %d...", page_number); girara_statusbar_item_set_text(zathura->ui.session, - zathura->ui.statusbar.file, tmp); + zathura->ui.statusbar.file, tmp); g_free(tmp); - /* render page */ + /* Get the page and cairo handle. */ cairo_t* cairo = gtk_print_context_get_cairo_context(context); zathura_page_t* page = zathura_document_get_page(zathura->document, page_number); if (cairo == NULL || page == NULL) { + gtk_print_operation_cancel(print_operation); return; } + /* Try to render the page without a temporary surface. This only works with + * plugins that support rendering to any surface. */ girara_debug("printing page %d ...", page_number); render_lock(zathura->sync.render_thread); - zathura_page_render(page, cairo, true); + int err = zathura_page_render(page, cairo, true); render_unlock(zathura->sync.render_thread); + if (err == ZATHURA_ERROR_OK) { + return; + } + + /* Try to render the page on a temporary image surface. */ + const gdouble width = gtk_print_context_get_width(context); + const gdouble height = gtk_print_context_get_height(context); + + const double page_height = zathura_page_get_height(page); + const double page_width = zathura_page_get_width(page); + cairo_surface_t* surface = cairo_image_surface_create(CAIRO_FORMAT_RGB24, page_width, page_height); + if (surface == NULL) { + gtk_print_operation_cancel(print_operation); + return; + } + + cairo_t* temp_cairo = cairo_create(surface); + if (cairo == NULL) { + gtk_print_operation_cancel(print_operation); + cairo_surface_destroy(surface); + return; + } + + /* Draw a white background. */ + cairo_save(temp_cairo); + cairo_set_source_rgb(temp_cairo, 1, 1, 1); + cairo_rectangle(temp_cairo, 0, 0, page_width, page_height); + cairo_fill(temp_cairo); + cairo_restore(temp_cairo); + + /* Render the page to the temporary surface */ + girara_debug("printing page %d ...", page_number); + render_lock(zathura->sync.render_thread); + err = zathura_page_render(page, temp_cairo, true); + render_unlock(zathura->sync.render_thread); + if (err != ZATHURA_ERROR_OK) { + cairo_destroy(temp_cairo); + cairo_surface_destroy(surface); + gtk_print_operation_cancel(print_operation); + return; + } + + /* Rescale the page and keep the aspect ratio */ + const gdouble scale = MIN(width / page_width, height / page_height); + cairo_scale(cairo, scale, scale); + + /* Blit temporary surface to original cairo object. */ + cairo_set_source_surface(cairo, surface, 0.0, 0.0); + cairo_paint(cairo); + cairo_destroy(temp_cairo); + cairo_surface_destroy(surface); } static void cb_print_request_page_setup(GtkPrintOperation* UNUSED(print_operation), - GtkPrintContext* UNUSED(context), gint page_number, GtkPageSetup* setup, - zathura_t* zathura) + GtkPrintContext* UNUSED(context), gint page_number, GtkPageSetup* setup, + zathura_t* zathura) { if (zathura == NULL || zathura->document == NULL) { return; diff --git a/render.c b/render.c index 65f5b4b..c410e66 100644 --- a/render.c +++ b/render.c @@ -17,10 +17,9 @@ static void render_job(void* data, void* user_data); static bool render(zathura_t* zathura, zathura_page_t* page); static gint render_thread_sort(gconstpointer a, gconstpointer b, gpointer data); -struct render_thread_s -{ +struct render_thread_s { GThreadPool* pool; /**< Pool of threads */ - GStaticMutex mutex; /**< Render lock */ + GMutex mutex; /**< Render lock */ bool about_to_close; /**< Render thread is to be freed */ }; @@ -52,7 +51,7 @@ render_init(zathura_t* zathura) render_thread->about_to_close = false; g_thread_pool_set_sort_function(render_thread->pool, render_thread_sort, zathura); - g_static_mutex_init(&render_thread->mutex); + g_mutex_init(&render_thread->mutex); return render_thread; @@ -74,7 +73,6 @@ render_free(render_thread_t* render_thread) g_thread_pool_free(render_thread->pool, TRUE, TRUE); } - g_static_mutex_free(&render_thread->mutex); g_free(render_thread); } @@ -330,7 +328,7 @@ render_lock(render_thread_t* render_thread) return; } - g_static_mutex_lock(&render_thread->mutex); + g_mutex_lock(&render_thread->mutex); } void @@ -340,5 +338,5 @@ render_unlock(render_thread_t* render_thread) return; } - g_static_mutex_unlock(&render_thread->mutex); + g_mutex_unlock(&render_thread->mutex); } diff --git a/shortcuts.c b/shortcuts.c index ecd72c5..9a33d22 100644 --- a/shortcuts.c +++ b/shortcuts.c @@ -18,9 +18,42 @@ #include "print.h" #include "page-widget.h" +/* Helper function; see sc_display_link and sc_follow. */ +static bool +draw_links(zathura_t* zathura) +{ + /* set pages to draw links */ + bool show_links = false; + unsigned int page_offset = 0; + unsigned int number_of_pages = zathura_document_get_number_of_pages(zathura->document); + for (unsigned int page_id = 0; page_id < number_of_pages; page_id++) { + zathura_page_t* page = zathura_document_get_page(zathura->document, page_id); + if (page == NULL) { + continue; + } + + GtkWidget* page_widget = zathura_page_get_widget(zathura, page); + g_object_set(page_widget, "search-results", NULL, NULL); + if (zathura_page_get_visibility(page) == true) { + g_object_set(page_widget, "draw-links", TRUE, NULL); + + int number_of_links = 0; + g_object_get(page_widget, "number-of-links", &number_of_links, NULL); + if (number_of_links != 0) { + show_links = true; + } + g_object_set(page_widget, "offset-links", page_offset, NULL); + page_offset += number_of_links; + } else { + g_object_set(page_widget, "draw-links", FALSE, NULL); + } + } + return show_links; +} + bool sc_abort(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -38,7 +71,7 @@ sc_abort(girara_session_t* session, girara_argument_t* UNUSED(argument), } g_object_set(zathura_page_get_widget(zathura, page), "draw-links", FALSE, NULL); - if (clear_search) { + if (clear_search == true) { g_object_set(zathura_page_get_widget(zathura, page), "search-results", NULL, NULL); } } @@ -52,7 +85,7 @@ sc_abort(girara_session_t* session, girara_argument_t* UNUSED(argument), bool sc_adjust_window(girara_session_t* session, girara_argument_t* argument, - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -65,6 +98,9 @@ sc_adjust_window(girara_session_t* session, girara_argument_t* argument, unsigned int first_page_column = 1; girara_setting_get(session, "first-page-column", &first_page_column); + int padding = 1; + girara_setting_get(zathura->ui.session, "page-padding", &padding); + if (zathura->ui.page_widget == NULL || zathura->document == NULL) { goto error_ret; } @@ -79,8 +115,8 @@ sc_adjust_window(girara_session_t* session, girara_argument_t* argument, /* get window size */ GtkAllocation allocation; gtk_widget_get_allocation(session->gtk.view, &allocation); - double width = allocation.width; - double height = allocation.height; + unsigned int width = allocation.width; + unsigned int height = allocation.height; /* scrollbar spacing */ gint spacing; @@ -90,75 +126,58 @@ sc_adjust_window(girara_session_t* session, girara_argument_t* argument, /* correct view size */ if (gtk_widget_get_visible(GTK_WIDGET(session->gtk.inputbar)) == true) { gtk_widget_get_allocation(session->gtk.inputbar, &allocation); - width += allocation.width; height += allocation.height; } - /* calculate total width and max-height */ - double total_width = 0; - double total_height = 0; - double max_height = 0; - double max_width = 0; + double scale = 1.0; + unsigned int cell_height = 0, cell_width = 0; + unsigned int document_height = 0, document_width = 0; - unsigned int number_of_pages = zathura_document_get_number_of_pages(zathura->document); - for (unsigned int page_id = 0; page_id < pages_per_row; page_id++) { - if (page_id == number_of_pages) { - break; - } + zathura_document_set_scale(zathura->document, scale); + zathura_document_get_cell_size(zathura->document, &cell_height, &cell_width); + zathura_get_document_size(zathura, cell_height, cell_width, + &document_height, &document_width); - zathura_page_t* page = zathura_document_get_page(zathura->document, page_id); - if (page == NULL) { - goto error_ret; - } + double page_ratio = (double)cell_height / (double)document_width; + double window_ratio = (double)height / (double)width; - unsigned int page_height = zathura_page_get_height(page); - unsigned int page_width = zathura_page_get_width(page); + if (argument->n == ZATHURA_ADJUST_WIDTH || + (argument->n == ZATHURA_ADJUST_BESTFIT && page_ratio < window_ratio)) { + scale = (double)(width - (pages_per_row - 1) * padding) / + (double)(pages_per_row * cell_width); + zathura_document_set_scale(zathura->document, scale); - if (page_height > max_height) { - max_height = page_height; - } + bool show_scrollbars = false; + girara_setting_get(session, "show-scrollbars", &show_scrollbars); - if (page_width > max_width) { - max_width = page_width; - } + if (show_scrollbars) { + /* If the document is taller than the view, there's a vertical + * scrollbar; we need to substract its width from the view's width. */ + zathura_get_document_size(zathura, cell_height, cell_width, + &document_height, &document_width); + if (height < document_height) { + GtkWidget* vscrollbar = gtk_scrolled_window_get_vscrollbar( + GTK_SCROLLED_WINDOW(session->gtk.view)); - total_width += page_width; - total_height += page_height; - } - - unsigned int rotation = zathura_document_get_rotation(zathura->document); - double page_ratio = max_height / total_width; - double window_ratio = height / width; - - if (rotation == 90 || rotation == 270) { - page_ratio = max_width / total_height; - } - - switch (argument->n) { - case ZATHURA_ADJUST_WIDTH: - if (rotation == 0 || rotation == 180) { - zathura_document_set_scale(zathura->document, width / total_width); - } else { - zathura_document_set_scale(zathura->document, width / total_height); - } - break; - case ZATHURA_ADJUST_BESTFIT: - if (rotation == 0 || rotation == 180) { - if (page_ratio < window_ratio) { - zathura_document_set_scale(zathura->document, width / total_width); - } else { - zathura_document_set_scale(zathura->document, height / max_height); - } - } else { - if (page_ratio < window_ratio) { - zathura_document_set_scale(zathura->document, width / total_height); - } else { - zathura_document_set_scale(zathura->document, height / max_width); + if (vscrollbar != NULL) { + GtkRequisition requisition; + gtk_widget_get_requisition(vscrollbar, &requisition); + if (0 < requisition.width && (unsigned)requisition.width < width) { + width -= requisition.width; + scale = (double)(width - (pages_per_row - 1) * padding) / + (double)(pages_per_row * cell_width); + zathura_document_set_scale(zathura->document, scale); + } } } - break; - default: - goto error_ret; + } + } + else if (argument->n == ZATHURA_ADJUST_BESTFIT) { + scale = (double)height / (double)cell_height; + zathura_document_set_scale(zathura->document, scale); + } + else { + goto error_ret; } /* keep position */ @@ -174,7 +193,7 @@ error_ret: bool sc_change_mode(girara_session_t* session, girara_argument_t* argument, - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); @@ -183,6 +202,30 @@ sc_change_mode(girara_session_t* session, girara_argument_t* argument, return false; } +bool +sc_display_link(girara_session_t* session, girara_argument_t* UNUSED(argument), + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) +{ + g_return_val_if_fail(session != NULL, false); + g_return_val_if_fail(session->global.data != NULL, false); + zathura_t* zathura = session->global.data; + + if (zathura->document == NULL || zathura->ui.session == NULL) { + return false; + } + + bool show_links = draw_links(zathura); + + /* ask for input */ + if (show_links) { + girara_dialog(zathura->ui.session, "Display link:", FALSE, NULL, + (girara_callback_inputbar_activate_t) cb_sc_display_link, + zathura->ui.session); + } + + return false; +} + bool sc_focus_inputbar(girara_session_t* session, girara_argument_t* argument, girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { @@ -239,7 +282,7 @@ sc_focus_inputbar(girara_session_t* session, girara_argument_t* argument, girara bool sc_follow(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -249,32 +292,7 @@ sc_follow(girara_session_t* session, girara_argument_t* UNUSED(argument), return false; } - /* set pages to draw links */ - bool show_links = false; - unsigned int page_offset = 0; - unsigned int number_of_pages = zathura_document_get_number_of_pages(zathura->document); - for (unsigned int page_id = 0; page_id < number_of_pages; page_id++) { - zathura_page_t* page = zathura_document_get_page(zathura->document, page_id); - if (page == NULL) { - continue; - } - - GtkWidget* page_widget = zathura_page_get_widget(zathura, page); - g_object_set(page_widget, "search-results", NULL, NULL); - if (zathura_page_get_visibility(page) == true) { - g_object_set(page_widget, "draw-links", TRUE, NULL); - - int number_of_links = 0; - g_object_get(page_widget, "number-of-links", &number_of_links, NULL); - if (number_of_links != 0) { - show_links = true; - } - g_object_set(page_widget, "offset-links", page_offset, NULL); - page_offset += number_of_links; - } else { - g_object_set(page_widget, "draw-links", FALSE, NULL); - } - } + bool show_links = draw_links(zathura); /* ask for input */ if (show_links == true) { @@ -293,6 +311,7 @@ sc_goto(girara_session_t* session, girara_argument_t* argument, girara_event_t* g_return_val_if_fail(argument != NULL, false); g_return_val_if_fail(zathura->document != NULL, false); + zathura_jumplist_save(zathura); if (t != 0) { /* add offset */ unsigned int page_offset = zathura_document_get_page_offset(zathura->document); @@ -300,13 +319,15 @@ sc_goto(girara_session_t* session, girara_argument_t* argument, girara_event_t* t += page_offset; } - page_set(zathura, t - 1); + page_set(zathura, t-1); } else if (argument->n == TOP) { page_set(zathura, 0); } else if (argument->n == BOTTOM) { page_set(zathura, zathura_document_get_number_of_pages(zathura->document) - 1); } + zathura_jumplist_add(zathura); + return false; } @@ -330,14 +351,14 @@ sc_mouse_scroll(girara_session_t* session, girara_argument_t* argument, girara_e GtkAdjustment* y_adj = NULL; switch (event->type) { - /* scroll */ + /* scroll */ case GIRARA_EVENT_SCROLL_UP: case GIRARA_EVENT_SCROLL_DOWN: case GIRARA_EVENT_SCROLL_LEFT: case GIRARA_EVENT_SCROLL_RIGHT: return sc_scroll(session, argument, NULL, t); - /* drag */ + /* drag */ case GIRARA_EVENT_BUTTON_PRESS: x = event->x; y = event->y; @@ -358,7 +379,7 @@ sc_mouse_scroll(girara_session_t* session, girara_argument_t* argument, girara_e set_adjustment(y_adj, gtk_adjustment_get_value(y_adj) - (event->y - y)); break; - /* unhandled events */ + /* unhandled events */ default: break; } @@ -396,7 +417,7 @@ sc_mouse_zoom(girara_session_t* session, girara_argument_t* argument, girara_eve bool sc_navigate(girara_session_t* session, girara_argument_t* argument, - girara_event_t* UNUSED(event), unsigned int t) + girara_event_t* UNUSED(event), unsigned int t) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -420,20 +441,20 @@ sc_navigate(girara_session_t* session, girara_argument_t* argument, t = (t == 0) ? (unsigned int) offset : t; if (argument->n == NEXT) { - if (scroll_wrap == true) { + if (scroll_wrap == false) { new_page = new_page + t; } else { new_page = (new_page + t) % number_of_pages; } } else if (argument->n == PREVIOUS) { - if (scroll_wrap == true) { + if (scroll_wrap == false) { new_page = new_page - t; } else { new_page = (new_page + number_of_pages - t) % number_of_pages; } } - if (scroll_wrap == true && (new_page < 0 || new_page >= number_of_pages)) { + if ((new_page < 0 || new_page >= number_of_pages) && !scroll_wrap) { return false; } @@ -444,7 +465,7 @@ sc_navigate(girara_session_t* session, girara_argument_t* argument, bool sc_print(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -462,7 +483,7 @@ sc_print(girara_session_t* session, girara_argument_t* UNUSED(argument), bool sc_recolor(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); @@ -476,7 +497,7 @@ sc_recolor(girara_session_t* session, girara_argument_t* UNUSED(argument), bool sc_reload(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -497,7 +518,7 @@ sc_reload(girara_session_t* session, girara_argument_t* UNUSED(argument), bool sc_rotate(girara_session_t* session, girara_argument_t* argument, - girara_event_t* UNUSED(event), unsigned int t) + girara_event_t* UNUSED(event), unsigned int t) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -530,7 +551,7 @@ sc_rotate(girara_session_t* session, girara_argument_t* argument, bool sc_scroll(girara_session_t* session, girara_argument_t* argument, - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -542,7 +563,7 @@ sc_scroll(girara_session_t* session, girara_argument_t* argument, GtkAdjustment* adjustment = NULL; if ( (argument->n == LEFT) || (argument->n == FULL_LEFT) || (argument->n == HALF_LEFT) || - (argument->n == RIGHT) || (argument->n == FULL_RIGHT) || (argument->n == HALF_RIGHT)) { + (argument->n == RIGHT) || (argument->n == FULL_RIGHT) || (argument->n == HALF_RIGHT)) { adjustment = gtk_scrolled_window_get_hadjustment(GTK_SCROLLED_WINDOW(session->gtk.view)); } else { adjustment = gtk_scrolled_window_get_vadjustment(GTK_SCROLLED_WINDOW(session->gtk.view)); @@ -560,6 +581,14 @@ sc_scroll(girara_session_t* session, girara_argument_t* argument, if (scroll_hstep < 0) { scroll_hstep = scroll_step; } + float scroll_full_overlap = 0.0; + girara_setting_get(session, "scroll-full-overlap", &scroll_full_overlap); + bool scroll_page_aware = false; + girara_setting_get(session, "scroll-page-aware", &scroll_page_aware); + + bool scroll_wrap = false; + girara_setting_get(session, "scroll-wrap", &scroll_wrap); + int padding = 1; girara_setting_get(session, "page-padding", &padding); @@ -568,11 +597,11 @@ sc_scroll(girara_session_t* session, girara_argument_t* argument, switch(argument->n) { case FULL_UP: case FULL_LEFT: - new_value = value - view_size - padding; + new_value = value - (1.0 - scroll_full_overlap) * view_size - padding; break; case FULL_DOWN: case FULL_RIGHT: - new_value = value + view_size + padding; + new_value = value + (1.0 - scroll_full_overlap) * view_size + padding; break; case HALF_UP: case HALF_LEFT: @@ -604,14 +633,107 @@ sc_scroll(girara_session_t* session, girara_argument_t* argument, new_value = value; } + if (scroll_wrap == true) { + if (new_value < 0) + new_value = max; + else if (new_value > max) + new_value = 0; + } + + if (scroll_page_aware == true) { + int page_offset; + double page_size; + + { + unsigned int page_id = zathura_document_get_current_page_number(zathura->document); + zathura_page_t* page = zathura_document_get_page(zathura->document, page_id); + page_offset_t offset; + page_calculate_offset(zathura, page, &offset); + + double scale = zathura_document_get_scale(zathura->document); + + if ((argument->n == LEFT) || (argument->n == FULL_LEFT) || (argument->n == HALF_LEFT) || + (argument->n == RIGHT) || (argument->n == FULL_RIGHT) || (argument->n == HALF_RIGHT)) { + page_offset = offset.x; + page_size = zathura_page_get_width(page) * scale; + } else { + page_offset = offset.y; + page_size = zathura_page_get_height(page) * scale; + } + + page_offset -= padding / 2; + page_size += padding; + } + + if ((argument->n == FULL_DOWN) || (argument->n == HALF_DOWN) || + (argument->n == FULL_RIGHT) || (argument->n == HALF_RIGHT)) { + if ((page_offset > value) && + (page_offset < value + view_size)) { + new_value = page_offset; + } else if ((page_offset <= value) && + (page_offset + page_size < value + view_size)) { + new_value = page_offset + page_size + 1; + } else if ((page_offset <= value) && + (page_offset + page_size < new_value + view_size)) { + new_value = page_offset + page_size - view_size + 1; + } + } else if ((argument->n == FULL_UP) || (argument->n == HALF_UP) || + (argument->n == FULL_LEFT) || (argument->n == HALF_LEFT)) { + if ((page_offset + 1 >= value) && + (page_offset < value + view_size)) { + new_value = page_offset - view_size; + } else if ((page_offset <= value) && + (page_offset + page_size + 1 < value + view_size)) { + new_value = page_offset + page_size - view_size; + } else if ((page_offset <= value) && + (page_offset > new_value)) { + new_value = page_offset; + } + } + } + set_adjustment(adjustment, new_value); return false; } + +bool +sc_jumplist(girara_session_t* session, girara_argument_t* argument, girara_event_t* UNUSED(event), unsigned int UNUSED(t)) +{ + g_return_val_if_fail(session != NULL, false); + g_return_val_if_fail(session->global.data != NULL, false); + zathura_t* zathura = session->global.data; + g_return_val_if_fail(argument != NULL, false); + g_return_val_if_fail(zathura->document != NULL, false); + + zathura_jump_t* jump = NULL; + switch(argument->n) { + case FORWARD: + zathura_jumplist_save(zathura); + zathura_jumplist_forward(zathura); + jump = zathura_jumplist_current(zathura); + break; + + case BACKWARD: + zathura_jumplist_save(zathura); + zathura_jumplist_backward(zathura); + jump = zathura_jumplist_current(zathura); + break; + } + + if (jump != NULL) { + page_set(zathura, jump->page); + const double s = zathura_document_get_scale(zathura->document); + position_set_delayed(zathura, jump->x * s, jump->y * s); + } + + return false; +} + bool sc_search(girara_session_t* session, girara_argument_t* argument, - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -621,7 +743,10 @@ sc_search(girara_session_t* session, girara_argument_t* argument, const int num_pages = zathura_document_get_number_of_pages(zathura->document); const int cur_page = zathura_document_get_current_page_number(zathura->document); + int diff = argument->n == FORWARD ? 1 : -1; + if (zathura->global.search_direction == BACKWARD) + diff = -diff; zathura_page_t* target_page = NULL; int target_idx = 0; @@ -637,7 +762,7 @@ sc_search(girara_session_t* session, girara_argument_t* argument, int num_search_results = 0, current = -1; g_object_get(page_widget, "search-current", ¤t, - "search-length", &num_search_results, NULL); + "search-length", &num_search_results, NULL); if (num_search_results == 0 || current == -1) { continue; } @@ -651,6 +776,8 @@ sc_search(girara_session_t* session, girara_argument_t* argument, target_idx = current - 1; } else { /* the next result is on a different page */ + zathura_jumplist_save(zathura); + g_object_set(page_widget, "search-current", -1, NULL); for (int npage_id = 1; page_id < num_pages; ++npage_id) { @@ -665,6 +792,8 @@ sc_search(girara_session_t* session, girara_argument_t* argument, break; } } + + zathura_jumplist_add(zathura); } break; @@ -699,7 +828,7 @@ sc_search(girara_session_t* session, girara_argument_t* argument, bool sc_navigate_index(girara_session_t* session, girara_argument_t* argument, - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -736,7 +865,7 @@ sc_navigate_index(girara_session_t* session, girara_argument_t* argument, gtk_tree_model_get_iter(model, &iter, path); /* select last child */ gtk_tree_model_iter_nth_child(model, &child_iter, &iter, - gtk_tree_model_iter_n_children(model, &iter)-1); + gtk_tree_model_iter_n_children(model, &iter)-1); gtk_tree_path_free(path); path = gtk_tree_model_get_path(model, &child_iter); } @@ -744,7 +873,7 @@ sc_navigate_index(girara_session_t* session, girara_argument_t* argument, break; case COLLAPSE: if (gtk_tree_view_collapse_row(tree_view, path) == FALSE - && gtk_tree_path_get_depth(path) > 1) { + && gtk_tree_path_get_depth(path) > 1) { gtk_tree_path_up(path); gtk_tree_view_collapse_row(tree_view, path); } @@ -756,11 +885,12 @@ sc_navigate_index(girara_session_t* session, girara_argument_t* argument, do { gtk_tree_model_get_iter(model, &iter, path); if (gtk_tree_model_iter_next(model, &iter)) { + gtk_tree_path_free(path); path = gtk_tree_model_get_path(model, &iter); break; } } while((is_valid_path = (gtk_tree_path_get_depth(path) > 1)) - && gtk_tree_path_up(path)); + && gtk_tree_path_up(path)); } break; case EXPAND: @@ -779,6 +909,7 @@ sc_navigate_index(girara_session_t* session, girara_argument_t* argument, break; case SELECT: cb_index_row_activated(tree_view, path, NULL, zathura); + gtk_tree_path_free(path); return false; } @@ -793,7 +924,7 @@ sc_navigate_index(girara_session_t* session, girara_argument_t* argument, bool sc_toggle_index(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -817,7 +948,7 @@ sc_toggle_index(girara_session_t* session, girara_argument_t* UNUSED(argument), } gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(zathura->ui.index), - GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC); + GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC); /* create index */ document_index = zathura_document_index_generate(zathura->document, NULL); @@ -884,6 +1015,9 @@ sc_toggle_index(girara_session_t* session, girara_argument_t* UNUSED(argument), vvalue = gtk_adjustment_get_value(vadjustment); hvalue = gtk_adjustment_get_value(hadjustment); + /* save current position to the jumplist */ + zathura_jumplist_save(zathura); + girara_set_view(session, zathura->ui.index); gtk_widget_show(GTK_WIDGET(zathura->ui.index)); girara_mode_set(zathura->ui.session, zathura->modes.index); @@ -907,9 +1041,38 @@ error_ret: return false; } +bool +sc_toggle_page_mode(girara_session_t* session, girara_argument_t* + UNUSED(argument), girara_event_t* UNUSED(event), unsigned int UNUSED(t)) +{ + g_return_val_if_fail(session != NULL, false); + g_return_val_if_fail(session->global.data != NULL, false); + zathura_t* zathura = session->global.data; + + if (zathura->document == NULL) { + girara_notify(session, GIRARA_WARNING, _("No document opened.")); + return false; + } + + int pages_per_row = 1; + girara_setting_get(zathura->ui.session, "pages-per-row", &pages_per_row); + + static int tmp = 2; + int value = 1; + if (pages_per_row == 1) { + value = tmp; + } else { + tmp = pages_per_row; + } + + girara_setting_set(zathura->ui.session, "pages-per-row", &value); + + return true; +} + bool sc_toggle_fullscreen(girara_session_t* session, girara_argument_t* - UNUSED(argument), girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + UNUSED(argument), girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); @@ -942,6 +1105,9 @@ sc_toggle_fullscreen(girara_session_t* session, girara_argument_t* zathura_document_set_scale(zathura->document, zoom); render_all(zathura); page_set_delayed(zathura, zathura_document_get_current_page_number(zathura->document)); + + /* setm ode */ + girara_mode_set(session, zathura->modes.normal); } else { /* backup pages per row */ girara_setting_get(session, "pages-per-row", &pages_per_row); @@ -967,6 +1133,9 @@ sc_toggle_fullscreen(girara_session_t* session, girara_argument_t* /* set full screen */ gtk_window_fullscreen(GTK_WINDOW(session->gtk.window)); page_set_delayed(zathura, zathura_document_get_current_page_number(zathura->document)); + + /* setm ode */ + girara_mode_set(session, zathura->modes.fullscreen); } fullscreen = fullscreen ? false : true; @@ -976,7 +1145,7 @@ sc_toggle_fullscreen(girara_session_t* session, girara_argument_t* bool sc_quit(girara_session_t* session, girara_argument_t* UNUSED(argument), - girara_event_t* UNUSED(event), unsigned int UNUSED(t)) + girara_event_t* UNUSED(event), unsigned int UNUSED(t)) { g_return_val_if_fail(session != NULL, false); @@ -990,7 +1159,7 @@ sc_quit(girara_session_t* session, girara_argument_t* UNUSED(argument), bool sc_zoom(girara_session_t* session, girara_argument_t* argument, girara_event_t* - UNUSED(event), unsigned int t) + UNUSED(event), unsigned int t) { g_return_val_if_fail(session != NULL, false); g_return_val_if_fail(session->global.data != NULL, false); diff --git a/shortcuts.h b/shortcuts.h index 191c1af..3572cf1 100644 --- a/shortcuts.h +++ b/shortcuts.h @@ -38,6 +38,17 @@ bool sc_adjust_window(girara_session_t* session, girara_argument_t* argument, gi */ bool sc_change_mode(girara_session_t* session, girara_argument_t* argument, girara_event_t* event, unsigned int t); +/** + * Display a link + * + * @param session The used girara session + * @param argument The used argument + * @param event Girara event + * @param t Number of executions + * @return true if no error occured otherwise false + */ +bool sc_display_link(girara_session_t* session, girara_argument_t* argument, girara_event_t* event, unsigned int t); + /** * Shortcut function to focus the inputbar * @@ -160,6 +171,17 @@ bool sc_rotate(girara_session_t* session, girara_argument_t* argument, girara_ev */ bool sc_scroll(girara_session_t* session, girara_argument_t* argument, girara_event_t* event, unsigned int t); +/** + * Scroll through the pages + * + * @param session The used girara session + * @param argument The used argument + * @param event Girara event + * @param t Number of executions + * @return true if no error occured otherwise false + */ +bool sc_jumplist(girara_session_t* session, girara_argument_t* argument, girara_event_t* event, unsigned int t); + /** * Search through the document for the latest search item * @@ -193,6 +215,17 @@ bool sc_navigate_index(girara_session_t* session, girara_argument_t* argument, g */ bool sc_toggle_index(girara_session_t* session, girara_argument_t* argument, girara_event_t* event, unsigned int t); +/** + * Toggle multi page mode + * + * @param session The used girara session + * @param argument The used argument + * @param event Girara event + * @param t Number of executions + * @return true if no error occured otherwise false + */ +bool sc_toggle_page_mode(girara_session_t* session, girara_argument_t* argument, girara_event_t* event, unsigned int t); + /** * Toggle fullscreen mode * diff --git a/synctex.c b/synctex.c index 9a9c91f..6d8c71f 100644 --- a/synctex.c +++ b/synctex.c @@ -1,25 +1,80 @@ /* See LICENSE file for license and copyright information */ +#include +#include + #include "synctex.h" #include "zathura.h" #include "page.h" #include "document.h" +#include "utils.h" -#include +#include + +enum { + SYNCTEX_RESULT_BEGIN = 1, + SYNCTEX_RESULT_END, + SYNCTEX_PROP_PAGE, + SYNCTEX_PROP_H, + SYNCTEX_PROP_V, + SYNCTEX_PROP_WIDTH, + SYNCTEX_PROP_HEIGHT, +}; + +typedef struct token_s { + const char* name; + guint token; +} token_t; + +static token_t scanner_tokens[] = { + {"SyncTeX result begin", SYNCTEX_RESULT_BEGIN}, + {"SyncTeX result end", SYNCTEX_RESULT_END}, + {"Page:", SYNCTEX_PROP_PAGE}, + {"h:", SYNCTEX_PROP_H}, + {"v:", SYNCTEX_PROP_V}, + {"W:", SYNCTEX_PROP_WIDTH}, + {"H:", SYNCTEX_PROP_HEIGHT}, + {NULL, 0} +}; + +static GScannerConfig scanner_config = { + .cset_skip_characters = "\n\r", + .cset_identifier_first = G_CSET_a_2_z G_CSET_A_2_Z, + .cset_identifier_nth = G_CSET_a_2_z G_CSET_A_2_Z ": ", + .cpair_comment_single = NULL, + .case_sensitive = TRUE, + .scan_identifier = TRUE, + .scan_symbols = TRUE, + .scan_float = TRUE, + .numbers_2_int = TRUE, +}; + +static void synctex_record_hits(zathura_t* zathura, int page_idx, girara_list_t* hits, bool first); +static double scan_float(GScanner* scanner); +static bool synctex_view(zathura_t* zathura, char* position); void synctex_edit(zathura_t* zathura, zathura_page_t* page, int x, int y) { - zathura_document_t* doc = zathura_page_get_document(page); - const char *filename = zathura_document_get_path(doc); - int pageIdx = zathura_page_get_index(page); - - char *buffer = g_strdup_printf("%d:%d:%d:%s", pageIdx+1, x, y, filename); - if (buffer == NULL) + if (zathura == NULL || page == NULL) { return; + } - if (zathura->synctex.editor) { + zathura_document_t* document = zathura_page_get_document(page); + if (document == NULL) { + return; + } + + const char *filename = zathura_document_get_path(document); + if (filename == NULL) { + return; + } + + int page_idx = zathura_page_get_index(page); + char *buffer = g_strdup_printf("%d:%d:%d:%s", page_idx + 1, x, y, filename); + + if (zathura->synctex.editor != NULL) { char* argv[] = {"synctex", "edit", "-o", buffer, "-x", zathura->synctex.editor, NULL}; g_spawn_async(NULL, argv, NULL, G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, NULL); } else { @@ -29,3 +84,155 @@ synctex_edit(zathura_t* zathura, zathura_page_t* page, int x, int y) g_free(buffer); } + +static void +synctex_record_hits(zathura_t* zathura, int page_idx, girara_list_t* hits, bool first) +{ + zathura_page_t* page = zathura_document_get_page(zathura->document, page_idx-1); + if (page == NULL) + return; + + GtkWidget* page_widget = zathura_page_get_widget(zathura, page); + g_object_set(page_widget, "draw-links", FALSE, NULL); + g_object_set(page_widget, "search-results", hits, NULL); + + if (first) { + page_set_delayed(zathura, zathura_page_get_index(page)); + g_object_set(page_widget, "search-current", 0, NULL); + } +} + +static double +scan_float(GScanner* scanner) +{ + switch (g_scanner_get_next_token(scanner)) { + case G_TOKEN_FLOAT: + return g_scanner_cur_value(scanner).v_float; + case G_TOKEN_INT: + return g_scanner_cur_value(scanner).v_int; + default: + return 0.0; + } +} + +static bool +synctex_view(zathura_t* zathura, char* position) +{ + char* filename = g_strdup(zathura_document_get_path(zathura->document)); + char* argv[] = {"synctex", "view", "-i", position, "-o", filename, NULL}; + gint output; + + bool ret = g_spawn_async_with_pipes(NULL, argv, NULL, G_SPAWN_SEARCH_PATH | G_SPAWN_STDERR_TO_DEV_NULL, NULL, NULL, NULL, NULL, &output, NULL, NULL); + g_free(filename); + + if (ret == false) { + return false; + } + + GScanner* scanner = g_scanner_new(&scanner_config); + token_t* tokens = scanner_tokens; + while (tokens->name != NULL) { + g_scanner_add_symbol(scanner, tokens->name, GINT_TO_POINTER(tokens->token)); + tokens++; + } + + g_scanner_input_file(scanner, output); + + bool found_begin = false, found_end = false; + while (found_begin == false && found_end == false) { + switch (g_scanner_get_next_token(scanner)) { + case G_TOKEN_EOF: + found_end = true; + break; + + case G_TOKEN_SYMBOL: + switch (GPOINTER_TO_INT(g_scanner_cur_value(scanner).v_identifier)) { + case SYNCTEX_RESULT_BEGIN: + found_begin = true; + break; + } + break; + + default: + /* skip everything else */ + break; + } + } + + if (found_begin == true) { + unsigned int number_of_pages = zathura_document_get_number_of_pages(zathura->document); + for (unsigned int page_id = 0; page_id < number_of_pages; ++page_id) { + zathura_page_t* page = zathura_document_get_page(zathura->document, page_id); + if (page == NULL) { + continue; + } + g_object_set(zathura_page_get_widget(zathura, page), "search-results", NULL, NULL); + } + } + + ret = false; + int page = -1, nextpage; + girara_list_t* hitlist = NULL; + zathura_rectangle_t* rectangle = NULL; + + while (found_end == false) { + switch (g_scanner_get_next_token(scanner)) { + case G_TOKEN_EOF: + found_end = true; + break; + + case G_TOKEN_SYMBOL: + switch (GPOINTER_TO_INT(g_scanner_cur_value(scanner).v_identifier)) { + case SYNCTEX_RESULT_END: + found_end = true; + break; + + case SYNCTEX_PROP_PAGE: + if (g_scanner_get_next_token(scanner) == G_TOKEN_INT) { + nextpage = g_scanner_cur_value(scanner).v_int; + if (page != nextpage) { + if (hitlist) { + synctex_record_hits(zathura, page, hitlist, !ret); + ret = true; + } + hitlist = girara_list_new2((girara_free_function_t) g_free); + page = nextpage; + } + rectangle = g_malloc0(sizeof(zathura_rectangle_t)); + girara_list_append(hitlist, rectangle); + } + break; + + case SYNCTEX_PROP_H: + rectangle->x1 = scan_float(scanner); + break; + + case SYNCTEX_PROP_V: + rectangle->y2 = scan_float(scanner); + break; + + case SYNCTEX_PROP_WIDTH: + rectangle->x2 = rectangle->x1 + scan_float(scanner); + break; + + case SYNCTEX_PROP_HEIGHT: + rectangle->y1 = rectangle->y2 - scan_float(scanner); + break; + } + break; + + default: + break; + } + } + + if (hitlist != NULL) { + synctex_record_hits(zathura, page, hitlist, !ret); + ret = true; + } + + g_scanner_destroy(scanner); + close(output); + + return ret; +} diff --git a/types.c b/types.c index 8027920..bfddce0 100644 --- a/types.c +++ b/types.c @@ -72,14 +72,14 @@ girara_list_t* zathura_document_information_entry_list_new() { girara_list_t* list = girara_list_new2((girara_free_function_t) - zathura_document_information_entry_free); + zathura_document_information_entry_free); return list; } zathura_document_information_entry_t* zathura_document_information_entry_new(zathura_document_information_type_t type, - const char* value) + const char* value) { if (value == NULL) { return NULL; diff --git a/utils.c b/utils.c index dc765c3..06de445 100644 --- a/utils.c +++ b/utils.c @@ -34,8 +34,7 @@ file_get_extension(const char* path) } unsigned int i = strlen(path); - for (; i > 0; i--) - { + for (; i > 0; i--) { if (*(path + i) != '.') { continue; } else { @@ -146,31 +145,31 @@ execute_command(char* const argv[], char** output) void document_index_build(GtkTreeModel* model, GtkTreeIter* parent, - girara_tree_node_t* tree) + girara_tree_node_t* tree) { girara_list_t* list = girara_node_get_children(tree); GIRARA_LIST_FOREACH(list, girara_tree_node_t*, iter, node) - zathura_index_element_t* index_element = (zathura_index_element_t*)girara_node_get_data(node); + zathura_index_element_t* index_element = (zathura_index_element_t*)girara_node_get_data(node); - zathura_link_type_t type = zathura_link_get_type(index_element->link); - zathura_link_target_t target = zathura_link_get_target(index_element->link); + zathura_link_type_t type = zathura_link_get_type(index_element->link); + zathura_link_target_t target = zathura_link_get_target(index_element->link); - gchar* description = NULL; - if (type == ZATHURA_LINK_GOTO_DEST) { - description = g_strdup_printf("Page %d", target.page_number + 1); - } else { - description = g_strdup(target.value); - } + gchar* description = NULL; + if (type == ZATHURA_LINK_GOTO_DEST) { + description = g_strdup_printf("Page %d", target.page_number + 1); + } else { + description = g_strdup(target.value); + } - GtkTreeIter tree_iter; - gtk_tree_store_append(GTK_TREE_STORE(model), &tree_iter, parent); - gtk_tree_store_set(GTK_TREE_STORE(model), &tree_iter, 0, index_element->title, 1, description, 2, index_element, -1); - g_object_weak_ref(G_OBJECT(model), (GWeakNotify) zathura_index_element_free, index_element); - g_free(description); + GtkTreeIter tree_iter; + gtk_tree_store_append(GTK_TREE_STORE(model), &tree_iter, parent); + gtk_tree_store_set(GTK_TREE_STORE(model), &tree_iter, 0, index_element->title, 1, description, 2, index_element, -1); + g_object_weak_ref(G_OBJECT(model), (GWeakNotify) zathura_index_element_free, index_element); + g_free(description); - if (girara_node_get_num_children(node) > 0) { - document_index_build(model, &tree_iter, node); - } + if (girara_node_get_num_children(node) > 0) { + document_index_build(model, &tree_iter, node); + } GIRARA_LIST_FOREACH_END(list, gchar*, iter, name); } @@ -183,7 +182,7 @@ page_calculate_offset(zathura_t* zathura, zathura_page_t* page, page_offset_t* o GtkWidget* widget = zathura_page_get_widget(zathura, page); g_return_if_fail(gtk_widget_translate_coordinates(widget, - zathura->ui.page_widget, 0, 0, &(offset->x), &(offset->y)) == true); + zathura->ui.page_widget, 0, 0, &(offset->x), &(offset->y)) == true); } zathura_rectangle_t rotate_rectangle(zathura_rectangle_t rectangle, unsigned int degree, int height, int width) @@ -274,7 +273,7 @@ void set_adjustment(GtkAdjustment* adjustment, gdouble value) { gtk_adjustment_set_value(adjustment, MAX(gtk_adjustment_get_lower(adjustment), - MIN(gtk_adjustment_get_upper(adjustment) - gtk_adjustment_get_page_size(adjustment), value))); + MIN(gtk_adjustment_get_upper(adjustment) - gtk_adjustment_get_page_size(adjustment), value))); } void @@ -300,6 +299,43 @@ page_calc_height_width(zathura_page_t* page, unsigned int* page_height, unsigned } } +void +zathura_get_document_size(zathura_t* zathura, + unsigned int cell_height, unsigned int cell_width, + unsigned int* height, unsigned int* width) +{ + g_return_if_fail(zathura != NULL && zathura->document != NULL && + height != NULL && width != NULL); + + unsigned int pages_per_row = 1; + girara_setting_get(zathura->ui.session, "pages-per-row", &pages_per_row); + if (pages_per_row == 0) + pages_per_row = 1; + + unsigned int first_page_column = 1; + girara_setting_get(zathura->ui.session, "first-page-column", &first_page_column); + if (first_page_column < 1) + first_page_column = 1; + if (first_page_column > pages_per_row) + first_page_column = (first_page_column - 1) % pages_per_row + 1; + + int padding = 1; + girara_setting_get(zathura->ui.session, "page-padding", &padding); + + double scale = zathura_document_get_scale(zathura->document); + + cell_height = ceil(cell_height * scale); + cell_width = ceil(cell_width * scale); + + *width = pages_per_row * cell_width + (pages_per_row - 1) * padding; + unsigned int effective_number_of_pages = + zathura_document_get_number_of_pages(zathura->document) + + first_page_column - 1; + unsigned int rows = effective_number_of_pages / pages_per_row + + (effective_number_of_pages % pages_per_row ? 1 : 0); + *height = rows * cell_height + (rows - 1) * padding; +} + GtkWidget* zathura_page_get_widget(zathura_t* zathura, zathura_page_t* page) { @@ -357,9 +393,9 @@ document_draw_search_results(zathura_t* zathura, bool value) char* zathura_get_version_string(zathura_t* zathura, bool markup) { - if (zathura == NULL) { - return NULL; - } + if (zathura == NULL) { + return NULL; + } GString* string = g_string_new(NULL); @@ -368,30 +404,30 @@ zathura_get_version_string(zathura_t* zathura, bool markup) g_string_append(string, zathura_version); g_free(zathura_version); - char* format = (markup == true) ? "\n(plugin) %s (%d.%d.%d) (%s)" : "\n(plugin) %s (%d.%d.%d) (%s)"; + char* format = (markup == true) ? "\n(plugin) %s (%d.%d.%d) (%s)" : "\n(plugin) %s (%d.%d.%d) (%s)"; /* plugin information */ girara_list_t* plugins = zathura_plugin_manager_get_plugins(zathura->plugins.manager); if (plugins != NULL) { GIRARA_LIST_FOREACH(plugins, zathura_plugin_t*, iter, plugin) - char* name = zathura_plugin_get_name(plugin); - zathura_plugin_version_t version = zathura_plugin_get_version(plugin); - char* text = g_strdup_printf(format, - (name == NULL) ? "-" : name, - version.major, - version.minor, - version.rev, - zathura_plugin_get_path(plugin) - ); - g_string_append(string, text); - g_free(text); + char* name = zathura_plugin_get_name(plugin); + zathura_plugin_version_t version = zathura_plugin_get_version(plugin); + char* text = g_strdup_printf(format, + (name == NULL) ? "-" : name, + version.major, + version.minor, + version.rev, + zathura_plugin_get_path(plugin) + ); + g_string_append(string, text); + g_free(text); GIRARA_LIST_FOREACH_END(plugins, zathura_plugin_t*, iter, plugin); } - char* version = string->str; - g_string_free(string, FALSE); + char* version = string->str; + g_string_free(string, FALSE); - return version; + return version; } char* diff --git a/utils.h b/utils.h index b531731..45990d0 100644 --- a/utils.h +++ b/utils.h @@ -104,6 +104,23 @@ void set_adjustment(GtkAdjustment* adjust, gdouble value); void page_calc_height_width(zathura_page_t* page, unsigned int* page_height, unsigned int* page_width, bool rotate); +/** + * Compute the size of the entire document to be displayed (in pixels), taking + * into account the scale, the layout of the pages, and the padding between + * them. It should be equal to the allocation of zathura->ui.page_widget once + * it's shown. + * + * @param[in] zathura The zathura instance + * @param[in] cell_height,cell_width The height and width of a cell containing + * a single page; it should be obtained + * using zathura_document_get_cell_size() + * with the document scale set to 1.0 + * @param[out] height,width The height and width of the document + */ +void zathura_get_document_size(zathura_t* zathura, + unsigned int cell_height, unsigned int cell_width, + unsigned int* height, unsigned int* width); + /** * Returns the page widget of the page * diff --git a/zathura.1.rst b/zathura.1.rst index 2f8322f..cd980b4 100644 --- a/zathura.1.rst +++ b/zathura.1.rst @@ -48,10 +48,10 @@ OPTIONS Set log debug level (debug, info, warning, error) -s, --synctex - Enable syntex support + Enable synctex support --x [cmd], --syntec-editor-command [cmd] - Set the syntex editor command +-x [cmd], --synctex-editor-command [cmd] + Set the synctex editor command MOUSE AND KEY BINDINGS ====================== @@ -68,6 +68,8 @@ t, ^f, ^b, space, , y Scroll a full page left, down, up or right gg, G, nG Goto to the first, the last or to the nth page +^o, ^i + Move backward and forward through the jump list ^c, Escape Abort a, s @@ -80,11 +82,13 @@ o, O Open document f Follow links +F + Display link target \: Enter command r Rotate by 90 degrees -^i +^r Recolor R Reload document @@ -169,6 +173,12 @@ The default appearance and behaviour of zathura can be overwritten by modifying the *zathurarc* file (default path: ~/.config/zathura/zathurarc). For a detailed description please consult zathurarc(5). +KNOWN BUGS +========== +If GDK_NATIVE_WINDOWS is enabled you will experience problems with large +documents. In this case zathura might crash or pages cannot be rendered +properly. Disabling GDK_NATIVE_WINDOWS fixes this issue. + SEE ALSO ======== diff --git a/zathura.c b/zathura.c index 191f4a8..b499801 100644 --- a/zathura.c +++ b/zathura.c @@ -3,6 +3,7 @@ #define _BSD_SOURCE #define _XOPEN_SOURCE 700 +#include #include #include #include @@ -32,21 +33,18 @@ #include "page-widget.h" #include "plugin.h" -typedef struct zathura_document_info_s -{ +typedef struct zathura_document_info_s { zathura_t* zathura; const char* path; const char* password; } zathura_document_info_t; -typedef struct page_set_delayed_s -{ +typedef struct page_set_delayed_s { zathura_t* zathura; unsigned int page; } page_set_delayed_t; -typedef struct position_set_delayed_s -{ +typedef struct position_set_delayed_s { zathura_t* zathura; double position_x; double position_y; @@ -64,6 +62,7 @@ zathura_create(void) /* global settings */ zathura->global.recolor = false; zathura->global.update_page_number = true; + zathura->global.search_direction = FORWARD; /* plugins */ zathura->plugins.manager = zathura_plugin_manager_new(); @@ -95,8 +94,13 @@ zathura_init(zathura_t* zathura) } /* create zathura (config/data) directory */ - g_mkdir_with_parents(zathura->config.config_dir, 0771); - g_mkdir_with_parents(zathura->config.data_dir, 0771); + if (g_mkdir_with_parents(zathura->config.config_dir, 0771) == -1) { + girara_error("Could not create '%s': %s", zathura->config.config_dir, strerror(errno)); + } + + if (g_mkdir_with_parents(zathura->config.data_dir, 0771) == -1) { + girara_error("Could not create '%s': %s", zathura->config.data_dir, strerror(errno)); + } /* load plugins */ zathura_plugin_manager_load(zathura->plugins.manager); @@ -208,11 +212,11 @@ zathura_init(zathura_t* zathura) girara_setting_get(zathura->ui.session, "database", &database); if (g_strcmp0(database, "plain") == 0) { - girara_info("Using plain database backend."); + girara_debug("Using plain database backend."); zathura->database = zathura_plaindatabase_new(zathura->config.data_dir); #ifdef WITH_SQLITE } else if (g_strcmp0(database, "sqlite") == 0) { - girara_info("Using sqlite database backend."); + girara_debug("Using sqlite database backend."); char* tmp = g_build_filename(zathura->config.data_dir, "bookmarks.sqlite", NULL); zathura->database = zathura_sqldatabase_new(tmp); g_free(tmp); @@ -228,13 +232,23 @@ zathura_init(zathura_t* zathura) /* bookmarks */ zathura->bookmarks.bookmarks = girara_sorted_list_new2((girara_compare_function_t) zathura_bookmarks_compare, - (girara_free_function_t) zathura_bookmark_free); + (girara_free_function_t) zathura_bookmark_free); /* add even to purge old pages */ int interval = 30; girara_setting_get(zathura->ui.session, "page-store-interval", &interval); g_timeout_add_seconds(interval, purge_pages, zathura); + /* jumplist */ + + zathura->jumplist.max_size = 20; + girara_setting_get(zathura->ui.session, "jumplist-size", &(zathura->jumplist.max_size)); + + zathura->jumplist.list = girara_list_new2(g_free); + zathura->jumplist.size = 0; + zathura->jumplist.cur = NULL; + zathura_jumplist_append_jump(zathura); + zathura->jumplist.cur = girara_list_iterator(zathura->jumplist.list); return true; error_free: @@ -291,6 +305,15 @@ zathura_free(zathura_t* zathura) g_free(zathura->config.config_dir); g_free(zathura->config.data_dir); + /* free jumplist */ + if (zathura->jumplist.list != NULL) { + girara_list_free(zathura->jumplist.list); + } + + if (zathura->jumplist.cur != NULL) { + girara_list_iterator_free(zathura->jumplist.cur); + } + g_free(zathura); } @@ -343,14 +366,14 @@ zathura_set_plugin_dir(zathura_t* zathura, const char* dir) if (dir != NULL) { girara_list_t* paths = girara_split_path_array(dir); GIRARA_LIST_FOREACH(paths, char*, iter, path) - zathura_plugin_manager_add_dir(zathura->plugins.manager, path); + zathura_plugin_manager_add_dir(zathura->plugins.manager, path); GIRARA_LIST_FOREACH_END(paths, char*, iter, path); girara_list_free(paths); } else { #ifdef ZATHURA_PLUGINDIR girara_list_t* paths = girara_split_path_array(ZATHURA_PLUGINDIR); GIRARA_LIST_FOREACH(paths, char*, iter, path) - zathura_plugin_manager_add_dir(zathura->plugins.manager, path); + zathura_plugin_manager_add_dir(zathura->plugins.manager, path); GIRARA_LIST_FOREACH_END(paths, char*, iter, path); girara_list_free(paths); #endif @@ -375,7 +398,7 @@ zathura_set_synctex_editor_command(zathura_t* zathura, const char* command) } void -zathura_set_syntex(zathura_t* zathura, bool value) +zathura_set_synctex(zathura_t* zathura, bool value) { g_return_if_fail(zathura != NULL); g_return_if_fail(zathura->ui.session != NULL); @@ -453,7 +476,7 @@ document_info_open(gpointer data) file = prepare_document_open_from_stdin(document_info->zathura); if (file == NULL) { girara_notify(document_info->zathura->ui.session, GIRARA_ERROR, - "Could not read file from stdin and write it to a temporary file."); + "Could not read file from stdin and write it to a temporary file."); } else { document_info->zathura->stdin_support.file = g_strdup(file); } @@ -490,7 +513,7 @@ document_open(zathura_t* zathura, const char* path, const char* password) if (path != NULL) { password_dialog_info->path = g_strdup(path); girara_dialog(zathura->ui.session, "Enter password:", true, NULL, - (girara_callback_inputbar_activate_t) cb_password_dialog, password_dialog_info); + (girara_callback_inputbar_activate_t) cb_password_dialog, password_dialog_info); goto error_out; } else { free(password_dialog_info); @@ -730,8 +753,16 @@ document_save(zathura_t* zathura, const char* path, bool overwrite) g_return_val_if_fail(path, false); gchar* file_path = girara_fix_path(path); - if ((overwrite == false) && g_file_test(file_path, G_FILE_TEST_EXISTS)) - { + /* use current basename if path points to a directory */ + if (g_file_test(file_path, G_FILE_TEST_IS_DIR) == TRUE) { + char* basename = g_path_get_basename(zathura_document_get_path(zathura->document)); + char* tmp = file_path; + file_path = g_strconcat(file_path, "/", basename, NULL); + g_free(tmp); + g_free(basename); + } + + if ((overwrite == false) && g_file_test(file_path, G_FILE_TEST_EXISTS)) { girara_error("File already exists: %s. Use :write! to overwrite it.", file_path); g_free(file_path); return false; @@ -935,14 +966,14 @@ page_widget_set_mode(zathura_t* zathura, unsigned int pages_per_row, unsigned in pages_per_row = 1; } - /* ensure: 0 < first_page_column <= pages_per_row */ - if (first_page_column < 1) { - first_page_column = 1; - } + /* ensure: 0 < first_page_column <= pages_per_row */ + if (first_page_column < 1) { + first_page_column = 1; + } - if (first_page_column > pages_per_row) { - first_page_column = ((first_page_column - 1) % pages_per_row) + 1; - } + if (first_page_column > pages_per_row) { + first_page_column = ((first_page_column - 1) % pages_per_row) + 1; + } if (zathura->document == NULL) { return; @@ -1026,3 +1057,98 @@ position_set_delayed(zathura_t* zathura, double position_x, double position_y) return FALSE; } + + +zathura_jump_t* +zathura_jumplist_current(zathura_t* zathura) +{ + if (zathura->jumplist.cur != NULL) { + return girara_list_iterator_data(zathura->jumplist.cur); + } else { + return NULL; + } +} + +void +zathura_jumplist_forward(zathura_t* zathura) +{ + if (girara_list_iterator_has_next(zathura->jumplist.cur)) { + girara_list_iterator_next(zathura->jumplist.cur); + } +} + +void +zathura_jumplist_backward(zathura_t* zathura) +{ + if (girara_list_iterator_has_previous(zathura->jumplist.cur)) { + girara_list_iterator_previous(zathura->jumplist.cur); + } +} + +void +zathura_jumplist_append_jump(zathura_t* zathura) +{ + zathura_jump_t *jump = g_malloc(sizeof(zathura_jump_t)); + if (jump != NULL) { + jump->page = 0; + jump->x = 0; + jump->y = 0; + + /* remove right tail after current */ + if (zathura->jumplist.cur != NULL) { + girara_list_iterator_t *it = girara_list_iterator_copy(zathura->jumplist.cur); + girara_list_iterator_next(it); + while (girara_list_iterator_is_valid(it)) { + girara_list_iterator_remove(it); + zathura->jumplist.size = zathura->jumplist.size - 1; + } + g_free(it); + } + + /* trim from beginning until max_size */ + girara_list_iterator_t *it = girara_list_iterator(zathura->jumplist.list); + while (zathura->jumplist.size >= zathura->jumplist.max_size && girara_list_iterator_is_valid(it)) { + girara_list_iterator_remove(it); + zathura->jumplist.size = zathura->jumplist.size - 1; + } + g_free(it); + + girara_list_append(zathura->jumplist.list, jump); + zathura->jumplist.size = zathura->jumplist.size + 1; + } +} + +void +zathura_jumplist_add(zathura_t* zathura) +{ + if (zathura->jumplist.list != NULL) { + unsigned int pagenum = zathura_document_get_current_page_number(zathura->document); + zathura_jump_t* cur = zathura_jumplist_current(zathura); + if (cur && cur->page == pagenum) { + return; + } + + zathura_jumplist_append_jump(zathura); + girara_list_iterator_next(zathura->jumplist.cur); + zathura_jumplist_save(zathura); + } +} + + +void +zathura_jumplist_save(zathura_t* zathura) +{ + zathura_jump_t* cur = zathura_jumplist_current(zathura); + + unsigned int pagenum = zathura_document_get_current_page_number(zathura->document); + + if (cur) { + /* get position */ + GtkAdjustment* view_vadjustment = gtk_scrolled_window_get_vadjustment(GTK_SCROLLED_WINDOW(zathura->ui.session->gtk.view)); + GtkAdjustment* view_hadjustment = gtk_scrolled_window_get_hadjustment(GTK_SCROLLED_WINDOW(zathura->ui.session->gtk.view)); + + cur->page = pagenum; + cur->x = gtk_adjustment_get_value(view_hadjustment) / zathura_document_get_scale(zathura->document); + cur->y = gtk_adjustment_get_value(view_vadjustment) / zathura_document_get_scale(zathura->document);; + } +} diff --git a/zathura.h b/zathura.h index 9aa807c..6970063 100644 --- a/zathura.h +++ b/zathura.h @@ -28,6 +28,16 @@ typedef struct _ZathuraDatabase zathura_database_t; struct render_thread_s; typedef struct render_thread_s render_thread_t; +/** + * Jump + */ +typedef struct zathura_jump_s +{ + unsigned int page; + double x; + double y; +} zathura_jump_t; + struct zathura_s { struct @@ -87,6 +97,7 @@ struct zathura_s bool recolor_keep_hue; /**< Keep hue when recoloring */ bool recolor; /**< Recoloring mode switch */ bool update_page_number; /**< Update current page number */ + int search_direction; /**< Current search direction (FORWARD or BACKWARD) */ girara_list_t* marks; /**< Marker */ char** arguments; /**> Arguments that were passed at startup */ } global; @@ -105,6 +116,14 @@ struct zathura_s girara_list_t* bookmarks; /**< bookmarks */ } bookmarks; + struct + { + girara_list_t* list; + girara_list_iterator_t *cur; + unsigned int size; + unsigned int max_size; + } jumplist; + struct { gchar* file; @@ -192,12 +211,12 @@ void zathura_set_plugin_dir(zathura_t* zathura, const char* dir); void zathura_set_synctex_editor_command(zathura_t* zathura, const char* command); /** - * En/Disable zathuras syntex support + * En/Disable zathuras synctex support * * @param zathura The zathura session * @param value The value */ -void zathura_set_syntex(zathura_t* zathura, bool value); +void zathura_set_synctex(zathura_t* zathura, bool value); /** * Sets the program parameters @@ -292,4 +311,48 @@ void page_widget_set_mode(zathura_t* zathura, unsigned int pages_per_row, unsign */ void statusbar_page_number_update(zathura_t* zathura); +/** + * Return current jump in the jumplist + * + * @param zathura The zathura session + * @return current jump + */ +zathura_jump_t* zathura_jumplist_current(zathura_t* zathura); + +/** + * Move forward in the jumplist + * + * @param zathura The zathura session + */ +void zathura_jumplist_forward(zathura_t* zathura); + +/** + * Move backward in the jumplist + * + * @param zathura The zathura session + */ +void zathura_jumplist_backward(zathura_t* zathura); + +/** + * Save current page to the jumplist at current position + * + * @param zathura The zathura session + */ +void zathura_jumplist_save(zathura_t* zathura); + +/** + * Add current page as a new item to the jumplist after current position + * + * @param zathura The zathura session + */ +void zathura_jumplist_add(zathura_t* zathura); + +/** + * Add a page to the jumplist after current position + * + * @param zathura The zathura session + */ +void zathura_jumplist_append_jump(zathura_t* zathura); + + #endif // ZATHURA_H diff --git a/zathurarc.5.rst b/zathurarc.5.rst index 0994ef9..ae58bc7 100644 --- a/zathurarc.5.rst +++ b/zathurarc.5.rst @@ -27,8 +27,8 @@ is not possible to write multiple commands in one single line. COMMANDS ======== -set - Chaning options ---------------------- +set - Changing options +---------------------- In addition to the build-in ``:set`` command zathura offers more options to be changed and makes those changes permanent. To overwrite an option you just have @@ -79,8 +79,7 @@ it is possible to map bindings only for a specific mode by passing the ``mode`` argument which can take one of the following values: * normal (default) -* visual -* insert +* fullscreen * index The brackets around the value are mandatory. @@ -151,7 +150,7 @@ are currently available: PageUp Page Up Return Return Space Space - Super Windows button + Super Windows key Tab Tab Of course it is possible to combine those special keys with a modifier. The @@ -206,11 +205,14 @@ The following shortcut functions can be mapped: abort Switch back to normal mode adjust_window Adjust page width change_mode Change current mode - follow Follow a link + display_link Display link target focus_inputbar Focus inputbar + follow Follow a link goto Go to a certain page - index_navigate Navigate through the index + jumplist Move forwards/backwards in the jumplist navigate Navigate to the next/previous page + navigate_index Navigate through the index + print Show the print dialog quit Quit zathura recolor Recolor the pages reload Reload the document @@ -221,6 +223,7 @@ The following shortcut functions can be mapped: toggle_fullscreen Toggle fullscreen toggle_index Show or hide index toggle_inputbar Show or hide inputbar + toggle_page_mode Toggle between one and multiple pages per row toggle_statusbar Show or hide statusbar zoom Zoom in or out @@ -490,6 +493,13 @@ Defines if the number of pages per row should be honored when advancing a page. * Value type: Boolean * Default value: false +incremental-search +^^^^^^^^^^^^^^^^^^ +En/Disables incremental search (search while typing). + +* Value type: Boolean +* Default value: true + highlight-color ^^^^^^^^^^^^^^^ Defines the color that is used for highlighting parts of the document (e.g.: @@ -598,6 +608,14 @@ Defines the step size of scrolling by calling the scroll command once * Value type: Float * Default value: 40 +scroll-full-overlap +^^^^^^^^^^^^^^^^^^^ +Defines the proportion of the current viewing area that should be +visible after scrolling a full page. + +* Value type: Float +* Default value: 0.1 + scroll-wrap ^^^^^^^^^^^ Defines if the last/first page should be wrapped @@ -605,6 +623,13 @@ Defines if the last/first page should be wrapped * Value type: Boolean * Default value: false +scroll-page-aware +^^^^^^^^^^^^^^^^^ +Defines if scrolling by half or full pages stops at page boundaries. + +* Value type: Boolean +* Default value: false + search-hadjust ^^^^^^^^^^^^^^ En/Disables horizontally centered search results