mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 08:37:46 +00:00
Userland: Replace most printf-style APIs with AK::Format APIs :^)
This commit is contained in:
parent
4f1889c2cb
commit
f5c35fccca
75 changed files with 642 additions and 644 deletions
|
@ -70,7 +70,7 @@ int main(int argc, char* argv[])
|
|||
}
|
||||
}
|
||||
if (!section) {
|
||||
fprintf(stderr, "No man page for %s\n", name);
|
||||
warnln("No man page for {}", name);
|
||||
exit(1);
|
||||
}
|
||||
}
|
||||
|
@ -92,11 +92,11 @@ int main(int argc, char* argv[])
|
|||
auto buffer = file->read_all();
|
||||
auto source = String::copy(buffer);
|
||||
|
||||
printf("%s(%s)\t\tSerenityOS manual\n", name, section);
|
||||
outln("{}({})\t\tSerenityOS manual", name, section);
|
||||
|
||||
auto document = Markdown::Document::parse(source);
|
||||
VERIFY(document);
|
||||
|
||||
String rendered = document->render_for_terminal(view_width);
|
||||
printf("%s", rendered.characters());
|
||||
out("{}", rendered);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue