|
@@ -29,6 +29,8 @@
|
|
|
#include <vcc/pretty.h>
|
|
#include <vcc/pretty.h>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+extern int current_sid;
|
|
|
|
|
+
|
|
|
struct theme theme_def = {
|
|
struct theme theme_def = {
|
|
|
.usrname = {
|
|
.usrname = {
|
|
|
.fg = FG_LIGHTBLUE,
|
|
.fg = FG_LIGHTBLUE,
|
|
@@ -54,6 +56,12 @@ struct theme theme_def = {
|
|
|
.mode = MODE_HIGHLIGHT
|
|
.mode = MODE_HIGHLIGHT
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
|
|
+ .sid = {
|
|
|
|
|
+ .fg = FG_RED,
|
|
|
|
|
+ .bg = BG_BLACK ,
|
|
|
|
|
+ .mode = MODE_HIGHLIGHT
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
.time = {
|
|
.time = {
|
|
|
.fg = FG_YELLOW,
|
|
.fg = FG_YELLOW,
|
|
|
.bg = BG_BLACK,
|
|
.bg = BG_BLACK,
|
|
@@ -85,6 +93,7 @@ struct theme *current_theme = &theme_def;
|
|
|
#define curr_sysusername (¤t_theme->sysusername)
|
|
#define curr_sysusername (¤t_theme->sysusername)
|
|
|
#define curr_msg (¤t_theme->msg)
|
|
#define curr_msg (¤t_theme->msg)
|
|
|
#define curr_sysmsg (¤t_theme->sysmsg)
|
|
#define curr_sysmsg (¤t_theme->sysmsg)
|
|
|
|
|
+#define curr_sid (¤t_theme->sid)
|
|
|
#define curr_time (¤t_theme->time)
|
|
#define curr_time (¤t_theme->time)
|
|
|
#define curr_errmsg (¤t_theme->errmsg)
|
|
#define curr_errmsg (¤t_theme->errmsg)
|
|
|
#define curr_helpcmd (¤t_theme->helpcmd)
|
|
#define curr_helpcmd (¤t_theme->helpcmd)
|
|
@@ -134,6 +143,10 @@ int pretty_new_msg(char *usrname, char *buf) {
|
|
|
|
|
|
|
|
int pretty_prompt(char *usrname) {
|
|
int pretty_prompt(char *usrname) {
|
|
|
ansi_csi_st(stderr, MODE_HIGHLIGHT, FG_BLACK, BG_BLACK);
|
|
ansi_csi_st(stderr, MODE_HIGHLIGHT, FG_BLACK, BG_BLACK);
|
|
|
|
|
+
|
|
|
|
|
+ setcolor(stderr, curr_sid);
|
|
|
|
|
+ fprintf(stderr, "#%03d ", current_sid);
|
|
|
|
|
+
|
|
|
setcolor(stderr, curr_usrname);
|
|
setcolor(stderr, curr_usrname);
|
|
|
fprintf(stderr, "%s", usrname);
|
|
fprintf(stderr, "%s", usrname);
|
|
|
|
|
|