commit 09ad0eb5f71c990e3e38dc1de415f799d359aaf0
parent 62ca113ed38e3aeec11fa2db02158f5c80058eaf
Author: Benno Schulenberg <bensberg@telfort.nl>
Date: Wed, 26 Jun 2019 19:07:26 +0200
tweaks: rename a function, to suit better, and reshuffle its parameters
Diffstat:
2 files changed, 4 insertions(+), 6 deletions(-)
diff --git a/src/proto.h b/src/proto.h
@@ -627,8 +627,6 @@ void statusline(message_type importance, const char *msg, ...);
void bottombars(int menu);
void post_one_key(const char *keystroke, const char *tag, int width);
void place_the_cursor(void);
-void edit_draw(linestruct *fileptr, const char *converted,
- int line, size_t from_col);
int update_line(linestruct *fileptr, size_t index);
#ifndef NANO_TINY
int update_softwrapped_line(linestruct *fileptr);
diff --git a/src/winio.c b/src/winio.c
@@ -2410,8 +2410,8 @@ void place_the_cursor(void)
* line to be drawn, and converted is the actual string to be written with
* tabs and control characters replaced by strings of regular characters.
* from_col is the column number of the first character of this "page". */
-void edit_draw(linestruct *fileptr, const char *converted,
- int row, size_t from_col)
+void draw_row(int row, const char *converted, linestruct *fileptr,
+ size_t from_col)
{
#if !defined(NANO_TINY) || defined(ENABLE_COLOR)
size_t from_x = actual_x(fileptr->data, from_col);
@@ -2800,7 +2800,7 @@ int update_line(linestruct *fileptr, size_t index)
/* Expand the piece to be drawn to its representable form, and draw it. */
converted = display_string(fileptr->data, from_col, editwincols, TRUE, FALSE);
- edit_draw(fileptr, converted, row, from_col);
+ draw_row(row, converted, fileptr, from_col);
free(converted);
if (from_col > 0) {
@@ -2867,7 +2867,7 @@ int update_softwrapped_line(linestruct *fileptr)
/* Convert the chunk to its displayable form and draw it. */
converted = display_string(fileptr->data, from_col, to_col - from_col,
TRUE, FALSE);
- edit_draw(fileptr, converted, row++, from_col);
+ draw_row(row++, converted, fileptr, from_col);
free(converted);
if (end_of_line)