Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
cs24-19fa
git_rec_nano
Commits
5864d975
Commit
5864d975
authored
8 years ago
by
Benno Schulenberg
Browse files
Options
Download
Email Patches
Plain Diff
tweaks: harmonize the routine for tabs with the one for spaces
parent
3ac37642
master
feature/match-parens
refactor/readbility
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/winio.c
+5
-4
src/winio.c
with
5 additions
and
4 deletions
+5
-4
src/winio.c
View file @
5864d975
...
...
@@ -1849,18 +1849,19 @@ char *display_string(const char *buf, size_t start_col, size_t len, bool
#endif
converted
[
index
++
]
=
' '
;
start_col
++
;
/* If buf contains a tab character, interpret it. */
}
else
if
(
*
buf_mb
==
'\t'
)
{
/* Show a tab as a visible character, or as as a space. */
#ifndef NANO_TINY
if
(
ISSET
(
WHITESPACE_DISPLAY
))
{
int
i
;
int
i
=
0
;
for
(
i
=
0
;
i
<
whitespace_len
[
0
]
;
i
++
)
converted
[
index
++
]
=
whitespace
[
i
];
while
(
i
<
whitespace_len
[
0
])
converted
[
index
++
]
=
whitespace
[
i
++
];
}
else
#endif
converted
[
index
++
]
=
' '
;
start_col
++
;
/* Fill the tab up with the required number of spaces. */
while
(
start_col
%
tabsize
!=
0
)
{
converted
[
index
++
]
=
' '
;
start_col
++
;
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help