tweaks: normalize the formatting after the previous two changes

master
Benno Schulenberg 2020-11-17 10:23:15 +01:00
parent dc907bfe43
commit 5918ca6cab
2 changed files with 6 additions and 12 deletions

View File

@ -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;
}

View File

@ -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))