comparison src/conversation.c @ 699:f8acdd22065a

[gaim-migrate @ 709] log chat logon/logoffs to whatever.chat.log committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Wed, 16 Aug 2000 07:13:18 +0000
parents b2ab04e04194
children d904bf694bd7
comparison
equal deleted inserted replaced
698:b2ab04e04194 699:f8acdd22065a
576 if ((font_options & OPT_FONT_FACE) || c->hasfont) { 576 if ((font_options & OPT_FONT_FACE) || c->hasfont) {
577 g_snprintf(buf2, BUF_LONG, "<FONT FACE=\"%s\">%s</FONT>", c->fontface, buf); 577 g_snprintf(buf2, BUF_LONG, "<FONT FACE=\"%s\">%s</FONT>", c->fontface, buf);
578 strcpy(buf, buf2); 578 strcpy(buf, buf2);
579 } 579 }
580 580
581 if (font_options & OPT_FONT_FGCOL) { 581 if ((font_options & OPT_FONT_FGCOL) || c->hasfg) {
582 g_snprintf(buf2, BUF_LONG, "<FONT COLOR=\"#%02X%02X%02X\">%s</FONT>", c->fgcol.red, c->fgcol.green, c->fgcol.blue, buf); 582 g_snprintf(buf2, BUF_LONG, "<FONT COLOR=\"#%02X%02X%02X\">%s</FONT>", c->fgcol.red, c->fgcol.green, c->fgcol.blue, buf);
583 strcpy(buf, buf2); 583 strcpy(buf, buf2);
584 } 584 }
585 585
586 if (font_options & OPT_FONT_BGCOL) { 586 if ((font_options & OPT_FONT_BGCOL) || c->hasbg) {
587 g_snprintf(buf2, BUF_LONG, "<BODY BGCOLOR=\"#%02X%02X%02X\">%s</BODY>", c->bgcol.red, c->bgcol.green, c->bgcol.blue, buf); 587 g_snprintf(buf2, BUF_LONG, "<BODY BGCOLOR=\"#%02X%02X%02X\">%s</BODY>", c->bgcol.red, c->bgcol.green, c->bgcol.blue, buf);
588 strcpy(buf, buf2); 588 strcpy(buf, buf2);
589 } 589 }
590 590
591 #ifdef GAIM_PLUGINS 591 #ifdef GAIM_PLUGINS
1114 1114
1115 gtk_html_append_text(GTK_HTML(c->text), "<BR>", 0); 1115 gtk_html_append_text(GTK_HTML(c->text), "<BR>", 0);
1116 1116
1117 if ((general_options & OPT_GEN_LOG_ALL) || find_log_info(c->name)) { 1117 if ((general_options & OPT_GEN_LOG_ALL) || find_log_info(c->name)) {
1118 char *t1; 1118 char *t1;
1119 char nm[256];
1119 1120
1120 if (general_options & OPT_GEN_STRIP_HTML) { 1121 if (general_options & OPT_GEN_STRIP_HTML) {
1121 t1 = strip_html(what); 1122 t1 = strip_html(what);
1122 } else { 1123 } else {
1123 t1 = what; 1124 t1 = what;
1124 } 1125 }
1125 fd = open_log_file(c->name); 1126 if (c->is_chat)
1127 g_snprintf(nm, 256, "%s.chat", c->name);
1128 else
1129 g_snprintf(nm, 256, "%s", c->name);
1130 fd = open_log_file(nm);
1126 fprintf(fd, "%s\n", t1); 1131 fprintf(fd, "%s\n", t1);
1127 fclose(fd); 1132 fclose(fd);
1128 if (general_options & OPT_GEN_STRIP_HTML) { 1133 if (general_options & OPT_GEN_STRIP_HTML) {
1129 g_free(t1); 1134 g_free(t1);
1130 } 1135 }
1587 c->link_dialog = NULL; 1592 c->link_dialog = NULL;
1588 c->log_dialog = NULL; 1593 c->log_dialog = NULL;
1589 sprintf(c->fontface, "%s", fontface); 1594 sprintf(c->fontface, "%s", fontface);
1590 c->hasfont = 0; 1595 c->hasfont = 0;
1591 c->bgcol = bgcolor; 1596 c->bgcol = bgcolor;
1597 c->hasbg = 0;
1592 c->fgcol = fgcolor; 1598 c->fgcol = fgcolor;
1599 c->hasfg = 0;
1593 1600
1594 gtk_container_add(GTK_CONTAINER(win), paned); 1601 gtk_container_add(GTK_CONTAINER(win), paned);
1595 gtk_container_border_width(GTK_CONTAINER(win), 10); 1602 gtk_container_border_width(GTK_CONTAINER(win), 10);
1596 1603
1597 if ((find_log_info(c->name)) || ((general_options & OPT_GEN_LOG_ALL))) 1604 if ((find_log_info(c->name)) || ((general_options & OPT_GEN_LOG_ALL)))