From: Alex Maestas Date: Fri, 30 Sep 2022 00:00:39 +0000 (+0000) Subject: update docs, add another test X-Git-Tag: 0.99~1051 X-Git-Url: https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=commitdiff_plain;h=bfbfe238d0733fabd7de1b7342184b118e4b79b4 update docs, add another test --- diff --git a/basis/unicode/control-pictures/control-pictures-docs.factor b/basis/unicode/control-pictures/control-pictures-docs.factor index 2485ffd4bd..0c1e7aabd6 100644 --- a/basis/unicode/control-pictures/control-pictures-docs.factor +++ b/basis/unicode/control-pictures/control-pictures-docs.factor @@ -7,10 +7,19 @@ HELP: control-pictures { $values { "string" string } } -{ $description "Transforms C0 control characters into their corresponding Control Picture block codepoints." } ; +{ $description "Transforms C0 control characters, excepting spaces, into their corresponding Control Picture block codepoints." } ; + +HELP: control-pictures* +{ $values + { "string" string } +} +{ $description "Transforms C0 control characters, including spaces, into their corresponding Control Picture block codepoints." } ; + ARTICLE: "unicode.control-pictures" "Control Pictures" -"The " { $vocab-link "unicode.control-pictures" } " vocabulary provides a utility word " { $link control-pictures } " for transforming characters in the nonprintable " { $url "http://www.unicode.org/charts/PDF/U0000.pdf" "ASCII C0 block" } " to their representations in the " { $url "http://www.unicode.org/charts/PDF/U2400.pdf" "Control Pictures" } " block. It has no effect on any other characters." +"The " { $vocab-link "unicode.control-pictures" } " vocabulary provides utility words for transforming characters in the nonprintable " { $url "http://www.unicode.org/charts/PDF/U0000.pdf" "ASCII C0 block" } " to their representations in the " { $url "http://www.unicode.org/charts/PDF/U2400.pdf" "Control Pictures" } " block. It has no effect on any other characters." +$nl +"Two words are provided - " { $link control-pictures } " transforms control characters, excepting spaces, to their picture form. The variant " { $link control-pictures* } " also transforms spaces." ; ABOUT: "unicode.control-pictures" diff --git a/basis/unicode/control-pictures/control-pictures-tests.factor b/basis/unicode/control-pictures/control-pictures-tests.factor index 35b2b6d496..e67f47a528 100644 --- a/basis/unicode/control-pictures/control-pictures-tests.factor +++ b/basis/unicode/control-pictures/control-pictures-tests.factor @@ -6,6 +6,7 @@ USING: sequences strings tools.test unicode.control-pictures ; { "␡" } [ "\x7f" control-pictures ] unit-test { "a␡b" } [ "a\x7fb" control-pictures ] unit-test +{ "a␡b" } [ "a\x7fb" control-pictures* ] unit-test { "␀␁␂␃␄␅␆␇␈␉␊␋␌␍␎␏␐␑␒␓␔␕␖␗␘␙␚␛␜␝␞␟␠!\"#$%&'()*+,-./" } [ 48 >string control-pictures*