summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--po/en.po4
-rw-r--r--res/lang/cs.binbin32811 -> 32862 bytes
-rw-r--r--res/lang/de.binbin31621 -> 31672 bytes
-rw-r--r--res/lang/en.binbin27690 -> 27741 bytes
-rw-r--r--res/lang/eo.binbin26880 -> 26931 bytes
-rw-r--r--res/lang/es.binbin31533 -> 31584 bytes
-rw-r--r--res/lang/es_MX.binbin28760 -> 28811 bytes
-rw-r--r--res/lang/fi.binbin31331 -> 31382 bytes
-rw-r--r--res/lang/fr.binbin32418 -> 32469 bytes
-rw-r--r--res/lang/gl.binbin30694 -> 30745 bytes
-rw-r--r--res/lang/hu.binbin32443 -> 32494 bytes
-rw-r--r--res/lang/ia.binbin30473 -> 30524 bytes
-rw-r--r--res/lang/ie.binbin30430 -> 30481 bytes
-rw-r--r--res/lang/isv.binbin26411 -> 26462 bytes
-rw-r--r--res/lang/nl.binbin29800 -> 29851 bytes
-rw-r--r--res/lang/pl.binbin31046 -> 31097 bytes
-rw-r--r--res/lang/ru.binbin46393 -> 46444 bytes
-rw-r--r--res/lang/sk.binbin26747 -> 26798 bytes
-rw-r--r--res/lang/sr.binbin45689 -> 45740 bytes
-rw-r--r--res/lang/tok.binbin28536 -> 28587 bytes
-rw-r--r--res/lang/tr.binbin30637 -> 30688 bytes
-rw-r--r--res/lang/uk.binbin45770 -> 45821 bytes
-rw-r--r--res/lang/zh_Hans.binbin26655 -> 26706 bytes
-rw-r--r--res/lang/zh_Hant.binbin27053 -> 27104 bytes
-rw-r--r--src/app.c6
-rw-r--r--src/gmdocument.c8
-rw-r--r--src/prefs.c11
-rw-r--r--src/prefs.h2
-rw-r--r--src/ui/documentwidget.c5
-rw-r--r--src/ui/util.c3
30 files changed, 30 insertions, 9 deletions
diff --git a/po/en.po b/po/en.po
index aae67ff0..aa557043 100644
--- a/po/en.po
+++ b/po/en.po
@@ -1429,6 +1429,10 @@ msgstr "Collapse preformatted:"
1429msgid "prefs.bookmarks.addbottom" 1429msgid "prefs.bookmarks.addbottom"
1430msgstr "Add bookmarks to bottom:" 1430msgstr "Add bookmarks to bottom:"
1431 1431
1432# User preference that controls whether image data embedded in Data URLs gets automatically displayed when a page is loaded.
1433msgid "prefs.dataurl.openimages"
1434msgstr "Open images in Data URLs:"
1435
1432# User preference that controls whether index.gmi pages get automatically opened when browsing the contents of a directory inside a compressed archive. 1436# User preference that controls whether index.gmi pages get automatically opened when browsing the contents of a directory inside a compressed archive.
1433msgid "prefs.archive.openindex" 1437msgid "prefs.archive.openindex"
1434msgstr "Open archive indices:" 1438msgstr "Open archive indices:"
diff --git a/res/lang/cs.bin b/res/lang/cs.bin
index a14c5cf4..f3f2a060 100644
--- a/res/lang/cs.bin
+++ b/res/lang/cs.bin
Binary files differ
diff --git a/res/lang/de.bin b/res/lang/de.bin
index 8dd9d478..0f918bfb 100644
--- a/res/lang/de.bin
+++ b/res/lang/de.bin
Binary files differ
diff --git a/res/lang/en.bin b/res/lang/en.bin
index dd3389ef..727258d1 100644
--- a/res/lang/en.bin
+++ b/res/lang/en.bin
Binary files differ
diff --git a/res/lang/eo.bin b/res/lang/eo.bin
index c65c893c..f68ac15d 100644
--- a/res/lang/eo.bin
+++ b/res/lang/eo.bin
Binary files differ
diff --git a/res/lang/es.bin b/res/lang/es.bin
index a0f2a07f..1d09138c 100644
--- a/res/lang/es.bin
+++ b/res/lang/es.bin
Binary files differ
diff --git a/res/lang/es_MX.bin b/res/lang/es_MX.bin
index e83f92e2..d3efe8fe 100644
--- a/res/lang/es_MX.bin
+++ b/res/lang/es_MX.bin
Binary files differ
diff --git a/res/lang/fi.bin b/res/lang/fi.bin
index f390cdca..24e2a905 100644
--- a/res/lang/fi.bin
+++ b/res/lang/fi.bin
Binary files differ
diff --git a/res/lang/fr.bin b/res/lang/fr.bin
index c268b356..c644fab8 100644
--- a/res/lang/fr.bin
+++ b/res/lang/fr.bin
Binary files differ
diff --git a/res/lang/gl.bin b/res/lang/gl.bin
index 04311f53..e93d1eb7 100644
--- a/res/lang/gl.bin
+++ b/res/lang/gl.bin
Binary files differ
diff --git a/res/lang/hu.bin b/res/lang/hu.bin
index 28ba0e48..5bfe37eb 100644
--- a/res/lang/hu.bin
+++ b/res/lang/hu.bin
Binary files differ
diff --git a/res/lang/ia.bin b/res/lang/ia.bin
index 27e3ba71..4b0b9bc3 100644
--- a/res/lang/ia.bin
+++ b/res/lang/ia.bin
Binary files differ
diff --git a/res/lang/ie.bin b/res/lang/ie.bin
index 244ade42..b69fd2a4 100644
--- a/res/lang/ie.bin
+++ b/res/lang/ie.bin
Binary files differ
diff --git a/res/lang/isv.bin b/res/lang/isv.bin
index 8c177e99..0cbd0f67 100644
--- a/res/lang/isv.bin
+++ b/res/lang/isv.bin
Binary files differ
diff --git a/res/lang/nl.bin b/res/lang/nl.bin
index 2bdf4a71..82d13774 100644
--- a/res/lang/nl.bin
+++ b/res/lang/nl.bin
Binary files differ
diff --git a/res/lang/pl.bin b/res/lang/pl.bin
index 129d34da..9d13a9e2 100644
--- a/res/lang/pl.bin
+++ b/res/lang/pl.bin
Binary files differ
diff --git a/res/lang/ru.bin b/res/lang/ru.bin
index ac407168..6a09521d 100644
--- a/res/lang/ru.bin
+++ b/res/lang/ru.bin
Binary files differ
diff --git a/res/lang/sk.bin b/res/lang/sk.bin
index 099f0ccf..9532ca17 100644
--- a/res/lang/sk.bin
+++ b/res/lang/sk.bin
Binary files differ
diff --git a/res/lang/sr.bin b/res/lang/sr.bin
index e550a05a..58828fea 100644
--- a/res/lang/sr.bin
+++ b/res/lang/sr.bin
Binary files differ
diff --git a/res/lang/tok.bin b/res/lang/tok.bin
index 2bf27e86..0c4f6123 100644
--- a/res/lang/tok.bin
+++ b/res/lang/tok.bin
Binary files differ
diff --git a/res/lang/tr.bin b/res/lang/tr.bin
index 6bd0c26c..f62d0968 100644
--- a/res/lang/tr.bin
+++ b/res/lang/tr.bin
Binary files differ
diff --git a/res/lang/uk.bin b/res/lang/uk.bin
index 520f6c97..bbc10575 100644
--- a/res/lang/uk.bin
+++ b/res/lang/uk.bin
Binary files differ
diff --git a/res/lang/zh_Hans.bin b/res/lang/zh_Hans.bin
index 81ea7de6..3a34d15d 100644
--- a/res/lang/zh_Hans.bin
+++ b/res/lang/zh_Hans.bin
Binary files differ
diff --git a/res/lang/zh_Hant.bin b/res/lang/zh_Hant.bin
index 029551c7..f0ac2727 100644
--- a/res/lang/zh_Hant.bin
+++ b/res/lang/zh_Hant.bin
Binary files differ
diff --git a/src/app.c b/src/app.c
index a2ada36e..d1e3870a 100644
--- a/src/app.c
+++ b/src/app.c
@@ -280,6 +280,7 @@ static iString *serializePrefs_App_(const iApp *d) {
280 { "prefs.collapsepreonload", &d->prefs.collapsePreOnLoad }, 280 { "prefs.collapsepreonload", &d->prefs.collapsePreOnLoad },
281 { "prefs.hoverlink", &d->prefs.hoverLink }, 281 { "prefs.hoverlink", &d->prefs.hoverLink },
282 { "prefs.bookmarks.addbottom", &d->prefs.addBookmarksToBottom }, 282 { "prefs.bookmarks.addbottom", &d->prefs.addBookmarksToBottom },
283 { "prefs.dataurl.openimages", &d->prefs.openDataUrlImagesOnLoad },
283 { "prefs.archive.openindex", &d->prefs.openArchiveIndexPages }, 284 { "prefs.archive.openindex", &d->prefs.openArchiveIndexPages },
284 { "prefs.font.warnmissing", &d->prefs.warnAboutMissingGlyphs }, 285 { "prefs.font.warnmissing", &d->prefs.warnAboutMissingGlyphs },
285 { "prefs.blink", &d->prefs.blinkingCursor }, 286 { "prefs.blink", &d->prefs.blinkingCursor },
@@ -2729,6 +2730,10 @@ iBool handleCommand_App(const char *cmd) {
2729 postRefresh_App(); 2730 postRefresh_App();
2730 return iTrue; 2731 return iTrue;
2731 } 2732 }
2733 else if (equal_Command(cmd, "prefs.dataurl.openimages.changed")) {
2734 d->prefs.openDataUrlImagesOnLoad = arg_Command(cmd) != 0;
2735 return iTrue;
2736 }
2732 else if (equal_Command(cmd, "prefs.archive.openindex.changed")) { 2737 else if (equal_Command(cmd, "prefs.archive.openindex.changed")) {
2733 d->prefs.openArchiveIndexPages = arg_Command(cmd) != 0; 2738 d->prefs.openArchiveIndexPages = arg_Command(cmd) != 0;
2734 return iTrue; 2739 return iTrue;
@@ -3096,6 +3101,7 @@ iBool handleCommand_App(const char *cmd) {
3096 setToggle_Widget(findChild_Widget(dlg, "prefs.hidetoolbarscroll"), d->prefs.hideToolbarOnScroll); 3101 setToggle_Widget(findChild_Widget(dlg, "prefs.hidetoolbarscroll"), d->prefs.hideToolbarOnScroll);
3097 setToggle_Widget(findChild_Widget(dlg, "prefs.bookmarks.addbottom"), d->prefs.addBookmarksToBottom); 3102 setToggle_Widget(findChild_Widget(dlg, "prefs.bookmarks.addbottom"), d->prefs.addBookmarksToBottom);
3098 setToggle_Widget(findChild_Widget(dlg, "prefs.font.warnmissing"), d->prefs.warnAboutMissingGlyphs); 3103 setToggle_Widget(findChild_Widget(dlg, "prefs.font.warnmissing"), d->prefs.warnAboutMissingGlyphs);
3104 setToggle_Widget(findChild_Widget(dlg, "prefs.dataurl.openimages"), d->prefs.openDataUrlImagesOnLoad);
3099 setToggle_Widget(findChild_Widget(dlg, "prefs.archive.openindex"), d->prefs.openArchiveIndexPages); 3105 setToggle_Widget(findChild_Widget(dlg, "prefs.archive.openindex"), d->prefs.openArchiveIndexPages);
3100 setToggle_Widget(findChild_Widget(dlg, "prefs.ostheme"), d->prefs.useSystemTheme); 3106 setToggle_Widget(findChild_Widget(dlg, "prefs.ostheme"), d->prefs.useSystemTheme);
3101 setToggle_Widget(findChild_Widget(dlg, "prefs.customframe"), d->prefs.customFrame); 3107 setToggle_Widget(findChild_Widget(dlg, "prefs.customframe"), d->prefs.customFrame);
diff --git a/src/gmdocument.c b/src/gmdocument.c
index 5cae4138..a3e233f3 100644
--- a/src/gmdocument.c
+++ b/src/gmdocument.c
@@ -334,7 +334,7 @@ static iRangecc addLink_GmDocument_(iGmDocument *d, iRangecc line, iGmLinkId *li
334 setRange_String(&link->url, link->urlRange); 334 setRange_String(&link->url, link->urlRange);
335 set_String(&link->url, canonicalUrl_String(absoluteUrl_String(&d->url, &link->url))); 335 set_String(&link->url, canonicalUrl_String(absoluteUrl_String(&d->url, &link->url)));
336 /* If invalid, disregard the link. */ 336 /* If invalid, disregard the link. */
337 if (size_String(&link->url) > prefs_App()->maxUrlSize || 337 if ((d->format == gemini_SourceFormat && size_String(&link->url) > prefs_App()->maxUrlSize) ||
338 (startsWithCase_String(&link->url, "about:command") 338 (startsWithCase_String(&link->url, "about:command")
339 /* this is a special internal page that allows submitting UI events */ 339 /* this is a special internal page that allows submitting UI events */
340 && !d->enableCommandLinks)) { 340 && !d->enableCommandLinks)) {
@@ -371,7 +371,11 @@ static iRangecc addLink_GmDocument_(iGmDocument *d, iRangecc line, iGmLinkId *li
371 } 371 }
372 else if (equalCase_Rangecc(parts.scheme, "data")) { 372 else if (equalCase_Rangecc(parts.scheme, "data")) {
373 setScheme_GmLink_(link, data_GmLinkScheme); 373 setScheme_GmLink_(link, data_GmLinkScheme);
374 if (startsWith_Rangecc(parts.path, "image/")) { 374 if (startsWith_Rangecc(parts.path, "image/png") ||
375 startsWith_Rangecc(parts.path, "image/jpg") ||
376 startsWith_Rangecc(parts.path, "image/jpeg") ||
377 startsWith_Rangecc(parts.path, "image/webp") ||
378 startsWith_Rangecc(parts.path, "image/gif")) {
375 link->flags |= imageFileExtension_GmLinkFlag; 379 link->flags |= imageFileExtension_GmLinkFlag;
376 } 380 }
377 } 381 }
diff --git a/src/prefs.c b/src/prefs.c
index cd86bf60..08355a6a 100644
--- a/src/prefs.c
+++ b/src/prefs.c
@@ -66,11 +66,12 @@ void init_Prefs(iPrefs *d) {
66 d->smoothScrollSpeed[keyboard_ScrollType] = 13; 66 d->smoothScrollSpeed[keyboard_ScrollType] = 13;
67 d->smoothScrollSpeed[mouse_ScrollType] = 13; 67 d->smoothScrollSpeed[mouse_ScrollType] = 13;
68 d->loadImageInsteadOfScrolling = iFalse; 68 d->loadImageInsteadOfScrolling = iFalse;
69 d->collapsePreOnLoad = iFalse; 69 d->openDataUrlImagesOnLoad = iFalse;
70 d->openArchiveIndexPages = iTrue; 70 d->collapsePreOnLoad = iFalse;
71 d->addBookmarksToBottom = iTrue; 71 d->openArchiveIndexPages = iTrue;
72 d->warnAboutMissingGlyphs = iTrue; 72 d->addBookmarksToBottom = iTrue;
73 d->decodeUserVisibleURLs = iTrue; 73 d->warnAboutMissingGlyphs = iTrue;
74 d->decodeUserVisibleURLs = iTrue;
74 d->maxCacheSize = 10; 75 d->maxCacheSize = 10;
75 d->maxMemorySize = 200; 76 d->maxMemorySize = 200;
76 d->maxUrlSize = 8192; 77 d->maxUrlSize = 8192;
diff --git a/src/prefs.h b/src/prefs.h
index 25bf56c4..59c36a16 100644
--- a/src/prefs.h
+++ b/src/prefs.h
@@ -75,6 +75,7 @@ enum iPrefsBool {
75 hoverLink_PrefsBool, 75 hoverLink_PrefsBool,
76 smoothScrolling_PrefsBool, 76 smoothScrolling_PrefsBool,
77 loadImageInsteadOfScrolling_PrefsBool, 77 loadImageInsteadOfScrolling_PrefsBool,
78 openDataUrlImagesOnLoad_PrefsBool,
78 collapsePreOnLoad_PrefsBool, 79 collapsePreOnLoad_PrefsBool,
79 openArchiveIndexPages_PrefsBool, 80 openArchiveIndexPages_PrefsBool,
80 81
@@ -128,6 +129,7 @@ struct Impl_Prefs {
128 iBool hoverLink; 129 iBool hoverLink;
129 iBool smoothScrolling; 130 iBool smoothScrolling;
130 iBool loadImageInsteadOfScrolling; 131 iBool loadImageInsteadOfScrolling;
132 iBool openDataUrlImagesOnLoad;
131 iBool collapsePreOnLoad; 133 iBool collapsePreOnLoad;
132 iBool openArchiveIndexPages; 134 iBool openArchiveIndexPages;
133 135
diff --git a/src/ui/documentwidget.c b/src/ui/documentwidget.c
index 6513fc33..293e4507 100644
--- a/src/ui/documentwidget.c
+++ b/src/ui/documentwidget.c
@@ -2411,8 +2411,9 @@ static const char *zipPageHeading_(const iRangecc mime) {
2411 2411
2412static void postProcessRequestContent_DocumentWidget_(iDocumentWidget *d, iBool isCached) { 2412static void postProcessRequestContent_DocumentWidget_(iDocumentWidget *d, iBool isCached) {
2413 iWidget *w = as_Widget(d); 2413 iWidget *w = as_Widget(d);
2414 /* Embedded images in data links should be shown immediately as they are already fetched 2414 /* Embedded images in data links can be shown immediately as they are already fetched
2415 data that is part of the document. */ { 2415 data that is part of the document. */
2416 if (prefs_App()->openDataUrlImagesOnLoad) {
2416 iGmDocument *doc = d->view.doc; 2417 iGmDocument *doc = d->view.doc;
2417 for (size_t linkId = 1; ; linkId++) { 2418 for (size_t linkId = 1; ; linkId++) {
2418 const int linkFlags = linkFlags_GmDocument(doc, linkId); 2419 const int linkFlags = linkFlags_GmDocument(doc, linkId);
diff --git a/src/ui/util.c b/src/ui/util.c
index 53ee8fda..b9f37476 100644
--- a/src/ui/util.c
+++ b/src/ui/util.c
@@ -2497,6 +2497,7 @@ iWidget *makePreferences_Widget(void) {
2497 { "input id:prefs.searchurl url:1 noheading:1" }, 2497 { "input id:prefs.searchurl url:1 noheading:1" },
2498 { "padding" }, 2498 { "padding" },
2499 { "toggle id:prefs.bookmarks.addbottom" }, 2499 { "toggle id:prefs.bookmarks.addbottom" },
2500 { "toggle id:prefs.dataurl.openimages" },
2500 { "toggle id:prefs.archive.openindex" }, 2501 { "toggle id:prefs.archive.openindex" },
2501 { "radio device:1 id:prefs.pinsplit", 0, 0, (const void *) pinSplitItems }, 2502 { "radio device:1 id:prefs.pinsplit", 0, 0, (const void *) pinSplitItems },
2502 { "padding" }, 2503 { "padding" },
@@ -2569,6 +2570,7 @@ iWidget *makePreferences_Widget(void) {
2569 const iMenuItem networkPanelItems[] = { 2570 const iMenuItem networkPanelItems[] = {
2570 { "title id:heading.prefs.network" }, 2571 { "title id:heading.prefs.network" },
2571 { "toggle id:prefs.decodeurls" }, 2572 { "toggle id:prefs.decodeurls" },
2573 { "input id:prefs.urlsize maxlen:10 selectall:1" },
2572 { "padding" }, 2574 { "padding" },
2573 { "input id:prefs.cachesize maxlen:4 selectall:1 unit:mb" }, 2575 { "input id:prefs.cachesize maxlen:4 selectall:1 unit:mb" },
2574 { "input id:prefs.memorysize maxlen:4 selectall:1 unit:mb" }, 2576 { "input id:prefs.memorysize maxlen:4 selectall:1 unit:mb" },
@@ -2643,6 +2645,7 @@ iWidget *makePreferences_Widget(void) {
2643 addDialogPadding_(headings, values); 2645 addDialogPadding_(headings, values);
2644 addDialogToggle_(headings, values, "${prefs.hoverlink}", "prefs.hoverlink"); 2646 addDialogToggle_(headings, values, "${prefs.hoverlink}", "prefs.hoverlink");
2645 addDialogToggle_(headings, values, "${prefs.bookmarks.addbottom}", "prefs.bookmarks.addbottom"); 2647 addDialogToggle_(headings, values, "${prefs.bookmarks.addbottom}", "prefs.bookmarks.addbottom");
2648 addDialogToggle_(headings, values, "${prefs.dataurl.openimages}", "prefs.dataurl.openimages");
2646 addDialogToggle_(headings, values, "${prefs.archive.openindex}", "prefs.archive.openindex"); 2649 addDialogToggle_(headings, values, "${prefs.archive.openindex}", "prefs.archive.openindex");
2647 if (deviceType_App() != phone_AppDeviceType) { 2650 if (deviceType_App() != phone_AppDeviceType) {
2648 addChild_Widget(headings, iClob(makeHeading_Widget("${prefs.pinsplit}"))); 2651 addChild_Widget(headings, iClob(makeHeading_Widget("${prefs.pinsplit}")));