5729c0b32f
This implementation is inspired by the behaviour in (recent versions of) Adobe Reader, since it leads to reasonably simple and straightforward code as far as I'm concerned. *Specifically:* We'll only consider *one* destination per page when finding/highlighting the current outline item, which is similar to e.g. Adobe Reader, and we choose the *first* outline item at the *lowest* level of the outline tree. Given that this functionality requires not only parsing of the `outline`, but looking up *all* of the destinations in the document, this feature can when initialized have a non-trivial performance overhead for larger PDF documents. In an attempt to reduce the performance impact, the following steps are taken here: - The "find current outline item"-functionality will only be enabled once *one* page has rendered and *all* the pages have been loaded[1], to prevent it interfering with data regular fetching/parsing early on during document loading and viewer initialization. - With the exception of a couple of small and simple `eventBus`-listeners, in `PDFOutlineViewer`, this new functionality is initialized *lazily* the first time that the user clicks on the `currentOutlineItem`-button. - The entire "find current outline item"-functionality is disabled when `disableAutoFetch = true` is set, since it can easily lead to the setting becoming essentially pointless[2] by triggering *a lot* of data fetching from a relatively minor viewer-feature. - Fetch the destinations *individually*, since that's generally more efficient than using `PDFDocumentProxy.getDestinations` to fetch them all at once. Despite making the overall parsing code *more* asynchronous, and leading to a lot more main/worker-thread message passing, in practice this seems faster for larger documents. Finally, we'll now always highlight an outline item that the user manually clicked on, since only highlighting when the new "find current outline item"-functionality is used seemed inconsistent. --- [1] Keep in mind that the `outline` itself already isn't fetched/parsed until at least *one* page has been rendered in the viewer. [2] And also quite slow, since it can take a fair amount of time to fetch all of the necessary `destinations` data when `disableAutoFetch = true` is set.
254 lines
11 KiB
Properties
254 lines
11 KiB
Properties
# Copyright 2012 Mozilla Foundation
|
||
#
|
||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||
# you may not use this file except in compliance with the License.
|
||
# You may obtain a copy of the License at
|
||
#
|
||
# http://www.apache.org/licenses/LICENSE-2.0
|
||
#
|
||
# Unless required by applicable law or agreed to in writing, software
|
||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||
# See the License for the specific language governing permissions and
|
||
# limitations under the License.
|
||
|
||
# Main toolbar buttons (tooltips and alt text for images)
|
||
previous.title=Föregående sida
|
||
previous_label=Föregående
|
||
next.title=Nästa sida
|
||
next_label=Nästa
|
||
|
||
# LOCALIZATION NOTE (page.title): The tooltip for the pageNumber input.
|
||
page.title=Sida
|
||
# LOCALIZATION NOTE (of_pages): "{{pagesCount}}" will be replaced by a number
|
||
# representing the total number of pages in the document.
|
||
of_pages=av {{pagesCount}}
|
||
# LOCALIZATION NOTE (page_of_pages): "{{pageNumber}}" and "{{pagesCount}}"
|
||
# will be replaced by a number representing the currently visible page,
|
||
# respectively a number representing the total number of pages in the document.
|
||
page_of_pages=({{pageNumber}} av {{pagesCount}})
|
||
|
||
zoom_out.title=Zooma ut
|
||
zoom_out_label=Zooma ut
|
||
zoom_in.title=Zooma in
|
||
zoom_in_label=Zooma in
|
||
zoom.title=Zoom
|
||
presentation_mode.title=Byt till presentationsläge
|
||
presentation_mode_label=Presentationsläge
|
||
open_file.title=Öppna fil
|
||
open_file_label=Öppna
|
||
print.title=Skriv ut
|
||
print_label=Skriv ut
|
||
download.title=Hämta
|
||
download_label=Hämta
|
||
bookmark.title=Aktuell vy (kopiera eller öppna i nytt fönster)
|
||
bookmark_label=Aktuell vy
|
||
|
||
# Secondary toolbar and context menu
|
||
tools.title=Verktyg
|
||
tools_label=Verktyg
|
||
first_page.title=Gå till första sidan
|
||
first_page.label=Gå till första sidan
|
||
first_page_label=Gå till första sidan
|
||
last_page.title=Gå till sista sidan
|
||
last_page.label=Gå till sista sidan
|
||
last_page_label=Gå till sista sidan
|
||
page_rotate_cw.title=Rotera medurs
|
||
page_rotate_cw.label=Rotera medurs
|
||
page_rotate_cw_label=Rotera medurs
|
||
page_rotate_ccw.title=Rotera moturs
|
||
page_rotate_ccw.label=Rotera moturs
|
||
page_rotate_ccw_label=Rotera moturs
|
||
|
||
cursor_text_select_tool.title=Aktivera textmarkeringsverktyg
|
||
cursor_text_select_tool_label=Textmarkeringsverktyg
|
||
cursor_hand_tool.title=Aktivera handverktyg
|
||
cursor_hand_tool_label=Handverktyg
|
||
|
||
scroll_vertical.title=Använd vertikal rullning
|
||
scroll_vertical_label=Vertikal rullning
|
||
scroll_horizontal.title=Använd horisontell rullning
|
||
scroll_horizontal_label=Horisontell rullning
|
||
scroll_wrapped.title=Använd överlappande rullning
|
||
scroll_wrapped_label=Överlappande rullning
|
||
|
||
spread_none.title=Visa enkelsidor
|
||
spread_none_label=Enkelsidor
|
||
spread_odd.title=Visa uppslag med olika sidnummer till vänster
|
||
spread_odd_label=Uppslag med framsida
|
||
spread_even.title=Visa uppslag med lika sidnummer till vänster
|
||
spread_even_label=Uppslag utan framsida
|
||
|
||
# Document properties dialog box
|
||
document_properties.title=Dokumentegenskaper…
|
||
document_properties_label=Dokumentegenskaper…
|
||
document_properties_file_name=Filnamn:
|
||
document_properties_file_size=Filstorlek:
|
||
# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}"
|
||
# will be replaced by the PDF file size in kilobytes, respectively in bytes.
|
||
document_properties_kb={{size_kb}} kB ({{size_b}} byte)
|
||
# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}"
|
||
# will be replaced by the PDF file size in megabytes, respectively in bytes.
|
||
document_properties_mb={{size_mb}} MB ({{size_b}} byte)
|
||
document_properties_title=Titel:
|
||
document_properties_author=Författare:
|
||
document_properties_subject=Ämne:
|
||
document_properties_keywords=Nyckelord:
|
||
document_properties_creation_date=Skapades:
|
||
document_properties_modification_date=Ändrades:
|
||
# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}"
|
||
# will be replaced by the creation/modification date, and time, of the PDF file.
|
||
document_properties_date_string={{date}}, {{time}}
|
||
document_properties_creator=Skapare:
|
||
document_properties_producer=PDF-producent:
|
||
document_properties_version=PDF-version:
|
||
document_properties_page_count=Sidantal:
|
||
document_properties_page_size=Pappersstorlek:
|
||
document_properties_page_size_unit_inches=in
|
||
document_properties_page_size_unit_millimeters=mm
|
||
document_properties_page_size_orientation_portrait=porträtt
|
||
document_properties_page_size_orientation_landscape=landskap
|
||
document_properties_page_size_name_a3=A3
|
||
document_properties_page_size_name_a4=A4
|
||
document_properties_page_size_name_letter=Letter
|
||
document_properties_page_size_name_legal=Legal
|
||
# LOCALIZATION NOTE (document_properties_page_size_dimension_string):
|
||
# "{{width}}", "{{height}}", {{unit}}, and {{orientation}} will be replaced by
|
||
# the size, respectively their unit of measurement and orientation, of the (current) page.
|
||
document_properties_page_size_dimension_string={{width}} × {{height}} {{unit}} ({{orientation}})
|
||
# LOCALIZATION NOTE (document_properties_page_size_dimension_name_string):
|
||
# "{{width}}", "{{height}}", {{unit}}, {{name}}, and {{orientation}} will be replaced by
|
||
# the size, respectively their unit of measurement, name, and orientation, of the (current) page.
|
||
document_properties_page_size_dimension_name_string={{width}} × {{height}} {{unit}} ({{name}}, {{orientation}})
|
||
# LOCALIZATION NOTE (document_properties_linearized): The linearization status of
|
||
# the document; usually called "Fast Web View" in English locales of Adobe software.
|
||
document_properties_linearized=Snabb webbvisning:
|
||
document_properties_linearized_yes=Ja
|
||
document_properties_linearized_no=Nej
|
||
document_properties_close=Stäng
|
||
|
||
print_progress_message=Förbereder sidor för utskrift…
|
||
# LOCALIZATION NOTE (print_progress_percent): "{{progress}}" will be replaced by
|
||
# a numerical per cent value.
|
||
print_progress_percent={{progress}}%
|
||
print_progress_close=Avbryt
|
||
|
||
# Tooltips and alt text for side panel toolbar buttons
|
||
# (the _label strings are alt text for the buttons, the .title strings are
|
||
# tooltips)
|
||
toggle_sidebar.title=Visa/dölj sidofält
|
||
toggle_sidebar_notification.title=Visa/dölj sidofält (dokument innehåller översikt/bilagor)
|
||
toggle_sidebar_notification2.title=Växla sidofält (dokumentet innehåller dokumentstruktur/bilagor/lager)
|
||
toggle_sidebar_label=Visa/dölj sidofält
|
||
document_outline.title=Visa dokumentdisposition (dubbelklicka för att expandera/komprimera alla objekt)
|
||
document_outline_label=Dokumentöversikt
|
||
attachments.title=Visa Bilagor
|
||
attachments_label=Bilagor
|
||
layers.title=Visa lager (dubbelklicka för att återställa alla lager till standardläge)
|
||
layers_label=Lager
|
||
thumbs.title=Visa miniatyrer
|
||
thumbs_label=Miniatyrer
|
||
current_outline_item.title=Hitta aktuell position i dokumentdispositionen
|
||
current_outline_item_label=Aktuell position i dokumentdisposition
|
||
findbar.title=Sök i dokument
|
||
findbar_label=Sök
|
||
|
||
additional_layers=Ytterligare lager
|
||
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
|
||
page_canvas=Sida {{page}}
|
||
# Thumbnails panel item (tooltip and alt text for images)
|
||
# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page
|
||
# number.
|
||
thumb_page_title=Sida {{page}}
|
||
# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page
|
||
# number.
|
||
thumb_page_canvas=Miniatyr av sida {{page}}
|
||
|
||
# Find panel button title and messages
|
||
find_input.title=Sök
|
||
find_input.placeholder=Sök i dokument…
|
||
find_previous.title=Hitta föregående förekomst av frasen
|
||
find_previous_label=Föregående
|
||
find_next.title=Hitta nästa förekomst av frasen
|
||
find_next_label=Nästa
|
||
find_highlight=Markera alla
|
||
find_match_case_label=Matcha versal/gemen
|
||
find_entire_word_label=Hela ord
|
||
find_reached_top=Nådde början av dokumentet, började från slutet
|
||
find_reached_bottom=Nådde slutet på dokumentet, började från början
|
||
# LOCALIZATION NOTE (find_match_count): The supported plural forms are
|
||
# [one|two|few|many|other], with [other] as the default value.
|
||
# "{{current}}" and "{{total}}" will be replaced by a number representing the
|
||
# index of the currently active find result, respectively a number representing
|
||
# the total number of matches in the document.
|
||
find_match_count={[ plural(total) ]}
|
||
find_match_count[one]={{current}} av {{total}} träff
|
||
find_match_count[two]={{current}} av {{total}} träffar
|
||
find_match_count[few]={{current}} av {{total}} träffar
|
||
find_match_count[many]={{current}} av {{total}} träffar
|
||
find_match_count[other]={{current}} av {{total}} träffar
|
||
# LOCALIZATION NOTE (find_match_count_limit): The supported plural forms are
|
||
# [zero|one|two|few|many|other], with [other] as the default value.
|
||
# "{{limit}}" will be replaced by a numerical value.
|
||
find_match_count_limit={[ plural(limit) ]}
|
||
find_match_count_limit[zero]=Mer än {{limit}} träffar
|
||
find_match_count_limit[one]=Mer än {{limit}} träff
|
||
find_match_count_limit[two]=Mer än {{limit}} träffar
|
||
find_match_count_limit[few]=Mer än {{limit}} träffar
|
||
find_match_count_limit[many]=Mer än {{limit}} träffar
|
||
find_match_count_limit[other]=Mer än {{limit}} träffar
|
||
find_not_found=Frasen hittades inte
|
||
|
||
# Error panel labels
|
||
error_more_info=Mer information
|
||
error_less_info=Mindre information
|
||
error_close=Stäng
|
||
# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be
|
||
# replaced by the PDF.JS version and build ID.
|
||
error_version_info=PDF.js v{{version}} (build: {{build}})
|
||
# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an
|
||
# english string describing the error.
|
||
error_message=Meddelande: {{message}}
|
||
# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack
|
||
# trace.
|
||
error_stack=Stack: {{stack}}
|
||
# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename
|
||
error_file=Fil: {{file}}
|
||
# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number
|
||
error_line=Rad: {{line}}
|
||
rendering_error=Ett fel uppstod vid visning av sidan.
|
||
|
||
# Predefined zoom values
|
||
page_scale_width=Sidbredd
|
||
page_scale_fit=Anpassa sida
|
||
page_scale_auto=Automatisk zoom
|
||
page_scale_actual=Verklig storlek
|
||
# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a
|
||
# numerical scale value.
|
||
page_scale_percent={{scale}}%
|
||
|
||
# Loading indicator messages
|
||
loading_error_indicator=Fel
|
||
loading_error=Ett fel uppstod vid laddning av PDF-filen.
|
||
invalid_file_error=Ogiltig eller korrupt PDF-fil.
|
||
missing_file_error=Saknad PDF-fil.
|
||
unexpected_response_error=Oväntat svar från servern.
|
||
|
||
# LOCALIZATION NOTE (annotation_date_string): "{{date}}" and "{{time}}" will be
|
||
# replaced by the modification date, and time, of the annotation.
|
||
annotation_date_string={{date}} {{time}}
|
||
|
||
# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip.
|
||
# "{{type}}" will be replaced with an annotation type from a list defined in
|
||
# the PDF spec (32000-1:2008 Table 169 – Annotation types).
|
||
# Some common types are e.g.: "Check", "Text", "Comment", "Note"
|
||
text_annotation_type.alt=[{{type}}-annotering]
|
||
password_label=Skriv in lösenordet för att öppna PDF-filen.
|
||
password_invalid=Ogiltigt lösenord. Försök igen.
|
||
password_ok=OK
|
||
password_cancel=Avbryt
|
||
|
||
printing_not_supported=Varning: Utskrifter stöds inte helt av den här webbläsaren.
|
||
printing_not_ready=Varning: PDF:en är inte klar för utskrift.
|
||
web_fonts_disabled=Webbtypsnitt är inaktiverade: kan inte använda inbäddade PDF-typsnitt.
|