Re: number keyword in legend [message #78663 is a reply to message #78662] |
Fri, 16 December 2011 10:14   |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
David Fanning writes:
>
> simona bellavista writes:
>
>> OK, if you try this:
>>
>> IDL> lines = indgen(6)
>> IDL> items = 'linestyle '+strtrim(lines,2)
>> IDL> plot, dindgen(10)
>> IDL> al_legend,items,linestyle=lines, charsize=1
>>
>> You'll see that a plot with a legend will appear, where in the legend
>> there are some lines with different styles. The charsize specifies the
>> font size in the legend.
>> Now if you try
>>
>> IDL> al_legend,items,linestyle=lines, charsize=2
>>
>> another legend will appear on the top, with larger fonts and longer
>> lines.
>>
>> Now, I would like to be able to change the font size, so to make my
>> labels readable, but not having gigantic lines.
>
> Ah, OK, I see what you mean.
>
> But, now we are out of my domain of expertise entirely, and
> we enter Wayne's realm. He will be in touch with us shortly,
> no doubt. :-)
Well, maybe I can answer this question! How about something like
this:
lines = indgen(6)
items = 'linestyle '+strtrim(lines,2)
cgplot, dindgen(10)
al_legend,items,linestyle=lines, charsize=2, pspacing=1.0
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|