From cb3a5e53721b03d2d12c0ebe227f1a41dc9656f8 Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma Date: Sat, 6 Aug 2016 13:05:45 +0200 Subject: sfeed_frames, sfeed_html: don't use HTML tables reasons: - HTML table rendering is extremely slow (invalidate because of resizing cells etc). - whitespace wrapping does not work properly in ancient browsers, links(1). --- sfeed_html.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) (limited to 'sfeed_html.c') diff --git a/sfeed_html.c b/sfeed_html.c index 6f6811c..ee45607 100644 --- a/sfeed_html.c +++ b/sfeed_html.c @@ -31,7 +31,6 @@ printfeed(FILE *fp, struct feed *f) xmlencode(f->name, stdout); fputs("\n", stdout); } - fputs("\n", stdout); while ((linelen = getline(&line, &linesize, fp)) > 0) { if (line[linelen - 1] == '\n') @@ -51,15 +50,9 @@ printfeed(FILE *fp, struct feed *f) f->totalnew += isnew; f->total++; - if (isnew) - fputs("", stdout); - else - fputs("", stdout); - fputs("\n", stdout); + fputs("\n", stdout); } - fputs("
", stdout); - fprintf(stdout, "%04d-%02d-%02d %02d:%02d", + fprintf(stdout, "%04d-%02d-%02d %02d:%02d ", tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min); - fputs("", stdout); if (isnew) fputs("", stdout); if (islink) { @@ -72,9 +65,8 @@ printfeed(FILE *fp, struct feed *f) fputs("", stdout); if (isnew) fputs("", stdout); - fputs("
\n", stdout); } int @@ -110,6 +102,7 @@ main(int argc, char *argv[]) fputs("\t\t
\n", stdout); else fputs("\t\t
\n", stdout); + fputs("
", stdout);
 
 	if (argc == 1) {
 		if (!(feeds[0] = calloc(1, sizeof(struct feed))))
@@ -132,7 +125,7 @@ main(int argc, char *argv[])
 			fclose(fp);
 		}
 	}
-	fputs("
\n", stdout); /* div items */ + fputs("\n
\n", stdout); /* div items */ if (showsidebar) { fputs("\t
\n\t\t