diff options
author | rgrimes <rgrimes@FreeBSD.org> | 1995-05-30 03:57:47 +0000 |
---|---|---|
committer | rgrimes <rgrimes@FreeBSD.org> | 1995-05-30 03:57:47 +0000 |
commit | 4f960dd75f181e9fa2edc44324f15f0ab5c64b37 (patch) | |
tree | 15a9c7203efd47ba6dde2896fdb6327dddd4547f /usr.sbin/pcvt/fed | |
parent | 30ef9631c5eac7f8254bd3d7ad274d34d9f518b8 (diff) | |
download | FreeBSD-src-4f960dd75f181e9fa2edc44324f15f0ab5c64b37.zip FreeBSD-src-4f960dd75f181e9fa2edc44324f15f0ab5c64b37.tar.gz |
Remove trailing whitespace.
Diffstat (limited to 'usr.sbin/pcvt/fed')
-rw-r--r-- | usr.sbin/pcvt/fed/edit.c | 66 | ||||
-rw-r--r-- | usr.sbin/pcvt/fed/fed.c | 22 | ||||
-rw-r--r-- | usr.sbin/pcvt/fed/fed.h | 2 | ||||
-rw-r--r-- | usr.sbin/pcvt/fed/misc.c | 50 | ||||
-rw-r--r-- | usr.sbin/pcvt/fed/select.c | 50 |
5 files changed, 95 insertions, 95 deletions
diff --git a/usr.sbin/pcvt/fed/edit.c b/usr.sbin/pcvt/fed/edit.c index c15a90c..67d616b 100644 --- a/usr.sbin/pcvt/fed/edit.c +++ b/usr.sbin/pcvt/fed/edit.c @@ -14,7 +14,7 @@ * 3. All advertising materials mentioning features or use of this software * must display the following acknowledgement: * This product includes software developed by Hellmuth Michaelis. - * 4. The name of the developer may not be used to endorse or promote + * 4. The name of the developer may not be used to endorse or promote * products derived from this software without specific prior written * permission. * @@ -29,7 +29,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * edit.c, 3.00, last edit-date: [Sun Jan 2 20:08:27 1994] + * edit.c, 3.00, last edit-date: [Sun Jan 2 20:08:27 1994] */ /*--------------------------------------------------------------------------- @@ -57,13 +57,13 @@ static int pen; void edit_mode(void) { mvwprintw(cmd_win,1,1,"(W)hite "); - mvwprintw(cmd_win,2,1,"(Black "); + mvwprintw(cmd_win,2,1,"(Black "); mvwprintw(cmd_win,3,1,"(I)nvert "); mvwprintw(cmd_win,4,1,"(R)ow BLACK "); mvwprintw(cmd_win,5,1,"(r)ow WHITE "); mvwprintw(cmd_win,6,1,"(C)ol BLACK "); - mvwprintw(cmd_win,7,1,"(c)ol WHITE "); - mvwprintw(cmd_win,8,1,"(Q)uit/Save "); + mvwprintw(cmd_win,7,1,"(c)ol WHITE "); + mvwprintw(cmd_win,8,1,"(Q)uit/Save "); mvwprintw(cmd_win,9 ,1,"e(X)it/undo "); mvwprintw(cmd_win,10,1,"Pen (U)p "); @@ -73,7 +73,7 @@ void edit_mode(void) mvwprintw(cmd_win,14,1,"(^N)ext Line"); mvwprintw(cmd_win,15,1,"(^F)orwd Col"); mvwprintw(cmd_win,16,1,"(^B)ack Col"); - wrefresh(cmd_win); + wrefresh(cmd_win); } /*---------------------------------------------------------------------------* @@ -88,23 +88,23 @@ int edit(void) c = r = 0; pen = UP; - + for(;;) { if(pen == DOWN) dis_cmd(" Edit Mode, the Pen is DOWN"); else - dis_cmd(" Edit Mode, the Pen is UP"); - + dis_cmd(" Edit Mode, the Pen is UP"); + l = ((mvwinch(ch_win,(r+1),(c+1))) & A_CHARTEXT); wattron(ch_win,A_REVERSE); mvwprintw(ch_win,(r+1),(c+1),"%c",l); - wattroff(ch_win,A_REVERSE); + wattroff(ch_win,A_REVERSE); wmove(ch_win,(r+1),(c+1)); wrefresh(ch_win); k_ch = wgetch(ch_win); - + switch(k_ch) { case K_LEFT: @@ -182,33 +182,33 @@ int edit(void) case 'W': setchr(WHITE); break; - + case 'b': case 'B': setchr(BLACK); break; - + case 'i': case 'I': invert(); break; - + case 'r': setrow(WHITE); break; - + case 'R': setrow(BLACK); break; - + case 'c': setcol(WHITE); break; - + case 'C': setcol(BLACK); break; - + case 'u': case 'U': pen = UP; @@ -218,11 +218,11 @@ int edit(void) case 'D': pen = DOWN; break; - + default: beep(); break; - + } } } @@ -237,12 +237,12 @@ void normal_ch(int r, int c) if(pen == DOWN) mvwprintw(ch_win,(r+1),(c+1),"*"); else - mvwprintw(ch_win,(r+1),(c+1),"%c",l); + mvwprintw(ch_win,(r+1),(c+1),"%c",l); wmove(ch_win,(r+1),(c+1)); } /*---------------------------------------------------------------------------* - * + * *---------------------------------------------------------------------------*/ void chg_pt(int r, int c) { @@ -262,7 +262,7 @@ void chg_pt(int r, int c) void invert(void) { int r,c; - + r = 1; while(r <= ch_height) @@ -273,7 +273,7 @@ void invert(void) if(WHITE == mvwinch(ch_win, r, c)) mvwaddch(ch_win, r, c, BLACK); else - mvwaddch(ch_win, r, c, WHITE); + mvwaddch(ch_win, r, c, WHITE); c++; } r++; @@ -286,15 +286,15 @@ void invert(void) void setchr(char type) { int r,c; - + r = 1; - + while(r <= ch_height) { c = 1; while(c <= ch_width) { - mvwaddch(ch_win, r, c, type); + mvwaddch(ch_win, r, c, type); c++; } r++; @@ -308,13 +308,13 @@ void setrow(char type) { int r,c; - getyx(ch_win,r,c); + getyx(ch_win,r,c); c = 1; - + while(c <= ch_width) { - mvwaddch(ch_win, r, c, type); + mvwaddch(ch_win, r, c, type); c++; } } @@ -326,13 +326,13 @@ void setcol(char type) { int r,c; - getyx(ch_win,r,c); + getyx(ch_win,r,c); r = 1; - + while(r <= ch_height) { - mvwaddch(ch_win, r, c, type); + mvwaddch(ch_win, r, c, type); r++; } } diff --git a/usr.sbin/pcvt/fed/fed.c b/usr.sbin/pcvt/fed/fed.c index aa577ab..d2fa4f3 100644 --- a/usr.sbin/pcvt/fed/fed.c +++ b/usr.sbin/pcvt/fed/fed.c @@ -14,7 +14,7 @@ * 3. All advertising materials mentioning features or use of this software * must display the following acknowledgement: * This product includes software developed by Hellmuth Michaelis. - * 4. The name of the developer may not be used to endorse or promote + * 4. The name of the developer may not be used to endorse or promote * products derived from this software without specific prior written * permission. * @@ -29,7 +29,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * fed.c, 3.00, last edit-date: [Sun Jan 2 20:08:45 1994] + * fed.c, 3.00, last edit-date: [Sun Jan 2 20:08:45 1994] */ /*--------------------------------------------------------------------------- @@ -53,7 +53,7 @@ void main(int argc, char *argv[]) int i; int row, col; int ret; - + if(argc != 2) { fprintf(stderr,"EGA/VGA Fonteditor, Rel 1.00\n"); @@ -81,10 +81,10 @@ void main(int argc, char *argv[]) if(ch_width == WIDTH16) addstr("1234567890123456"); else - addstr("12345678"); + addstr("12345678"); /* charcater vertical ruler */ - + for(i=1; i < ch_height+1; i++) mvprintw((WINROW+i), (CHCOL + ((WIDTH16 - ch_width)/2) - 2), "%2d", i); @@ -112,19 +112,19 @@ void main(int argc, char *argv[]) cmd_win = newwin(((WSIZE)+(2*WBORDER)),(CMDSIZE+(2*WBORDER)), WINROW,CMDCOL); - keypad(cmd_win,TRUE); + keypad(cmd_win,TRUE); idlok(cmd_win, TRUE); box(cmd_win,'|','-'); sel_mode(); - + /* character font window */ ch_win = newwin((ch_height+(2*WBORDER)),(ch_width+(2*WBORDER)), WINROW, CHCOL+((WIDTH16 - ch_width)/2)); keypad(ch_win,TRUE); idlok(ch_win, TRUE); - + box(ch_win,'|','-'); wrefresh(ch_win); @@ -132,7 +132,7 @@ void main(int argc, char *argv[]) set_win = newwin((WSIZE+(2*WBORDER)),((WSIZE*2)+(2*WBORDER)), WINROW,SETCOL); /* whole character set */ - keypad(set_win,TRUE); + keypad(set_win,TRUE); idlok(set_win, TRUE); box(set_win,'|','-'); @@ -152,10 +152,10 @@ void main(int argc, char *argv[]) wmove(set_win,1,1); wrefresh(set_win); -/* start */ +/* start */ clr_cmd(); - + curchar = 0; if((ret = selectc()) == 1) diff --git a/usr.sbin/pcvt/fed/fed.h b/usr.sbin/pcvt/fed/fed.h index 27a32c3..0911d37 100644 --- a/usr.sbin/pcvt/fed/fed.h +++ b/usr.sbin/pcvt/fed/fed.h @@ -14,7 +14,7 @@ * 3. All advertising materials mentioning features or use of this software * must display the following acknowledgement: * This product includes software developed by Hellmuth Michaelis. - * 4. The name of the developer may not be used to endorse or promote + * 4. The name of the developer may not be used to endorse or promote * products derived from this software without specific prior written * permission. * diff --git a/usr.sbin/pcvt/fed/misc.c b/usr.sbin/pcvt/fed/misc.c index a0dff32..c6707ba 100644 --- a/usr.sbin/pcvt/fed/misc.c +++ b/usr.sbin/pcvt/fed/misc.c @@ -14,7 +14,7 @@ * 3. All advertising materials mentioning features or use of this software * must display the following acknowledgement: * This product includes software developed by Hellmuth Michaelis. - * 4. The name of the developer may not be used to endorse or promote + * 4. The name of the developer may not be used to endorse or promote * products derived from this software without specific prior written * permission. * @@ -29,7 +29,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * misc.c, 3.00, last edit-date: [Sun Jan 2 20:09:21 1994] + * misc.c, 3.00, last edit-date: [Sun Jan 2 20:09:21 1994] */ /*--------------------------------------------------------------------------- @@ -84,9 +84,9 @@ void readfont(char *filename) struct stat sbuf, *sbp; int ret; char buffer[1024]; - + sbp = &sbuf; - + if((in = fopen(filename, "r")) == NULL) { sprintf(buffer, "cannot open file %s for reading", filename); @@ -107,31 +107,31 @@ void readfont(char *filename) ch_height = HEIGHT8X8; ch_width = WIDTH8; break; - + case FONT8X10: ch_height = HEIGHT8X10; ch_width = WIDTH8; break; - + case FONT8X14: ch_height = HEIGHT8X14; ch_width = WIDTH8; break; - + case FONT8X16: ch_height = HEIGHT8X16; ch_width = WIDTH8; break; - + case FONT16X16: ch_height = HEIGHT16X16; ch_width = WIDTH16; break; - + default: fprintf(stderr,"error, file %s is no valid font file, size=%d\n",filename,sbp->st_size); exit(1); - } + } if((fonttab = (unsigned char *)malloc((size_t)sbp->st_size)) == NULL) { @@ -147,7 +147,7 @@ void readfont(char *filename) sprintf(buffer,"error reading file %s, size = %d, ret = %d\n",filename,sbp->st_size, ret); perror(buffer); exit(1); - } + } } /*---------------------------------------------------------------------------* @@ -158,12 +158,12 @@ void writefont() FILE *in, *out; int ret; char buffer[1024]; - + if((in = fopen(lfilename, "r")) != NULL) { int c; char wfn[1024]; - + strcpy(wfn, lfilename); strcat(wfn, ".BAK"); if((out = fopen(wfn, "w")) == NULL) @@ -179,7 +179,7 @@ void writefont() fclose(out); fclose(in); } - + if((out = fopen(lfilename, "w")) == NULL) { sprintf(buffer, "cannot open file %s for writing", lfilename); @@ -192,7 +192,7 @@ void writefont() sprintf(buffer,"error writing file %s, size=%d, ret=%d\n",lfilename,lfilesize, ret); perror(buffer); exit(1); - } + } } /*---------------------------------------------------------------------------* @@ -223,7 +223,7 @@ void move_ch(int src, int dst) { unsigned char *s, *d; int offset = 0; - + if(ch_width == WIDTH16) offset = 2; else @@ -231,7 +231,7 @@ void move_ch(int src, int dst) s = &(fonttab[ch_height * offset * src]); d = &(fonttab[ch_height * offset * dst]); - + bcopy(s, d, (ch_height*offset)); /* src -> dst */ } @@ -243,7 +243,7 @@ void xchg_ch(int src, int dst) unsigned char *s, *d; unsigned char buf[32]; int offset = 0; - + if(ch_width == WIDTH16) offset = 2; else @@ -251,7 +251,7 @@ void xchg_ch(int src, int dst) s = &(fonttab[ch_height * offset * src]); d = &(fonttab[ch_height * offset * dst]); - + bcopy(s, buf, (ch_height*offset)); /* src -> tmp */ bcopy(d, s, (ch_height*offset)); /* dst -> src */ bcopy(buf, d, (ch_height*offset)); /* tmp -> dst */ @@ -266,19 +266,19 @@ void display(int no) char line[32]; int ln_no; unsigned char hibyte; - unsigned char lobyte; + unsigned char lobyte; int offset; int r; offset = 0; r = 1; lobyte = 0; - + if(ch_width == WIDTH16) fontchar = &(fonttab[ch_height * 2 * no]); else fontchar = &(fonttab[ch_height * no]); - + for (ln_no = 0; ln_no < ch_height; ln_no++) { hibyte = *(fontchar + (offset++)); @@ -287,7 +287,7 @@ void display(int no) { lobyte = *(fontchar + offset++); } - + strcpy(line,bitmask[(int)((hibyte >> 4) & 0x0f)]); strcat(line,bitmask[(int)(hibyte & 0x0f)]); @@ -317,7 +317,7 @@ void save_ch(void) int r, c; unsigned short byte; unsigned short shift; - + if(ch_width == WIDTH16) offset = 2; else @@ -326,7 +326,7 @@ void save_ch(void) s = &(fonttab[ch_height * offset * curchar]); r = 1; - + while(r <= ch_height) { c = 1; diff --git a/usr.sbin/pcvt/fed/select.c b/usr.sbin/pcvt/fed/select.c index 6b9d385..b6993bb 100644 --- a/usr.sbin/pcvt/fed/select.c +++ b/usr.sbin/pcvt/fed/select.c @@ -14,7 +14,7 @@ * 3. All advertising materials mentioning features or use of this software * must display the following acknowledgement: * This product includes software developed by Hellmuth Michaelis. - * 4. The name of the developer may not be used to endorse or promote + * 4. The name of the developer may not be used to endorse or promote * products derived from this software without specific prior written * permission. * @@ -29,7 +29,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * select.c, 3.00, last edit-date: [Sun Jan 2 20:09:36 1994] + * select.c, 3.00, last edit-date: [Sun Jan 2 20:09:36 1994] */ /*--------------------------------------------------------------------------- @@ -78,14 +78,14 @@ int selectc() int ret; char h, l; unsigned int k_ch; - + c = (curchar / 16); r = (curchar % 16); for(;;) { dis_cmd(" Select Character"); - + sel_mode(); curchar = r + (c*16); @@ -96,12 +96,12 @@ int selectc() l = ((mvwinch(set_win,(r+1),((c*2)+2))) & A_CHARTEXT); wattron(set_win,A_REVERSE); mvwprintw(set_win,(r+1),((c*2)+1),"%c%c",h,l); - wattroff(set_win,A_REVERSE); + wattroff(set_win,A_REVERSE); wmove(set_win,(r+1),((c*2)+1)); wrefresh(set_win); - + k_ch = wgetch(set_win); - + switch(k_ch) { case K_LEFT: @@ -141,7 +141,7 @@ int selectc() break; case 'e': - case 'E': + case 'E': edit_mode(); dis_cmd(" Edit Character"); display(curchar); @@ -195,25 +195,25 @@ int selectc() case 'q': case 'Q': normal_set(r,c); - wrefresh(set_win); + wrefresh(set_win); return(1); break; - + case 'x': case 'X': normal_set(r,c); - wrefresh(set_win); + wrefresh(set_win); return(0); break; case 0x0c: wrefresh(curscr); break; - + default: beep(); break; - + } } } @@ -221,7 +221,7 @@ int selectc() void normal_set(int r, int c) { char h, l; - + h = ((mvwinch(set_win,(r+1),((c*2)+1))) & A_CHARTEXT); l = ((mvwinch(set_win,(r+1),((c*2)+2))) & A_CHARTEXT); wattroff(set_win,A_REVERSE); @@ -234,7 +234,7 @@ int sel_dest(void) int c, r; char h, l; unsigned int k_ch; - + c = (curchar / 16); r = (curchar % 16); @@ -242,19 +242,19 @@ int sel_dest(void) { curchar = r + (c*16); - + display(curchar); - + h = ((mvwinch(set_win,(r+1),((c*2)+1))) & A_CHARTEXT); l = ((mvwinch(set_win,(r+1),((c*2)+2))) & A_CHARTEXT); wattron(set_win,A_UNDERLINE); mvwprintw(set_win,(r+1),((c*2)+1),"%c%c",h,l); - wattroff(set_win,A_UNDERLINE); + wattroff(set_win,A_UNDERLINE); wmove(set_win,(r+1),((c*2)+1)); wrefresh(set_win); k_ch = wgetch(set_win); - + switch(k_ch) { case K_LEFT: @@ -292,7 +292,7 @@ int sel_dest(void) c++; } break; - + case '\r': case '\n': normal_uset(r,c); @@ -301,9 +301,9 @@ int sel_dest(void) case 0x0c: wrefresh(curscr); break; - + default: - normal_uset(r,c); + normal_uset(r,c); return(-1); } } @@ -315,7 +315,7 @@ void normal_uset(int r, int c) h = ((mvwinch(set_win,(r+1),((c*2)+1))) & A_CHARTEXT); l = ((mvwinch(set_win,(r+1),((c*2)+2))) & A_CHARTEXT); - + wattroff(set_win,A_UNDERLINE); mvwprintw(set_win,(r+1),((c*2)+1),"%c%c",h,l); wmove(set_win,(r+1),((c*2)+1)); @@ -324,9 +324,9 @@ void normal_uset(int r, int c) { wattron(set_win,A_REVERSE); mvwprintw(set_win,(r+1),((c*2)+1),"%c%c",h,l); - wattroff(set_win,A_REVERSE); + wattroff(set_win,A_REVERSE); wmove(set_win,(r+1),((c*2)+1)); - } + } } |