Mercurial > octave
changeset 28392:d872aed70d27
listfonts.m: Fix problem accidentaly introduced in c126a60b0d52.
* listfonts.m: Fix input validation that was relying on default assignment of
input 'h'.
author | Rik <rik@octave.org> |
---|---|
date | Mon, 01 Jun 2020 13:08:12 -0700 |
parents | c126a60b0d52 |
children | 5147fbf58fa6 |
files | scripts/gui/listfonts.m |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/gui/listfonts.m Mon Jun 01 09:53:08 2020 +0200 +++ b/scripts/gui/listfonts.m Mon Jun 01 13:08:12 2020 -0700 @@ -44,7 +44,7 @@ print_usage (); endif - if (! isempty (h) && (! ishghandle (h) || ! isprop (h, "fontname"))) + if (nargin == 1 && (! ishghandle (h) || ! isprop (h, "fontname"))) error (['listfonts: H must be a handle to a graphics object ', ... 'with a "fontname" property']); endif