# HG changeset patch # User Mikael Berthe # Date 1141494749 -3600 # Node ID e1639629c87bbb129ff562bc789eeb6a6b098d40 # Parent 75dde88f1884cca73f5ad785cddb21f7ef9fecb1 Rename color options diff -r 75dde88f1884 -r e1639629c87b mcabber/mcabberrc.example --- a/mcabber/mcabberrc.example Sat Mar 04 18:50:21 2006 +0100 +++ b/mcabber/mcabberrc.example Sat Mar 04 18:52:29 2006 +0100 @@ -136,12 +136,24 @@ # Colors # Colors are: black, red, green, yellow, blue, magenta, cyan, white # You can use the "default" color, too (i.e. for transparent background) +# +# background: background color of the chat window and the log window +# general: text color in the chat window and the log window +# bgstatus: background color of the status lines +# status: text color of the status lines +# roster: text color of the roster (buddylist) normal items +# bgrostersel: background color of the selected roster item +# rostersel: text color of the selected roster item +# rosternewmsg: text color of items with unread messages +# #set color_background = blue #set color_general = white -#set color_newmessage = red -#set color_rosternormal = magenta -#set color_rosterselect = black -#set color_backselected = cyan +#set color_bgstatus = blue +#set color_status = white +#set color_roster = green +#set color_bgrostersel = cyan +#set color_rostersel = blue +#set color_rosternewmsg = red # Style # Note: the "log_win_height" and "roster_width" values below can be set diff -r 75dde88f1884 -r e1639629c87b mcabber/src/screen.c --- a/mcabber/src/screen.c Sat Mar 04 18:50:21 2006 +0100 +++ b/mcabber/src/screen.c Sat Mar 04 18:52:29 2006 +0100 @@ -131,17 +131,17 @@ "", "", "general", "status", - "newmsg", - "rosterselect", - "rosternormal", + "roster", + "rostersel", + "rosternewmsg", NULL }; char *tmp = g_new(char, 512); const char *color; const char *background = settings_opt_get("color_background"); - const char *backselected = settings_opt_get("color_backselected"); - const char *backstatus = settings_opt_get("color_backstatus"); + const char *backselected = settings_opt_get("color_bgrostersel"); + const char *backstatus = settings_opt_get("color_bgstatus"); int i = 0; // Default values @@ -168,16 +168,16 @@ init_pair(i+1, ((color) ? FindColor(color) : COLOR_WHITE), FindColor(backstatus)); break; - case COLOR_NMSG: - init_pair(i+1, ((color) ? FindColor(color) : COLOR_RED), + case COLOR_ROSTER: + init_pair(i+1, ((color) ? FindColor(color) : COLOR_GREEN), FindColor(background)); break; - case COLOR_BD_DESSEL: + case COLOR_ROSTERSEL: init_pair(i+1, ((color) ? FindColor(color) : COLOR_BLUE), FindColor(backselected)); break; - case COLOR_BD_DES: - init_pair(i+1, ((color) ? FindColor(color) : COLOR_GREEN), + case COLOR_ROSTERNMSG: + init_pair(i+1, ((color) ? FindColor(color) : COLOR_RED), FindColor(background)); break; } @@ -789,16 +789,16 @@ if (budstate >= 0 && budstate < imstatus_size && currentstatus != offline) status = imstatus2char[budstate]; if (buddy == current_buddy) { - wattrset(rosterWnd, COLOR_PAIR(COLOR_BD_DESSEL)); + wattrset(rosterWnd, COLOR_PAIR(COLOR_ROSTERSEL)); // The 3 following lines aim to color the whole line wmove(rosterWnd, i, 0); for (n = 0; n < maxx; n++) waddch(rosterWnd, ' '); } else { if (pending == '#') - wattrset(rosterWnd, COLOR_PAIR(COLOR_NMSG)); + wattrset(rosterWnd, COLOR_PAIR(COLOR_ROSTERNMSG)); else - wattrset(rosterWnd, COLOR_PAIR(COLOR_BD_DES)); + wattrset(rosterWnd, COLOR_PAIR(COLOR_ROSTER)); } if (ismuc) { diff -r 75dde88f1884 -r e1639629c87b mcabber/src/screen.h --- a/mcabber/src/screen.h Sat Mar 04 18:50:21 2006 +0100 +++ b/mcabber/src/screen.h Sat Mar 04 18:52:29 2006 +0100 @@ -6,11 +6,11 @@ #include "logprint.h" -#define COLOR_GENERAL 3 -#define COLOR_STATUS 4 -#define COLOR_NMSG 5 -#define COLOR_BD_DESSEL 6 -#define COLOR_BD_DES 7 +#define COLOR_GENERAL 3 +#define COLOR_STATUS 4 +#define COLOR_ROSTER 5 +#define COLOR_ROSTERSEL 6 +#define COLOR_ROSTERNMSG 7 // Length of the timestamp & flag prefix in the chat buffer window #define PREFIX_WIDTH 17