strange behaviour of color property in function graphics [message #89586] |
Thu, 30 October 2014 04:35  |
Helder Marchetto
Messages: 520 Registered: November 2011
|
Senior Member |
|
|
Hi,
I've just came across this:
This is ok:
IDL> i = image(/test)
IDL> t = text(0.5,0.5,'test', 'r', /norm)
This gives an error:
IDL> i = image(/test)
IDL> t = text(0.5,0.5,'test', /norm, color='r')
% TEXT: <LONG Array[1]>.
% Execution halted at: $MAIN$
I think that this is a bug, because:
1) it works for the plot function:
p = plot(/test, color='r')
2) the description of the color property in plot() and text() is the same (set the property to a string or RGB vector: http://www.exelisvis.com/docs/FormattingSymsAndLines.html)
Running the debug option in text, I get the following error:
% ITEXT: <LONG Array[1]>.
% Execution halted at: TEXT 119 C:\Program Files\Exelis\IDL84\lib\graphics\text.pro
Something strange is going on with the color variable being, as the error says, a an array and not a scalar.
cheers,
Helder
|
|
|
|
Re: strange behaviour of color property in function graphics [message #89588 is a reply to message #89587] |
Thu, 30 October 2014 05:20   |
Helder Marchetto
Messages: 520 Registered: November 2011
|
Senior Member |
|
|
On Thursday, October 30, 2014 1:08:26 PM UTC+1, Fabien wrote:
> Hi again Helder,
>
> On 30.10.2014 12:35, Helder wrote:
>> This gives an error:
>> IDL> i = image(/test)
>> IDL> t = text(0.5,0.5,'test', /norm, color='r')
>> % TEXT: <LONG Array[1]>.
>> % Execution halted at: $MAIN$
>
> No error in IDL 8.3!
>
> There seems to be a bunch of changes in IDL8.4 ...
>
> Fabien
Yeah,
and we're chasing them down...
h
|
|
|
|