"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "bekijk.c" between
lookat_bekijk-1.4.3.tar.gz and lookat_bekijk-1.4.4.tar.gz

About: Lookat/Bekijk is a program to view Un*x text files and manual pages.

bekijk.c  (lookat_bekijk-1.4.3):bekijk.c  (lookat_bekijk-1.4.4)
/* /*
* bekijk.c 1.4.0 * bekijk.c 1.4.0
* *
* Copyright (C) 1997, 1998, 2000, 2001, 2002, 2003, 2006, 2007 Staf Wagemakers Belgium * Copyright (C) 1997, 1998, 2000, 2001, 2002, 2003, 2006, 2007, 2015 Staf Wage makers Belgium
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version. * (at your option) any later version.
* *
* This program is distributed in the hope that it will be useful, * This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of * but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details. * GNU General Public License for more details.
skipping to change at line 568 skipping to change at line 568
m.txt=txt_ok_anu; m.txt=txt_ok_anu;
m.hkey=hkey_ok_anu; m.hkey=hkey_ok_anu;
m.hplace=hplace_ok_anu; m.hplace=hplace_ok_anu;
m.color1=kleur[15]; m.color1=kleur[15];
m.color2=kleur[18]; m.color2=kleur[18];
m.color3=kleur[19]; m.color3=kleur[19];
m.color4=kleur[20]; m.color4=kleur[20];
brol=open_inputwin(7,60,&m,kleur[16],&s,txt,1,win1); brol=open_inputwin(7,60,&m,kleur[16],&s,txt,1,win1);
curs_set(0); curs_set(0);
if (strlen(s.c)&&!brol) { if (strlen(s.c)&&!brol) {
sscanf(s.c,"%ld",&y); sscanf(s.c,"%lu",&y);
if (y) --y; if (y) --y;
else bv.y=0; else bv.y=0;
view_sety(y); view_sety(y);
view_refresh(); view_refresh();
} }
xfree(s.c); xfree(s.c);
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
/* Bijvoegen van een type ... */ /* Bijvoegen van een type ... */
skipping to change at line 786 skipping to change at line 786
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
/* type geheugen terug vrijgeven */ /* type geheugen terug vrijgeven */
/* -------------------------------------------- */ /* -------------------------------------------- */
void free_type(char **cc,int a) void free_type(char **cc,int a)
{ {
int i; int i;
for (i=0;i<=a-1;i++) xfree(cc[i]); for (i=0;i<=a-1;i++) xfree(cc[i]);
xfree(cc); xfree(cc);
cc=NULL; *cc=NULL;
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
/* Funktie voor types... */ /* Funktie voor types... */
/* -------------------------------------------- */ /* -------------------------------------------- */
void set_types () void set_types ()
{ {
MENU m,mm; MENU m,mm;
WINDOW *w; WINDOW *w;
int key_m[]={KEY_UP,KEY_DOWN,'\n',KEY_PPAGE,KEY_NPAGE,27,9}; int key_m[]={KEY_UP,KEY_DOWN,'\n',KEY_PPAGE,KEY_NPAGE,27,9};
int key_mm[]={0,9,'\n',' ',27,'\n'}; int key_mm[]={0,9,'\n',' ',27,'\n'};
skipping to change at line 1334 skipping to change at line 1334
wrefresh(w); wrefresh(w);
} while ((mm.sel<1)||(mm.sel==mm.amount-1)); } while ((mm.sel<1)||(mm.sel==mm.amount-1));
delwin(w); delwin(w);
xfree(backup_colors); xfree(backup_colors);
xfree(mm.txt); xfree(mm.txt);
} }
void cp2stdout(FILE *fp) void cp2stdout(FILE *fp)
{ {
char c; int c;
while(1) { while(1) {
if ((c=getc(fp))==EOF) break; if ((c=getc(fp))==EOF) break;
fputc(c,stdout); fputc(c,stdout);
} }
fclose(fp); fclose(fp);
fclose(stdout); fclose(stdout);
} }
FILE * get_config_file (const char *opentype) FILE * get_config_file (const char *opentype)
{ {
 End of changes. 4 change blocks. 
4 lines changed or deleted 4 lines changed or added

Home  |  About  |  All  |  Newest  |  Fossies Dox  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTPS