Mercurial > octave
changeset 28753:e82484e1b2f6
doc: grammarcheck documentation.
* plot.txi, jsonencode.cc, strfns.cc, sysdep.cc, integral.m, pol2cart.m,
sph2cart.m, fullfile.m, memory.m, area.m, colorbar.m, stairs.m:
grammarcheck documentation.
author | Rik <rik@octave.org> |
---|---|
date | Thu, 17 Sep 2020 11:07:19 -0700 |
parents | 810eb29fc227 |
children | 86dc599fff0f |
files | doc/interpreter/plot.txi libinterp/corefcn/jsonencode.cc libinterp/corefcn/strfns.cc libinterp/corefcn/sysdep.cc scripts/general/integral.m scripts/general/pol2cart.m scripts/general/sph2cart.m scripts/miscellaneous/fullfile.m scripts/miscellaneous/memory.m scripts/plot/draw/area.m scripts/plot/draw/colorbar.m scripts/plot/draw/stairs.m |
diffstat | 12 files changed, 45 insertions(+), 35 deletions(-) [+] |
line wrap: on
line diff
--- a/doc/interpreter/plot.txi Thu Sep 17 10:24:55 2020 -0700 +++ b/doc/interpreter/plot.txi Thu Sep 17 11:07:19 2020 -0700 @@ -1181,7 +1181,7 @@ In addition, there are several functions which operate on properties of the graphics objects and which also return handles. This includes but is not -limited to the following functions: The functions @code{plot} and @code{plot3} +limited to the following functions: The functions @code{plot} and @code{plot3} return a handle pointing to an object of type @code{line}. The function @code{subplot} returns a handle pointing to an object of type @code{axes}. The functions @code{fill}, @code{trimesh}, and @code{trisurf} return a handle
--- a/libinterp/corefcn/jsonencode.cc Thu Sep 17 10:24:55 2020 -0700 +++ b/libinterp/corefcn/jsonencode.cc Thu Sep 17 11:07:19 2020 -0700 @@ -473,7 +473,7 @@ result will be a column vector. @item -Encoding and decoding is not guaranteed to preserve the Octave data type +Encoding and decoding is not guaranteed to preserve the Octave data type because JSON supports fewer data types than Octave. For example, if you encode an @code{int8} and then decode it, you will get a @code{double}. @end itemize @@ -481,25 +481,26 @@ This table shows the conversions from Octave data types to JSON data types: @multitable @columnfractions 0.50 0.50 -@headitem Octave data type @tab JSON data type -@item logical scalar @tab Boolean -@item logical vector @tab Array of Boolean, reshaped to row vector -@item logical array @tab nested Array of Boolean -@item numeric scalar @tab Number +@headitem Octave data type @tab JSON data type +@item logical scalar @tab Boolean +@item logical vector @tab Array of Boolean, reshaped to row vector +@item logical array @tab nested Array of Boolean +@item numeric scalar @tab Number @item numeric vector @tab Array of Number, reshaped to row vector -@item numeric array @tab nested Array of Number +@item numeric array @tab nested Array of Number @item @code{NaN}, @code{NA}, @code{Inf}, @code{-Inf}@* when @qcode{"ConvertInfAndNaN" = true} @tab @qcode{"null"} @item @code{NaN}, @code{NA}, @code{Inf}, @code{-Inf}@* -when @qcode{"ConvertInfAndNaN" = false} @tab @qcode{"NaN"}, @qcode{"NaN"}, @qcode{"Infinity"}, @qcode{"-Infinity"} +when @qcode{"ConvertInfAndNaN" = false} @tab @qcode{"NaN"}, @qcode{"NaN"}, +@qcode{"Infinity"}, @qcode{"-Infinity"} @item empty array @tab @qcode{"[]"} -@item character vector @tab String -@item character array @tab Array of String +@item character vector @tab String +@item character array @tab Array of String @item empty character array @tab @qcode{""} @item cell scalar @tab Array @item cell vector @tab Array, reshaped to row vector -@item cell array @tab Array, flattened to row vector -@item struct scalar @tab Object +@item cell array @tab Array, flattened to row vector +@item struct scalar @tab Object @item struct vector @tab Array of Object, reshaped to row vector @item struct array @tab nested Array of Object @item classdef object @tab Object
--- a/libinterp/corefcn/strfns.cc Thu Sep 17 10:24:55 2020 -0700 +++ b/libinterp/corefcn/strfns.cc Thu Sep 17 11:07:19 2020 -0700 @@ -1051,10 +1051,10 @@ Return string with valid UTF-8. On encountering invalid UTF-8 in @var{in_str}, the bytes are either replaced by -the replacement character "�" (if @var{mode} is omitted or is the string -"replace") or interpreted as the Unicode code points U+0080–U+00FF with the -same value as the byte (if @var{mode} is the string "unicode"), thus -interpreting the bytes according to ISO-8859-1. +the replacement character @qcode{"�"} (if @var{mode} is omitted or is the +string @qcode{"replace"}) or interpreted as the Unicode code points +U+0080–U+00FF with the same value as the byte (if @var{mode} is the string +@qcode{"unicode"}), thus interpreting the bytes according to ISO-8859-1. @end deftypefn */) { int nargin = args.length ();
--- a/libinterp/corefcn/sysdep.cc Thu Sep 17 10:24:55 2020 -0700 +++ b/libinterp/corefcn/sysdep.cc Thu Sep 17 11:07:19 2020 -0700 @@ -247,10 +247,10 @@ DEFUN (__is_elevated_process__, args, , doc: /* -*- texinfo -*- -@deftypefn {} {@var{retval} =} __is_elevated_process__ () +@deftypefn {} {@var{retval} =} __is_elevated_process__ () Check if current process has elevated rights. -On Windows, return true if the current process has elevated right. Otherwise, +On Windows, return true if the current process has elevated right. Otherwise, return false. On non-Windows platforms, this function fails with an error. @end deftypefn */)
--- a/scripts/general/integral.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/general/integral.m Thu Sep 17 11:07:19 2020 -0700 @@ -33,8 +33,9 @@ ## @code{integral} is a wrapper for @code{quadcc} (general real-valued, scalar ## integrands and limits), @code{quadgk} (integrals with specified integration ## paths), and @code{quadv} (array-valued integrands) that is intended to -## provide @sc{matlab} compatibility. More control of the numerical integration -## may be achievable by calling the various quadrature functions directly. +## provide @sc{matlab} compatibility. More control of the numerical +## integration may be achievable by calling the various quadrature functions +## directly. ## ## @var{f} is a function handle, inline function, or string containing the name ## of the function to evaluate. The function @var{f} must be vectorized and
--- a/scripts/general/pol2cart.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/general/pol2cart.m Thu Sep 17 11:07:19 2020 -0700 @@ -56,9 +56,11 @@ ## @ifnottex ## ## @example +## @group ## @var{x} = @var{r} * cos (@var{theta}) ## @var{y} = @var{r} * sin (@var{theta}) ## @var{z} = @var{z} +## @end group ## @end example ## ## @end ifnottex
--- a/scripts/general/sph2cart.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/general/sph2cart.m Thu Sep 17 11:07:19 2020 -0700 @@ -54,9 +54,11 @@ ## @ifnottex ## ## @example +## @group ## @var{x} = r * cos (@var{phi}) * cos (@var{theta}) ## @var{y} = r * cos (@var{phi}) * sin (@var{theta}) ## @var{z} = r * sin (@var{phi}) +## @end group ## @end example ## ## @end ifnottex
--- a/scripts/miscellaneous/fullfile.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/miscellaneous/fullfile.m Thu Sep 17 11:07:19 2020 -0700 @@ -24,7 +24,7 @@ ######################################################################## ## -*- texinfo -*- -## @deftypefn {} {@var{filename} =} fullfile (@var{dir1}, @var{dir2}, @dots{}, @var{file}) +## @deftypefn {} {@var{filename} =} fullfile (@var{dir1}, @var{dir2}, @dots{}, @var{file}) ## Build complete filename from separate parts. ## ## The function joins any number of path components intelligently. The return
--- a/scripts/miscellaneous/memory.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/miscellaneous/memory.m Thu Sep 17 11:07:19 2020 -0700 @@ -33,35 +33,39 @@ ## ## The output argument @var{userdata} is a structure with the following fields ## containing data for the Octave process: +## ## @table @code ## @item @var{MaxPossibleArrayBytes} ## Maximum size for an array to be allocated. Be aware that this includes ## @emph{all} physical memory and swap space. Allocating that amount of memory ## might result in system instability, data corruption and/or file system -## curruption. Note that dependend on the platform (32bit systems), the largest -## contiguous memory block might further limit the maximum possible allocatable -## array. This check is currently not implemented. +## curruption. Note that dependend on the platform (32bit systems), the +## largest contiguous memory block might further limit the maximum possible +## allocatable array. This check is currently not implemented. ## ## @item @var{MemAvailableAllArrays} ## The total size of available memory in bytes. ## ## @item @var{ram_available_all_arrays} ## The maximum size for an array that can be allocated in physical memory -## (excluding swap space). Note that dependend on the platform (32bit systems), -## the largest contiguous memory block might further limit the maximum possible -## allocatable array. This check is currently not implemented. +## (excluding swap space). Note that dependend on the platform (32bit +## systems), the largest contiguous memory block might further limit the +## maximum possible allocatable array. This check is currently not +## implemented. ## -## @item @var{MemUsedMATLAB} +## @item @var{MemUsedMATLAB} ## @itemx @var{mem_used_octave} ## The memory (including swap space) currently used by Octave in bytes. ## ## @item @var{ram_used_octave} -## The physical memory (excluding swap space) currently used by Octave in bytes. +## The physical memory (excluding swap space) currently used by Octave in +## bytes. ## ## @end table ## -## The output argument @var{systemdata} is a nested structure with the following -## fields containing information about the system's memory: +## The output argument @var{systemdata} is a nested structure with the +## following fields containing information about the system's memory: +## ## @table @code ## @item @var{PhysicalMemory.Available} ## The currently available pyhsical memory in bytes.
--- a/scripts/plot/draw/area.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/plot/draw/area.m Thu Sep 17 11:07:19 2020 -0700 @@ -41,7 +41,7 @@ ## the shading under the curve should be defined. The default level is 0. ## ## Additional property/value pairs are passed directly to the underlying patch -## object. The full list of properties is documented at +## object. The full list of properties is documented at ## @ref{Patch Properties}. ## ## If the first argument @var{hax} is an axes handle, then plot into this axes,
--- a/scripts/plot/draw/colorbar.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/plot/draw/colorbar.m Thu Sep 17 11:07:19 2020 -0700 @@ -82,7 +82,7 @@ ## operate on this colorbar directly. ## ## Additional property/value pairs are passed directly to the underlying axes -## object. The full list of properties is documented at +## object. The full list of properties is documented at ## @ref{Axes Properties}. ## ## The optional return value @var{h} is a graphics handle to the created
--- a/scripts/plot/draw/stairs.m Thu Sep 17 10:24:55 2020 -0700 +++ b/scripts/plot/draw/stairs.m Thu Sep 17 11:07:19 2020 -0700 @@ -42,7 +42,7 @@ ## of the same format as the @code{plot} command. ## ## Multiple property/value pairs may be specified, but they must appear in -## pairs. The full list of properties is documented at +## pairs. The full list of properties is documented at ## @ref{Line Properties}. ## ## If the first argument @var{hax} is an axes handle, then plot into this axes,