Compare commits

...

3 Commits

Author SHA1 Message Date
0c17a7f390 Merge remote-tracking branch 'refs/remotes/origin/devel' into devel 2022-10-12 08:29:01 -05:00
62be20817e Routine changes 2022-10-12 08:24:25 -05:00
302764d09b Added .gitignore 2022-10-12 08:22:00 -05:00
4 changed files with 11 additions and 7 deletions

4
.gitignore vendored Normal file
View File

@@ -0,0 +1,4 @@
sample1.txt
program3-4
program3-4-2.c
test1.c

View File

@@ -1,2 +1,2 @@
program3-4: program3-4.c texted.c fileman.c
gcc -g program3-4.c texted.c fileman.c -o program3-4 -Llib -lncursest -Wl,-rpath=lib
gcc program3-4.c texted.c fileman.c -o program3-4 -Llib -lncursest -Wl,-rpath=lib

View File

@@ -42,7 +42,7 @@ int main(int argc,char** argv) {
int rowCounter; //Number of rows to skip reading in a file, when the user presses Page Down
bool eofFound; //Self-explanatory; is EOF found?
int colorScheme; //stores the value of the color scheme - changes when user hits Ctrl-D
int colCounter; //ISN'T USED ELSEWHERE IN THE PROGRAM - SHOULD BE REMOVED
// int colCounter; //ISN'T USED ELSEWHERE IN THE PROGRAM - SHOULD BE REMOVED
char tempChar; //Holds the 'current' character while reading from a file.
int numCharsToPrint; //Weird naming - should be renamed to 'numLinesToPrint' - Number of lines to print in the file explorer.
int numDowns=0; //Stores the number of times the user has pressed the Down Arrow / Page Down
@@ -96,7 +96,7 @@ int main(int argc,char** argv) {
colorScheme=1; // Default value for the color scheme.
rowCounter = 1; // Set this to zero, because we don't want to skip anything
colCounter = 1;
// colCounter = 1;
WINDOW* mainwin = newwin(yLen-7,xLen-9,START_WIN,START_WIN); /*NCURSES - This creates our 'main' window, that will be
used to display ~99% of the actual content.*/

View File

@@ -33,7 +33,7 @@
int run(char* dir) {
char* text;
char* saveLocation;
char* tempSaveLoc;
// char* tempSaveLoc;
int textCounter;
int selRow=1;
// int numCharsCurrent;
@@ -46,7 +46,7 @@ int run(char* dir) {
int numLines;
bool newLineFound;
// int textIndex;
char* shortText;
// char* shortText;
int upArrowDistance;
int charsOnLine;
@@ -82,7 +82,7 @@ int run(char* dir) {
int numNewLinesFound=0;
int indexToBegin=0;
FILE* readFile;
int tempSelRow,tempSelCol;
// int tempSelRow,tempSelCol;
// if (argc > 1) {
if (readFile = fopen(dir,"r")) {
@@ -432,7 +432,7 @@ int run(char* dir) {
endwin();
return 0;
}