summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-05-30 11:06:35 +0800
committervictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-05-30 11:06:35 +0800
commitcc02fdac3ff52d3661380e40f1742a4af2203676 (patch)
tree102b6c1822eade99e7bfbaa222395bc52d61b681
parent885543f75f49534141214c4adf9b9e6bdc8da1b2 (diff)
downloadpttbbs-cc02fdac3ff52d3661380e40f1742a4af2203676.tar
pttbbs-cc02fdac3ff52d3661380e40f1742a4af2203676.tar.gz
pttbbs-cc02fdac3ff52d3661380e40f1742a4af2203676.tar.bz2
pttbbs-cc02fdac3ff52d3661380e40f1742a4af2203676.tar.lz
pttbbs-cc02fdac3ff52d3661380e40f1742a4af2203676.tar.xz
pttbbs-cc02fdac3ff52d3661380e40f1742a4af2203676.tar.zst
pttbbs-cc02fdac3ff52d3661380e40f1742a4af2203676.zip
just commit it\!
git-svn-id: http://opensvn.csie.org/pttbbs/branches/victor.screen@2032 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--mbbsd/io.c3
-rw-r--r--mbbsd/screen.c21
-rw-r--r--mbbsd/var.c5
3 files changed, 20 insertions, 9 deletions
diff --git a/mbbsd/io.c b/mbbsd/io.c
index fa9b7b5c..f6db7c99 100644
--- a/mbbsd/io.c
+++ b/mbbsd/io.c
@@ -1,6 +1,8 @@
/* $Id$ */
#include "bbs.h"
+#define MAXLASTCMD 12
+
/*
* Mechanism
* =========
@@ -500,7 +502,6 @@ oldgetdata(int line, int col, char *prompt, char *buf, int len, int echo)
register int ch, i;
int clen;
int x = col, y = line;
-#define MAXLASTCMD 12
static char lastcmd[MAXLASTCMD][80];
strip_ansi(buf, buf, STRIP_ALL);
diff --git a/mbbsd/screen.c b/mbbsd/screen.c
index 056ffec4..91c5921a 100644
--- a/mbbsd/screen.c
+++ b/mbbsd/screen.c
@@ -22,7 +22,7 @@ initscr()
{
if (!big_picture) {
#ifdef Try_to_remove_these_code
- scr_lns = scr_lns;
+ scr_lns = t_lines;
scr_cols = ANSILINELEN;
/* scr_cols = MIN(t_columns, ANSILINELEN); */
#endif
@@ -77,8 +77,6 @@ rel_move(int was_col, int was_ln, int new_col, int new_ln)
do_move(new_col, new_ln);
}
-/*
- */
static void
standoutput(char *buf, int ds, int de, int sso, int eso)
{
@@ -126,8 +124,9 @@ redoscr()
bp = &big_picture[j];
if ((len = bp->len)) {
rel_move(tc_col, tc_line, 0, i);
- if (bp->mode & STANDOUT)
+ if (bp->mode & STANDOUT) {
standoutput((char *)bp->data, 0, len, bp->sso, bp->eso);
+ }
else
output((char *)bp->data, len);
tc_col += len;
@@ -193,7 +192,7 @@ refresh()
if (bp->mode & STANDOUT)
standoutput((char *)bp->data, bp->smod, bp->emod + 1,
- bp->sso, bp->eso);
+ bp->sso, bp->eso);
else
output((char *)&bp->data[bp->smod], bp->emod - bp->smod + 1);
tc_col = bp->emod + 1;
@@ -352,11 +351,19 @@ parsecolor(char *buf)
while (val) {
if (atoi(val) < 30) {
+#if 0
+ if (data[0]) {
+ data[len++] = ';';
+ data[len] = 0;
+ }
+ strcpy(&data[len], val);
+#else
if (data[0]) {
data[len++] = ';';
data[len] = 0;
}
strcpy(&data[len], val);
+#endif
}
val = (char *)strtok(NULL, ";");
}
@@ -521,7 +528,7 @@ region_scroll_up(int top, int bottom)
refresh();
}
-/* 開始反白 - 瑩幕上之後的訊息開始反白輸出 */
+/* 開始反白 - 瑩幕上之後的訊息開始反白輸出,會寫在 screenline_t 上。 */
void
standout()
{
@@ -533,6 +540,7 @@ standout()
slp->sso = slp->eso = cur_col;
slp->mode |= STANDOUT;
}
+// outs(strtstandout);
}
/* 結束反白 */
@@ -546,4 +554,5 @@ standend()
standing = NA;
slp->eso = MAX(slp->eso, cur_col);
}
+// outs(endstandout);
}
diff --git a/mbbsd/var.c b/mbbsd/var.c
index c0773882..8b5dfcc1 100644
--- a/mbbsd/var.c
+++ b/mbbsd/var.c
@@ -404,9 +404,10 @@ screenline_t *big_picture = NULL;
#ifdef Try_to_remove_these_code
unsigned char scr_lns;
unsigned short scr_cols;
-#endif
+#else
#define scr_lns t_lines
-#define scr_cols t_columns
+#define scr_cols ANSILINELEN
+#endif
char roll;
/* gomo.c */