commit 5918ca6cab8f44f235b2bb4fb488b2d55ccf7dae
parent dc907bfe435a73ced5e5c34eb5ebe4952b67bf2d
Author: Benno Schulenberg <bensberg@telfort.nl>
Date: Tue, 17 Nov 2020 10:23:15 +0100
tweaks: normalize the formatting after the previous two changes
Diffstat:
2 files changed, 6 insertions(+), 12 deletions(-)
diff --git a/src/move.c b/src/move.c
@@ -594,8 +594,7 @@ void do_left(void)
{
linestruct *was_current = openfile->current;
- if (openfile->current_x > 0)
- {
+ if (openfile->current_x > 0) {
openfile->current_x = step_left(openfile->current->data,
openfile->current_x);
#ifdef ENABLE_UTF8
@@ -604,8 +603,7 @@ void do_left(void)
openfile->current_x = step_left(openfile->current->data,
openfile->current_x);
#endif
- }
- else if (openfile->current != openfile->filetop) {
+ } else if (openfile->current != openfile->filetop) {
openfile->current = openfile->current->prev;
openfile->current_x = strlen(openfile->current->data);
}
@@ -618,8 +616,7 @@ void do_right(void)
{
linestruct *was_current = openfile->current;
- if (openfile->current->data[openfile->current_x] != '\0')
- {
+ if (openfile->current->data[openfile->current_x] != '\0') {
openfile->current_x = step_right(openfile->current->data,
openfile->current_x);
#ifdef ENABLE_UTF8
@@ -628,8 +625,7 @@ void do_right(void)
openfile->current_x = step_right(openfile->current->data,
openfile->current_x);
#endif
- }
- else if (openfile->current != openfile->filebot) {
+ } else if (openfile->current != openfile->filebot) {
openfile->current = openfile->current->next;
openfile->current_x = 0;
}
diff --git a/src/prompt.c b/src/prompt.c
@@ -110,8 +110,7 @@ void do_statusbar_prev_word(void)
/* Move left one character in the answer. */
void do_statusbar_left(void)
{
- if (typing_x > 0)
- {
+ if (typing_x > 0) {
typing_x = step_left(answer, typing_x);
#ifdef ENABLE_UTF8
while (typing_x > 0 && is_zerowidth(answer + typing_x))
@@ -123,8 +122,7 @@ void do_statusbar_left(void)
/* Move right one character in the answer. */
void do_statusbar_right(void)
{
- if (answer[typing_x] != '\0')
- {
+ if (answer[typing_x] != '\0') {
typing_x = step_right(answer, typing_x);
#ifdef ENABLE_UTF8
while (answer[typing_x] != '\0' && is_zerowidth(answer + typing_x))