[Cpri-develop] cpri/src drv_html.c,1.6,1.7
Brought to you by:
chrisan,
rasmusmyklebust
|
From: Rasmus M. <ras...@us...> - 2005-01-22 18:19:06
|
Update of /cvsroot/cpri/cpri/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30459 Modified Files: drv_html.c Log Message: Improved description of fonts Index: drv_html.c =================================================================== RCS file: /cvsroot/cpri/cpri/src/drv_html.c,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** drv_html.c 13 Dec 2003 20:04:08 -0000 1.6 --- drv_html.c 22 Jan 2005 18:18:57 -0000 1.7 *************** *** 72,83 **** p += sprintf(p, " %s", align_texts[align]); p += sprintf(p, ">"); ! if (size) { ! if (face) ! p += sprintf(p, "<font size=\"%+d\" face=\"%s\">", size, faces[face]); ! else ! p += sprintf(p, "<font size=\"%+d\">", size); ! } else if (face) { ! p += sprintf(p, "<font face=\"%s\">", faces[face]); ! } if (bold) p += sprintf(p, "<b>"); --- 72,79 ---- p += sprintf(p, " %s", align_texts[align]); p += sprintf(p, ">"); ! if (face) ! p += sprintf(p, "<span style=\"font-size:%d; font-family:%s\">", size, faces[face]); ! else ! p += sprintf(p, "<span style=\"font-size:%d\">", size); if (bold) p += sprintf(p, "<b>"); *************** *** 106,111 **** if (italic) p += sprintf(p, "</i>"); ! if (face||size) ! p += sprintf(p, "</font>"); p += sprintf(p, "</td>\n"); *celltext = 0; --- 102,107 ---- if (italic) p += sprintf(p, "</i>"); ! if (face) ! p += sprintf(p, "</span>"); p += sprintf(p, "</td>\n"); *celltext = 0; *************** *** 144,153 **** "Albertus,Times", "Antique,Times", ! "Times New Roman,Times", "Verdana,Arial,Helvetica", ! "Universe condensed,Arial,Helvetica", ! "Coronet, Courier New,Courier", ! "Courier,Courier New,Courier", ! "Gothic,Courier New,Courier", }; char link[MAXLINKLEN+1], celltext[1000]; --- 140,149 ---- "Albertus,Times", "Antique,Times", ! "'Times New Roman',Times", "Verdana,Arial,Helvetica", ! "'Universe condensed',Arial,Helvetica", ! "Coronet, 'Courier New',Courier", ! "Courier,'Courier New'", ! "Gothic,'Courier New',Courier", }; char link[MAXLINKLEN+1], celltext[1000]; *************** *** 182,188 **** if (underline) strcat(celltext, "</u>"); ! strcat(celltext, "<sup><font size=\"-1\">"); strcat(celltext, s); ! strcat(celltext, "</sup></font>"); if (underline) strcat(celltext, "<u>"); --- 178,184 ---- if (underline) strcat(celltext, "</u>"); ! strcat(celltext, "<sup><span style=\"font-size:smaller\">"); strcat(celltext, s); ! strcat(celltext, "</sup></span>"); if (underline) strcat(celltext, "<u>"); *************** *** 257,261 **** case EPC_FONT_SIZE: _CpriGetIntParam(q, ¶m); ! size = (param - 12) / 2; if (size > 1) { size /= 2; --- 253,258 ---- case EPC_FONT_SIZE: _CpriGetIntParam(q, ¶m); ! size = param; ! /* size = (param - 12) / 2; if (size > 1) { size /= 2; *************** *** 263,267 **** size = 3; } ! } break; case EPC_END_START_SEQUENCE: --- 260,264 ---- size = 3; } ! }*/ break; case EPC_END_START_SEQUENCE: *************** *** 331,335 **** if (embedded) sprintf(celltext, "<table width=%d bgcolor=\"%s\"><tr><td>" ! "<font size=\"%+d\" face=\"%s\">%s%s%s%s%s%s%s</font>" "</td></tr></table>", barw, colors[pattern], size, htmlfaces[face], bold?"<b>":"",underline?"<u>":"",italic?"<i>":"", --- 328,332 ---- if (embedded) sprintf(celltext, "<table width=%d bgcolor=\"%s\"><tr><td>" ! "<span style=\"font-size:%d; font-family:%s>%s%s%s%s%s%s%s</span>" "</td></tr></table>", barw, colors[pattern], size, htmlfaces[face], bold?"<b>":"",underline?"<u>":"",italic?"<i>":"", |