# HG changeset patch # User Rik # Date 1330063986 28800 # Node ID cbcaf5602469ac3c7a82d4106f8c21ffc48bc671 # Parent 2bce551c85b6f118ce8eaf7d6a2c3b30cbb65978 doc: Make spacing nicer for Strings chapter of manual. * numbers.txi, strings.txi, int2str.m, bin2dec.m, blanks.m, cstrcat.m, hex2dec.m, index.m pt-mat.cc(string_fill_char): Make spacing nicer for Strings chapter of manual. diff --git a/doc/interpreter/numbers.txi b/doc/interpreter/numbers.txi --- a/doc/interpreter/numbers.txi +++ b/doc/interpreter/numbers.txi @@ -773,9 +773,9 @@ @example @group x = ones (2, 2); -x (1, 1) = single (2) - @result{} x = 2 1 - 1 1 +x(1, 1) = single (2) + @result{} x = 2 1 + 1 1 @end group @end example diff --git a/doc/interpreter/strings.txi b/doc/interpreter/strings.txi --- a/doc/interpreter/strings.txi +++ b/doc/interpreter/strings.txi @@ -187,14 +187,14 @@ @example @group -ischar(collection) - @result{} ans = 1 +ischar (collection) + @result{} 1 -ischar(collection) && isvector(collection) - @result{} ans = 0 +ischar (collection) && isvector (collection) + @result{} 0 -ischar("my string") && isvector("my string") - @result{} ans = 1 +ischar ("my string") && isvector ("my string") + @result{} 1 @end group @end example @@ -243,9 +243,8 @@ @example @group -char([98, 97, 110, 97, 110, 97]) - @result{} ans = - banana +char ([98, 97, 110, 97, 110, 97]) + @result{} banana @end group @end example @@ -256,16 +255,14 @@ @example @group -char("an apple", "two pears") - @result{} ans = - an apple +char ("an apple", "two pears") + @result{} an apple two pears @end group @group -strcat("oc", "tave", " is", " good", " for you") - @result{} ans = - octave is good for you +strcat ("oc", "tave", " is", " good", " for you") + @result{} octave is good for you @end group @end example @@ -275,18 +272,16 @@ @example @group -char("orange", "green", "", "red") - @result{} ans = - orange +char ("orange", "green", "", "red") + @result{} orange green red @end group @group -strvcat("orange", "green", "", "red") - @result{} ans = - orange +strvcat ("orange", "green", "", "red") + @result{} orange green red @end group @@ -299,21 +294,20 @@ @example @group -char(@{"red", "green", "", "blue"@}) - @result{} ans = - red - green +char (@{"red", "green", "", "blue"@}) + @result{} red + green - blue + blue @end group @group -strcat(@{"abc"; "ghi"@}, @{"def"; "jkl"@}) - @result{} ans = - @{ - [1,1] = abcdef - [2,1] = ghijkl - @} +strcat (@{"abc"; "ghi"@}, @{"def"; "jkl"@}) + @result{} + @{ + [1,1] = abcdef + [2,1] = ghijkl + @} @end group @end example @@ -323,17 +317,15 @@ @example @group -strcat(["dir1";"directory2"], ["/";"/"], ["file1";"file2"]) - @result{} ans = - dir1/file1 - directory2/file2 +strcat (["dir1";"directory2"], ["/";"/"], ["file1";"file2"]) + @result{} dir1/file1 + directory2/file2 @end group @group -cstrcat(["thirteen apples"; "a banana"], [" 5$";" 1$"]) - @result{} ans = - thirteen apples 5$ - a banana 1$ +cstrcat (["thirteen apples"; "a banana"], [" 5$";" 1$"]) + @result{} thirteen apples 5$ + a banana 1$ @end group @end example @@ -467,7 +459,7 @@ @example @group hex2dec ("FF") - @result{} ans = 255 + @result{} 255 @end group @end example diff --git a/scripts/general/int2str.m b/scripts/general/int2str.m --- a/scripts/general/int2str.m +++ b/scripts/general/int2str.m @@ -32,7 +32,7 @@ ## 4 5 6 ## ## whos s -## @result{} s = +## @result{} ## Attr Name Size Bytes Class ## ==== ==== ==== ===== ===== ## s 2x7 14 char diff --git a/scripts/strings/bin2dec.m b/scripts/strings/bin2dec.m --- a/scripts/strings/bin2dec.m +++ b/scripts/strings/bin2dec.m @@ -24,7 +24,7 @@ ## @example ## @group ## bin2dec ("1110") -## @result{} 14 +## @result{} 14 ## @end group ## @end example ## diff --git a/scripts/strings/blanks.m b/scripts/strings/blanks.m --- a/scripts/strings/blanks.m +++ b/scripts/strings/blanks.m @@ -23,7 +23,7 @@ ## @example ## @group ## blanks (10); -## whos ans; +## whos ans ## @result{} ## Attr Name Size Bytes Class ## ==== ==== ==== ===== ===== diff --git a/scripts/strings/cstrcat.m b/scripts/strings/cstrcat.m --- a/scripts/strings/cstrcat.m +++ b/scripts/strings/cstrcat.m @@ -32,8 +32,8 @@ ## @group ## s = [ "ab"; "cde" ]; ## cstrcat (s, s, s) -## @result{} "ab ab ab " -## "cdecdecde" +## @result{} "ab ab ab " +## "cdecdecde" ## @end group ## @end example ## @seealso{strcat, char, strvcat} diff --git a/scripts/strings/hex2dec.m b/scripts/strings/hex2dec.m --- a/scripts/strings/hex2dec.m +++ b/scripts/strings/hex2dec.m @@ -24,9 +24,9 @@ ## @example ## @group ## hex2dec ("12B") -## @result{} 299 +## @result{} 299 ## hex2dec ("12b") -## @result{} 299 +## @result{} 299 ## @end group ## @end example ## diff --git a/scripts/strings/index.m b/scripts/strings/index.m --- a/scripts/strings/index.m +++ b/scripts/strings/index.m @@ -28,7 +28,7 @@ ## @example ## @group ## index ("Teststring", "t") -## @result{} 4 +## @result{} 4 ## @end group ## @end example ## diff --git a/src/pt-mat.cc b/src/pt-mat.cc --- a/src/pt-mat.cc +++ b/src/pt-mat.cc @@ -1400,9 +1400,9 @@ @group\n\ string_fill_char (\"X\");\n\ [ \"these\"; \"are\"; \"strings\" ]\n\ - @result{} \"theseXX\"\n\ - \"areXXXX\"\n\ - \"strings\"\n\ + @result{} \"theseXX\"\n\ + \"areXXXX\"\n\ + \"strings\"\n\ @end group\n\ @end example\n\ \n\