Opened 7 years ago

Closed 7 years ago

#10 closed defect (fixed)

'help' word wrapping problem

Reported by: hawke@… Owned by: oxygene
Priority: minor Milestone:
Component: FILO Version:
Keywords: Cc:
Dependencies: Patch Status: patch has been committed


The help system seems to have slight problems with word wrapping.

For example, 'help terminal':
terminal: terminal [--no-echo] [--no-edit] [--timeout=SECS] [--lines=LINES] [--


...that is, the line beginning 'terminal:' goes out to column 79, and then on column 80 of the next line, the character 's' is printed. It looks like filo is maybe expecting CR or LF to do both?

Attachments (1)

filo-newlines.diff (730 bytes) - added by oxygene 7 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 7 years ago by oxygene

  • Owner changed from somebody to oxygene
  • Status changed from new to assigned

You're on the right track, I think. Following fixes it for me:
--- main/grub/char_io.c (revision 2062)
+++ main/grub/char_io.c (local)
@@ -935,6 +935,7 @@

} else if (isprint(c)) {

getyx(stdscr, y, x);
if (x + 1 == COLS) {

+ console_putchar('\r');


if (console_color_state == COLOR_STATE_HIGHLIGHT)

There is another issue (the four spaces on the long description lines are not always clean). Once I figured that out, I'll post a patch

Changed 7 years ago by oxygene

comment:2 Changed 7 years ago by oxygene

  • Patch Status changed from there is no patch to patch needs review

Patch attached. I'll need to figure out why grub_printf("const string") is different than grub_putstr("const string"), but putstr is the faster choice anyway (not that this really matters ;-) )

comment:3 Changed 7 years ago by oxygene

  • Patch Status changed from patch needs review to patch has been committed

committed in rev 76

comment:4 Changed 7 years ago by oxygene

  • Resolution set to fixed
  • Status changed from assigned to closed

Add Comment

Modify Ticket

as closed The owner will remain oxygene.
The resolution will be deleted. Next status will be 'reopened'.

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.