diff --git a/src/classic.c b/src/classic.c index 8493df1..41c803c 100644 --- a/src/classic.c +++ b/src/classic.c @@ -17,7 +17,8 @@ void classic_stylesheet(FILE* out, const char* top) { free(nodes); } - if(breadcrumb_bgcolor == NULL) breadcrumb_bgcolor = "#003366"; + if(breadcrumb_bgcolor == NULL) + breadcrumb_bgcolor = "#003366"; fprintf(out, "body {\n"); fprintf(out, " padding: 0;\n"); @@ -129,7 +130,8 @@ void classic_stylesheet(FILE* out, const char* top) { void classic_head(FILE* out, const char* top, xl_node_t* header) { xl_node_t* child; - fprintf(out, " \n", top); + fprintf(out, " \n", + top); child = header->first_child; while(child != NULL) { @@ -139,8 +141,10 @@ void classic_head(FILE* out, const char* top, xl_node_t* header) { } } -void classic_body(FILE* out, const char* top, const char* title, xl_node_t* body) { - char year[4 + 1 + 4 + 1]; /* no one would use our software in year 10000... right? :) */ +void classic_body(FILE* out, const char* top, const char* title, + xl_node_t* body) { + char year[4 + 1 + 4 + + 1]; /* no one would use our software in year 10000... right? :) */ char* holder = "Unknown people"; char* sitesearch = NULL; xl_node_t** nodes; @@ -182,9 +186,11 @@ void classic_body(FILE* out, const char* top, const char* title, xl_node_t* body free(nodes); } - if(sitesearch == NULL) sitesearch = "https://invalid.link"; + if(sitesearch == NULL) + sitesearch = "https://invalid.link"; - fprintf(out, "
| \n"); if((nodes = xl_get_path(skinconf->root, "breadcrumb.link")) != NULL) { @@ -236,14 +248,18 @@ void classic_body(FILE* out, const char* top, const char* title, xl_node_t* body char* link = xl_get_attribute(nodes[i], "href"); char* name = xl_get_attribute(nodes[i], "name"); - if(link == NULL) link = "https://invalid.link"; + if(link == NULL) + link = "https://invalid.link"; link = u_path(top, link); - if(title == NULL) title = link; + if(title == NULL) + title = link; - if(i > 0) fprintf(out, " |\n"); - fprintf(out, " %s\n", link, name); + if(i > 0) + fprintf(out, " |\n"); + fprintf(out, " %s\n", + link, name); free(link); } @@ -251,19 +267,28 @@ void classic_body(FILE* out, const char* top, const char* title, xl_node_t* body free(nodes); } fprintf(out, " | \n"); - fprintf(out, "\n"); - fprintf(out, " |