Mercurial > octave
changeset 27535:303df1e804d4
struct2hdl.m: Allow light objects to be constructed (bug #57093)
author | Guillaume Flandin |
---|---|
date | Mon, 21 Oct 2019 16:23:52 +0100 |
parents | f70d7a9ee3fd |
children | d389416f0e50 |
files | scripts/plot/util/struct2hdl.m |
diffstat | 1 files changed, 7 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/plot/util/struct2hdl.m Fri Oct 18 16:45:56 2019 -0400 +++ b/scripts/plot/util/struct2hdl.m Mon Oct 21 16:23:52 2019 +0100 @@ -163,6 +163,8 @@ h = createimage (s, par); elseif (strcmp (s.type, "surface")) h = createsurface (s, par); + elseif (strcmp (s.type, "light")) + h = createlight (s, par); elseif (strcmp (s.type, "hggroup")) [h, s, p] = createhg (s, p, par, hilev); elseif (any (strcmp (s.type, {"uimenu", "uicontextmenu",... @@ -370,6 +372,11 @@ addmissingprops (h, s.properties); endfunction +function h = createlight (s, par) + h = light ("parent", par); + addmissingprops (h, s.properties); +endfunction + function [h, s] = createui (s, par) if (isfield (s.properties, "style") && strcmp (s.properties.style, "frame")) s.type = "uipanel"; # frame is deprecated: use uipanel instead