summaryrefslogtreecommitdiff
path: root/src/ui
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2021-07-11 08:45:12 +0300
committerJaakko Keränen <jaakko.keranen@iki.fi>2021-07-11 08:45:12 +0300
commit2f60372f8ea9ee6f6bad04d817a79e2b03c91e3b (patch)
treeb6a7edc3d41884695e0523d85521ea6b56c51247 /src/ui
parent1214aecd71df48164a7591b75fd48720f5b930f3 (diff)
Preferences: Added setting for line spacing
IssueID #229
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/documentwidget.c11
-rw-r--r--src/ui/util.c1
2 files changed, 8 insertions, 4 deletions
diff --git a/src/ui/documentwidget.c b/src/ui/documentwidget.c
index 5bded6c6..38f34c77 100644
--- a/src/ui/documentwidget.c
+++ b/src/ui/documentwidget.c
@@ -1298,9 +1298,9 @@ static void postProcessRequestContent_DocumentWidget_(iDocumentWidget *d, iBool
1298 2); 1298 2);
1299 } 1299 }
1300 if (preloadCoverImage_Gempub(d->sourceGempub, d->doc)) { 1300 if (preloadCoverImage_Gempub(d->sourceGempub, d->doc)) {
1301 redoLayout_GmDocument(d->doc); 1301 redoLayout_GmDocument(d->doc);
1302 updateVisible_DocumentWidget_(d); 1302 updateVisible_DocumentWidget_(d);
1303 invalidate_DocumentWidget_(d); 1303 invalidate_DocumentWidget_(d);
1304 } 1304 }
1305 } 1305 }
1306 else if (equal_String(d->mod.url, indexPageUrl_Gempub(d->sourceGempub))) { 1306 else if (equal_String(d->mod.url, indexPageUrl_Gempub(d->sourceGempub))) {
@@ -2461,7 +2461,10 @@ static iBool handleCommand_DocumentWidget_(iDocumentWidget *d, const char *cmd)
2461 invalidate_DocumentWidget_(d); 2461 invalidate_DocumentWidget_(d);
2462 refresh_Widget(w); 2462 refresh_Widget(w);
2463 } 2463 }
2464 else if (equal_Command(cmd, "document.layout.changed") && document_App() == d) { 2464 else if (equal_Command(cmd, "document.layout.changed") && document_Root(get_Root()) == d) {
2465 if (argLabel_Command(cmd, "redo")) {
2466 redoLayout_GmDocument(d->doc);
2467 }
2465 updateSize_DocumentWidget(d); 2468 updateSize_DocumentWidget(d);
2466 } 2469 }
2467 else if (equal_Command(cmd, "pinsplit.set")) { 2470 else if (equal_Command(cmd, "pinsplit.set")) {
diff --git a/src/ui/util.c b/src/ui/util.c
index 5aea4f11..d68274ad 100644
--- a/src/ui/util.c
+++ b/src/ui/util.c
@@ -1809,6 +1809,7 @@ iWidget *makePreferences_Widget(void) {
1809 addRadioButton_(widths, "prefs.linewidth.1000", "${prefs.linewidth.fill}", "linewidth.set arg:1000"); 1809 addRadioButton_(widths, "prefs.linewidth.1000", "${prefs.linewidth.fill}", "linewidth.set arg:1000");
1810 } 1810 }
1811 addChildFlags_Widget(values, iClob(widths), arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag); 1811 addChildFlags_Widget(values, iClob(widths), arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag);
1812 addPrefsInputWithHeading_(headings, values, "prefs.linespacing", iClob(new_InputWidget(5)));
1812 addChild_Widget(headings, iClob(makeHeading_Widget("${prefs.quoteicon}"))); 1813 addChild_Widget(headings, iClob(makeHeading_Widget("${prefs.quoteicon}")));
1813 iWidget *quote = new_Widget(); { 1814 iWidget *quote = new_Widget(); {
1814 addRadioButton_(quote, "prefs.quoteicon.1", "${prefs.quoteicon.icon}", "quoteicon.set arg:1"); 1815 addRadioButton_(quote, "prefs.quoteicon.1", "${prefs.quoteicon.icon}", "quoteicon.set arg:1");