mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 01:57:45 +00:00
LibPDF+Tests: Correctly decode text strings without explicit encoding
This commit is contained in:
parent
8f47acee6a
commit
57e2b5ef59
2 changed files with 3 additions and 8 deletions
|
@ -92,9 +92,7 @@ DeprecatedString Document::text_string_to_utf8(DeprecatedString const& text_stri
|
|||
return text_string.substring(3);
|
||||
}
|
||||
|
||||
// FIXME: Convert from PDFDocEncoding to UTF-8.
|
||||
|
||||
return text_string;
|
||||
return TextCodec::decoder_for("PDFDocEncoding"sv)->to_utf8(text_string).release_value_but_fixme_should_propagate_errors().to_deprecated_string();
|
||||
}
|
||||
|
||||
PDFErrorOr<NonnullRefPtr<Document>> Document::create(ReadonlyBytes bytes)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue