diff options
author | mongo <andmarti@gmail.com> | 2023-09-28 10:22:14 -0300 |
---|---|---|
committer | mongo <andmarti@gmail.com> | 2023-09-28 10:22:14 -0300 |
commit | 0ba93dce6fa354c3ba06e5a0f337d1633f1e518a (patch) | |
tree | b6d6848a364988a702781eb2824a74921d4dc36a | |
parent | 7ff262c4e455c708f8a6925f017b5da0b99adbda (diff) | |
parent | b97a8fe340073c095c009bc59a61a93a5dfc1e2f (diff) |
Merge branch 'pr-833' into dev
-rwxr-xr-x | src/Makefile | 2 | ||||
-rw-r--r-- | src/actions/plot.c | 2 | ||||
-rw-r--r-- | src/cmds/cmds.c | 8 | ||||
-rw-r--r-- | src/conf.c | 4 | ||||
-rwxr-xr-x | src/doc | 28 | ||||
-rw-r--r-- | src/format.c | 2 | ||||
-rw-r--r-- | src/formats/xlsx.c | 2 | ||||
-rw-r--r-- | src/function.c | 2 | ||||
-rw-r--r-- | src/graph.c | 14 | ||||
-rw-r--r-- | src/input.c | 2 | ||||
-rw-r--r-- | src/interp.c | 2 | ||||
-rw-r--r-- | src/lex.c | 2 | ||||
-rw-r--r-- | src/lua.c | 4 | ||||
-rw-r--r-- | src/main.c | 4 | ||||
-rw-r--r-- | src/maps.c | 2 | ||||
-rw-r--r-- | src/tui.c | 14 | ||||
-rw-r--r-- | src/undo.c | 2 | ||||
-rwxr-xr-x | src/utils/string.c | 4 | ||||
-rw-r--r-- | src/vmtbl.c | 4 | ||||
-rw-r--r-- | src/yank.c | 4 |
20 files changed, 54 insertions, 54 deletions
diff --git a/src/Makefile b/src/Makefile index 0915f41..9831bb3 100755 --- a/src/Makefile +++ b/src/Makefile @@ -82,7 +82,7 @@ ifneq ($(shell uname -s),Darwin) LDLIBS += -pthread endif -# Check for gnuplot existance +# Check for gnuplot existence ifneq (, $(shell which gnuplot)) CFLAGS += -DGNUPLOT endif diff --git a/src/actions/plot.c b/src/actions/plot.c index e308435..c743736 100644 --- a/src/actions/plot.c +++ b/src/actions/plot.c @@ -82,7 +82,7 @@ int plotedit(wchar_t * s) { editor = DFLT_EDITOR; sprintf(command, "%.*s %.*s", 100, editor, 100, path_out); - if (system(command) == -1) sc_error("Failed editting plot file - errno:%d", errno); + if (system(command) == -1) sc_error("Failed editing plot file - errno:%d", errno); ui_resume(); } else { sc_error("error: invalid plot file: %ls", s); diff --git a/src/cmds/cmds.c b/src/cmds/cmds.c index c3a9ef3..e7863e8 100644 --- a/src/cmds/cmds.c +++ b/src/cmds/cmds.c @@ -293,7 +293,7 @@ void int_deletecol(struct sheet * sh, int col, int mult) { erase_area(sh, 0, col, sh->maxrow, col, 0, 1); //important: this mark the ents as deleted rebuild_graph(); // Rebuild of graph is needed. - //But shouldnt! TODO + //But shouldn't! TODO // Copy references from right column cells to left column (which gets removed) for (r = 0; r <= sh->maxrow; r++) { @@ -1278,7 +1278,7 @@ void send_to_interp(wchar_t * oper) { yyparse(); linelim = -1; line[0]='\0'; - // commented on 28/04/2021. EvalAll should be used only on certain ocasions. + // commented on 28/04/2021. EvalAll should be used only on certain occasions. // Use EvalRange instead when possible, and certainly not here everytime sending to interp. //if (get_conf_int("autocalc") && ! roman->loading) EvalAll(); return; @@ -2022,7 +2022,7 @@ void valueize_area(struct sheet * sh, int sr, int sc, int er, int ec) { // delete vertex only if it end up having no edges, no expression, no value, no label.... if (e->connectsTo->edges == NULL && e->connectsTo->back_edges == NULL && !e->connectsTo->ent->expr && !(e->connectsTo->ent->flags & is_valid) && ! e->connectsTo->ent->label) destroy_vertex(sh, e->connectsTo->ent); - // WARNING: an orphan vertex now represents an ent that has an enode thats + // WARNING: an orphan vertex now represents an ent that has an enode that's // need to be evaluated, but do not depend in another cell. e = e->next; } @@ -2596,7 +2596,7 @@ int calc_mobile_rows(struct sheet * sh, int *last_p) { * \details This function finds the number of mobile columns that can fit on * the screen. This number excludes frozen columns as they never leave the * screen, hence their total height is subtracted from the available screen - * area. This number also excludes hidden columns. Displayed mobile columnss + * area. This number also excludes hidden columns. Displayed mobile columns * are considered starting from offscr_sc_cols, however curcol must be within * the displayed columns. If curcol is found to be outside the displayed set * of columns then offscr_sc_cols is adjusted accordingly. @@ -165,7 +165,7 @@ char * get_conf_values(char * salida) { } /** - * \brief Retreive the string value of a given key in user_conf_d + * \brief Retrieve the string value of a given key in user_conf_d * * \details This function will look for a given key in the user_conf_d * dictionary. If the key is found it will return the value of that @@ -183,7 +183,7 @@ char * get_conf_value(const char * key) { } /** - * \brief Retreive the integer value of a given key in user_conf_d + * \brief Retrieve the integer value of a given key in user_conf_d * * \details This function will look for a given key in the user_conf_d * dictionary. If the key is found it will return the value of that @@ -237,7 +237,7 @@ Commands for handling cell content: ordinary strings, since all numbers must be formatted or expressions decompiled on the fly during the search. - ? Same as / but searchs backwards. + ? Same as / but searches backwards. n Move to next search match. N Move to previous search match. @@ -329,8 +329,8 @@ Commands for handling cell content: d<RIGHT> Delete the character under the cursor. dh Delete the character before the cursor. d<LEFT> Delete the character before the cursor. - df{char} Delete until the first occurence of {char} to the right. - dF{char} Delete until the previous occurence of {char} to the left. + df{char} Delete until the first occurrence of {char} to the right. + dF{char} Delete until the previous occurrence of {char} to the left. dt{char} Delete until the next occurrence of {char} to the right. dT{char} Delete until the previous occurrence of {char} to the left. @@ -438,7 +438,7 @@ Commands for handling cell content: spreadsheet, with ".tab" appended. If a range is selected, only that range is exported. NOTE: If you do an export with the :e command, current file - name stays unchaged. + name stays unchanged. See :file command for more details. See 'ignore_hidden' configuration variable below to avoid exporting hidden rows. @@ -629,7 +629,7 @@ Commands for handling cell content: the status line. Take note that current file name is set during loading of Sc-im or with this command. If you do an export with the :e - command, current file name stays unchaged. + command, current file name stays unchanged. :fill {range} {initial_number} {increment_number} Fill range {range} with values. The first cell of the range @@ -746,7 +746,7 @@ Commands for handling cell content: :subtotal {col_range} {operation} {col_operation} Apply subtotals over the data in a selected range. {col_range} is the column to group by. - {operation} can be one of the followings: + {operation} can be one of the following: @sum, @prod, @avg, @count, @stddev, @max, @min {col_operation} is the column whose values will be used to do the {operation}. @@ -842,7 +842,7 @@ Commands for handling cell content: (the rest of the screen scrolls but the column/s stays fixed on the screen). :freezecol {range} - Freeze the columns determinated by the selected range. + Freeze the columns determined by the selected range. :freezerow {row} :freezerow {row:row} @@ -850,7 +850,7 @@ Commands for handling cell content: (the rest of the screen scrolls but the row/s stays fixed on the screen). :freezerow {range} - Freeze the rows determinated by the selected range. + Freeze the rows determined by the selected range. :unfreezecol {column} :unfreezecol {column:column} @@ -918,7 +918,7 @@ Commands for handling cell content: numbers (That are positive) - STRG The cell styling used for cells formatted as strings. - - DATEF The cell styling used for cells formated as + - DATEF The cell styling used for cells formatted as dates. - CELL_SELECTION - The row and column selection styling used on the HEADINGS to indicate the coordinates of the @@ -1041,7 +1041,7 @@ Commands for handling cell content: :trigger b10 "mode=W type=C file=trg.so function=wr2mysql" Function "wr2mysql" in trg.so is called when to - cell b10 is writen a new value. + cell b10 is written a new value. See "examples/Module/module.c" for more Infos. Adding "-Wl,--export-dynamic" in Makefile for linking sc-im, will export all symbols from sc-im, making it @@ -1245,7 +1245,7 @@ Commands for handling cell content: The <C-d> command works on NORMAL and VISUAL modes, and converts cell's text content that represents a date, and sets the numeric value of the cell using using locale's D_FMT format. - After convertion, the same format is applied automatically to the + After conversion, the same format is applied automatically to the cell so that the value is displayed as a date. You can then change the date format with :format command or just leave it as it is with the current locale D_FMT format. @@ -1264,9 +1264,9 @@ Commands for handling cell content: b. With :datefmt command: This command works like <C-d> but instead of using locale's D_FMT - format for convertion, it takes a strftime-compatible format string as + format for conversion, it takes a strftime-compatible format string as a parameter. Its syntax is ':datefmt "{strftime_format}"' - After convertion, the same format is applied automatically to the cell + After conversion, the same format is applied automatically to the cell so that the value is displayed as a date. Example: \12/03/2020 @@ -1429,7 +1429,7 @@ Commands for handling cell content: AUTOBACKUP must be set during sc-im build for this feature to be available. If you set this to 0 but AUTOBACKUP was set during build, it still will - check for existance of backups before loading a file. + check for existence of backups before loading a file. 'show_cursor' [default off] Make the screen cursor follow the active cell. Useful for people diff --git a/src/format.c b/src/format.c index e85e20b..d702217 100644 --- a/src/format.c +++ b/src/format.c @@ -533,7 +533,7 @@ static void reverse(register char *buf) { * When a number is formatted as engineering and is outside of the range, * the format reverts to scientific. * - * To preserve compatability with old spreadsheet files, the third value + * To preserve compatibility with old spreadsheet files, the third value * may be missing, and the default will be fixed point (format 0). * * When an old style sheet is saved, the third value will be stored. diff --git a/src/formats/xlsx.c b/src/formats/xlsx.c index b8b5dff..614009e 100644 --- a/src/formats/xlsx.c +++ b/src/formats/xlsx.c @@ -307,7 +307,7 @@ void get_sheet_data(xmlDocPtr doc, xmlDocPtr doc_strings, xmlDocPtr doc_styles) } else if ( child_node->xmlChildrenNode != NULL && ! strcmp((char *) child_node->xmlChildrenNode->name, "f")) { - // handle the formula if that is whats desidered!! + // handle the formula if that is what's desidered!! if (get_conf_int("xlsx_readformulas") && // dont handle shared formulas right now ! (xmlHasProp(child_node->xmlChildrenNode, (xmlChar *) "t") && diff --git a/src/function.c b/src/function.c index 51a2ecb..171fab3 100644 --- a/src/function.c +++ b/src/function.c @@ -914,7 +914,7 @@ char * dofmt(char * fmtstr, double v) { * \brief doext() * \details Given a command name and a value, run the command with the given * value and read and return its first output line (only) as an allocated - * string, always a copy of se->e.o.s, whic is set appropriately first + * string, always a copy of se->e.o.s, which is set appropriately first * unless external functions are disabled, in which case the previous value * is used. The handling of se->e.o.s. and freezing of command is tricky. * Returning an allocated string in all cases, even if null, insures cell diff --git a/src/graph.c b/src/graph.c index 9996e36..390f0ed 100644 --- a/src/graph.c +++ b/src/graph.c @@ -54,7 +54,7 @@ * track of all the vertex's that depends on the first vertex. * * \details NOTE: an orphan vertex represents an ent that has an enode - * thats need to be evaluated, but do not depend in another cell. + * that's need to be evaluated, but do not depend in another cell. */ #include <stdio.h> @@ -250,9 +250,9 @@ void GraphAddEdge(vertexT * from, vertexT * to) { /** - * \brief Iterate through all verticies and set visited to false + * \brief Iterate through all vertices and set visited to false * - * Iterate through all verticies and set visited to false + * Iterate through all vertices and set visited to false * evalvisited * * \return none @@ -269,7 +269,7 @@ void markAllVerticesNotVisited (int eval_visited) { /** - * \brief Prints vertexes + * \brief Prints vertices * \return none */ void print_vertexs() { @@ -389,7 +389,7 @@ void destroy_vertex(struct sheet * sh, struct ent * ent) { // delete vertex only if it end up having no edges, no expression, no value, no label.... if (e->connectsTo->edges == NULL && e->connectsTo->back_edges == NULL && !e->connectsTo->ent->expr && !(e->connectsTo->ent->flags & is_valid) && ! e->connectsTo->ent->label) destroy_vertex(e->connectsTo->sheet, e->connectsTo->ent); - // WARNING: an orphan vertex now represents an ent that has an enode thats + // WARNING: an orphan vertex now represents an ent that has an enode that's // need to be evaluated, but do not depends on another cell. e = e->next; } @@ -521,7 +521,7 @@ int All_vertexs_of_edges_visited(struct edgeTag * e, int eval_visited) { /** * \brief ents_that_depends_on() * \details get the list of ents that depends on an specific ent - * it adds the ents in "deps" variable, and reallocs as neccesary + * it adds the ents in "deps" variable, and reallocs as necessary * \param[in] struct sheet * sh * \param[in] struct ent * ent * \return none @@ -537,7 +537,7 @@ void ents_that_depends_on(struct sheet * sh, struct ent * ent) { deps[0].vf = dep_size; // we always keep size of list in the first position ! //sc_debug("sheet:%s %d %d - dependency on:%s %d %d", sh->name, ent->row, ent->col, edges->connectsTo->sheet->name, edges->connectsTo->ent->row, edges->connectsTo->ent->col); deps[dep_size-1].vp = lookat(edges->connectsTo->sheet, edges->connectsTo->ent->row, edges->connectsTo->ent->col); - deps[dep_size-1].sheet = edges->connectsTo->sheet; // we should save the sheet asociated with the ent as well + deps[dep_size-1].sheet = edges->connectsTo->sheet; // we should save the sheet associated with the ent as well ents_that_depends_on(edges->connectsTo->sheet, edges->connectsTo->ent); edges->connectsTo->visited = 1; edges = edges->next; diff --git a/src/input.c b/src/input.c index 46f2451..63afe59 100644 --- a/src/input.c +++ b/src/input.c @@ -99,7 +99,7 @@ void handle_input(struct block * buffer) { /* add char to buffer until valid command found. * important: buffer may contain a valid command (for instance, * just a letter in insert mode) but that buffer start may also - * be a possible mapping! (for instace kj in insert mode to exit the mode). + * be a possible mapping! (for instance kj in insert mode to exit the mode). * if so, wait a mapping_timeout (1500ms), before triggering has_cmd.. */ while ( diff --git a/src/interp.c b/src/interp.c index a8a1656..d65767a 100644 --- a/src/interp.c +++ b/src/interp.c @@ -215,7 +215,7 @@ double eval(struct sheet * sh, struct ent * ent, struct enode * e, int rebuild_g int r = eval(sh, ent, e->e.o.left, rebuild_graph); int c = eval(sh, ent, e->e.o.right, rebuild_graph); if (r < 0 || c < 0) { - sc_debug("@getent shouldnt be called with negative parameters %d %d", r, c); + sc_debug("@getent shouldn't be called with negative parameters %d %d", r, c); return (double) 0; } struct ent * vp = *ATBL(sh, sh->tbl, r, c); @@ -342,7 +342,7 @@ int yylex() { * \brief TODO Document atocol() * * \details Given a token string starting with a symbolid column name and - * its valid length, convert column namd ("A"-"Z" or "AA"-"ZZ") to a + * its valid length, convert column name ("A"-"Z" or "AA"-"ZZ") to a * column number (0-N). Never mind if the column number is illegal * (too high). The procedure's name and function are the inverse of coltoa(). * @@ -492,13 +492,13 @@ void doLuaTriger2(int row, int col, int flags) { /* * Lua trigger on a particular cell - * we assume file and function ist correct other lua throught an error + * we assume file and function is correct other lua through an error */ /** * \brief TODO Document doLuaTrigger_cell() * * \details Lua trigger on a particular cell. We assume file and - * function ist correct. Otherwise, Lua throes an error + * function is correct. Otherwise, Lua throes an error * * \return: none */ @@ -154,7 +154,7 @@ extern graphADT graph; * \brief The main() function * * \details The main() function of sc-im. It is the first function called when - * the applicaiton is executed. + * the application is executed. * * \param[in] argc (argument count) is the number of strings pointed to by argv. This * is passed to main() by the system. @@ -587,7 +587,7 @@ void handle_argv_exports() { /** - * \brief Set up signals catched by sc-im + * \brief Set up signals caught by sc-im * \return none */ void signals() { @@ -267,7 +267,7 @@ int exists_map(char * in, int mode) { } /** - * \brief Ammend a mapping to the current session + * \brief Amend a mapping to the current session * * \param[in] in * \param[in] out @@ -1008,7 +1008,7 @@ int ui_show_content(WINDOW * win, int nb_mobile_rows, int nb_mobile_cols) { // num[0]='\0'; // } // - // AVOID showing text content and date formated numeric value both at the same time - number 3 of issue 769 + // AVOID showing text content and date formatted numeric value both at the same time - number 3 of issue 769 if ((*p) && (*p)->format && (*p)->format[0] == 'd') text[0]='\0'; pad_and_align(text, num, fieldlen, align, (*p)->pad, out, sh->row_format[row]); @@ -1332,7 +1332,7 @@ void ui_show_text(char * val) { /** * \brief - * UI function thats called after SIGWINCH signal. + * UI function that's called after SIGWINCH signal. * \return none */ void sig_winchg() { @@ -1566,7 +1566,7 @@ void ui_start_colors() { /** * \brief - * UI function thats called after SIGTSTP signal. + * UI function that's called after SIGTSTP signal. * \return none */ void ui_pause() { @@ -1579,7 +1579,7 @@ void ui_pause() { /** * \brief - * UI function thats called after SIGCONT signal. + * UI function that's called after SIGCONT signal. * \return none */ void ui_resume() { @@ -1594,7 +1594,7 @@ void ui_resume() { /** * \brief - * UI function thats moves input bar to bottom or back to the top + * UI function that's moves input bar to bottom or back to the top * \return none */ void ui_mv_bottom_bar() { @@ -1606,7 +1606,7 @@ void ui_mv_bottom_bar() { /** * \brief - * UI function thats refresh input_pad + * UI function that's refresh input_pad * \return none */ void ui_refresh_pad(int scroll) { @@ -1617,7 +1617,7 @@ void ui_refresh_pad(int scroll) { /** * \brief - * function thats handles mouse movements + * function that's handles mouse movements * \return none */ #ifdef MOUSE @@ -119,7 +119,7 @@ * 1. Remove content from cell or range * 2. Input content into a cell * 3. Edit a cell - * 4. Change alginment of range or cell + * 4. Change alignment of range or cell * 5. Paste range or cell * 6. Shift range or cell with sh, sj, sk, sl * 7. Insert row or column diff --git a/src/utils/string.c b/src/utils/string.c index 0155c0c..f53ce60 100755 --- a/src/utils/string.c +++ b/src/utils/string.c @@ -447,7 +447,7 @@ char * xstrtok(char * line, char * delims) { } /** - * \brief Change the number of occurences of a word in s. Not used. + * \brief Change the number of occurrences of a word in s. Not used. * * \param[in] s * \param[in] word @@ -468,7 +468,7 @@ int count_word_occurrences(char * s, char * word, int overlap) { } /** - * \brief Search substr word inside string and replace all its occurances with replacement + * \brief Search substr word inside string and replace all its occurrences with replacement * * \param[in] string * \param[in] substr diff --git a/src/vmtbl.c b/src/vmtbl.c index 61c6451..0dc8668 100644 --- a/src/vmtbl.c +++ b/src/vmtbl.c @@ -104,7 +104,7 @@ void checkbounds(struct sheet * sh, int * rowp, int * colp) { sc_error(msg); \ return (FALSE); \ } \ - oldptr = newptr /* wait incase we can't alloc */ + oldptr = newptr /* wait in case we can't alloc */ #ifndef PSC static char nolonger[] = "The table can't be any longer"; @@ -115,7 +115,7 @@ static char nowider[] = "The table can't be any wider"; /** * \brief TODO Document growtbl() * - * \details Grow the main && auxillary tables (reset maxrows/mascols + * \details Grow the main && auxiliary tables (reset maxrows/mascols * as needed). toprow &&/|| topcol tells us a better guess of how big * to become. We return TRUE if we could grow, FALSE if not. * \param[in] rowcol @@ -42,7 +42,7 @@ * \brief TODO Write a tbrief file description. * * \details Yanklist doesn't keep references to 'ent' elements, it - * creates new nodes.Tthe yanklist is constantly cleaned out. Example: When + * creates new nodes.The yanklist is constantly cleaned out. Example: When * removing 'ent' elements with `dc`, the original ones are removed * and new elements are created in the yanklist. Important: each 'ent' * element should keep a row and col. @@ -196,7 +196,7 @@ void yank_area(struct sheet * sh, int tlrow, int tlcol, int brrow, int brcol, ch (y_cells)->vp->col = e_ori->col; // work on issue 674 - // if ignore_hidden is set we substract that number to the internal row so all the pasted rows are + // if ignore_hidden is set we subtract that number to the internal row so all the pasted rows are // adjacent. this is a special case when we're pulling hidden rows and we want to ignore those hidden ranges // (example if yanking a result of a filter) if (ignore_hidden) (y_cells)->vp->row -= hid; |