Set paragraph spacing from stylesheet
authorThomas White <taw@bitwiz.me.uk>
Thu, 18 Oct 2018 06:54:24 +0000 (08:54 +0200)
committerThomas White <taw@bitwiz.me.uk>
Thu, 18 Oct 2018 06:54:24 +0000 (08:54 +0200)
src/sc_interp.c

index 0b39d00..e357150 100644 (file)
@@ -1045,6 +1045,12 @@ static void apply_style(SCInterpreter *scin, Stylesheet *ss, const char *path)
        result = stylesheet_lookup(ss, fullpath);
        if ( result != NULL ) set_padding(sc_interp_get_frame(scin), result);
 
+       /* Paragraph spacing */
+       strcpy(fullpath, path);
+       strcat(fullpath, ".paraspace");
+       result = stylesheet_lookup(ss, fullpath);
+       if ( result != NULL ) set_paraspace(scin, result);
+
        update_bg(scin);
 }