Page 1 of 1

LegendParams Command

Posted: Tue Nov 21, 2017 11:19 am
by dkabq
I am having an issue with getting the LegendParams command to modify a plot. As a test, I have copied/pasted the example for making the legend background opaque, filled with a light cyan.

DPlot_Command(DocNum, "[LegendParams(,,,1,,,,,0x00FFFFC0)]")

I have DocNum=1, which works for the subsequent DPlot_command

DPlot_Command(DocNum, "[SetBackgroundImage(""d:\dplot_files\image.png"", 1, 1, 0, 0, 0, 0, 1, 150, -1)]")

Thanks for the help.

Posted: Tue Nov 21, 2017 3:14 pm
by DPlotAdmin
I don't know. That worked fine for me just now when I used it in a macro.

Posted: Tue Nov 21, 2017 4:08 pm
by dkabq
Were you using it in a macro that modifies an XYZ contour plot?

Might the inability of my macro to execute the command be related to the Legends/Labels command being absent from my Text menu command list? It is there when I start DPlot, but vanishes after I create a new 3D surface plot (either manually or via a macro).

Posted: Tue Nov 21, 2017 4:48 pm
by DPlotAdmin
Were you using it in a macro that modifies an XYZ contour plot?
No, and that's the problem. The legend in 3D plots is quite a bit different than 2D. You can't draw a frame or fill the background or move it to arbitrary locations, for example.

Posted: Tue Nov 21, 2017 5:58 pm
by dkabq
Well that is a bummer, as my legend is overlapping with the plot titles.

You might want to put a note in the User Manual LegendParams macro command stating that which plots the command is and is not valid for.

Posted: Tue Nov 21, 2017 11:08 pm
by DPlotAdmin
Well that is a bummer, as my legend is overlapping with the plot titles.
That should not ever happen. Please save your graph as a DPlot file and send it to me at support@dplot.com at your convenience.