diff options
author | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-08-06 13:03:41 +0800 |
---|---|---|
committer | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-08-06 13:03:41 +0800 |
commit | 01cae7cc0030e26ce53c5743fc0dccc4aa7bf683 (patch) | |
tree | 387b16397b214d8ae40ac24672149f4a3b035418 /mbbsd/bbs.c | |
parent | ff24026ce0222c9b0bc78ee075dd0ca9bb50c193 (diff) | |
download | pttbbs-01cae7cc0030e26ce53c5743fc0dccc4aa7bf683.tar pttbbs-01cae7cc0030e26ce53c5743fc0dccc4aa7bf683.tar.gz pttbbs-01cae7cc0030e26ce53c5743fc0dccc4aa7bf683.tar.bz2 pttbbs-01cae7cc0030e26ce53c5743fc0dccc4aa7bf683.tar.lz pttbbs-01cae7cc0030e26ce53c5743fc0dccc4aa7bf683.tar.xz pttbbs-01cae7cc0030e26ce53c5743fc0dccc4aa7bf683.tar.zst pttbbs-01cae7cc0030e26ce53c5743fc0dccc4aa7bf683.zip |
Large Terminal Rules
New api: *lr family calls are used to pad and fir terminal width.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2996 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/bbs.c')
-rw-r--r-- | mbbsd/bbs.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/mbbsd/bbs.c b/mbbsd/bbs.c index 37e8eb8f..0d9269c4 100644 --- a/mbbsd/bbs.c +++ b/mbbsd/bbs.c @@ -159,14 +159,14 @@ set_board(void) /* calculate with other title information */ int l = 0; - snprintf(currBM, sizeof(currBM), "板主:%s", bp->BM); - /* title have +7 leading symbols */ + snprintf(currBM, sizeof(currBM), "板主:%s", bp->BM); + /* title has +7 leading symbols */ l += strlen(bp->title); if(l >= 7) l -= 7; else l = 0; - l += 12; /* fixed stuff */ + l += 8 + strlen(currboard); /* trailing stuff */ l += strlen(bp->brdname); l = t_columns - l -strlen(currBM); @@ -259,12 +259,18 @@ readtitle(void) listmode_desc[currlistmode]); #ifdef USE_COOLDOWN - if (bp->brdattr & BRD_COOLDOWN && !((currmode & MODE_BOARD) || HasUserPerm(PERM_SYSOP))) - prints(" " ANSI_RESET); + if ( bp->brdattr & BRD_COOLDOWN && + !((currmode & MODE_BOARD) || HasUserPerm(PERM_SYSOP))) + outslr("", 44, ANSI_RESET, 0); else #endif - prints(" 人氣:%-5d " ANSI_RESET, + { + char buf[32]; + sprintf(buf, "人氣:%d ", SHM->bcache[currbid - 1].nuser); + outslr("", 44, buf, -1); + outs(ANSI_RESET); + } } static void |