comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Problem changing color table
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Problem changing color table [message #87967 is a reply to message #87966] Thu, 06 March 2014 16:25 Go to previous messageGo to previous message
kelle is currently offline  kelle
Messages: 4
Registered: March 2014
Junior Member
On Thursday, March 6, 2014 7:15:27 PM UTC-5, kelle wrote:
> On Thursday, March 6, 2014 6:58:21 PM UTC-5, kelle wrote:
>
>> Hey David,
>
>>
>
>>
>
>>
>
>> Thanks for the quick reply.
>
>>
>
>>
>
>>
>
>> Yes, I'm aware of that command and have had it in my code and functioning for many years. It has recently *stopped* working.
>
>>
>
>>
>
>>
>
>> IF ~KEYWORD_SET(ps) THEN BEGIN
>
>>
>
>> ;set up for display to screen
>
>>
>
>> set_plot,'x'
>
>>
>
>> device, Decomposed=0 ;make colors work for 24-bit display
>
>>
>
>> print,'debug red plots'
>
>>
>
>> ENDIF
>
>>
>
>>
>
>>
>
>> If no one else has encountered this problem with the new XQuartz or Mac OS, I will try to debug some more on my own.
>
>>
>
>>
>
>>
>
>> thanks!
>
>>
>
>> kelle
>
>>
>
>>
>
>>
>
>> On Thursday, March 6, 2014 6:44:43 PM UTC-5, David Fanning wrote:
>
>>
>
>>> kelle writes:
>
>>
>
>>>
>
>>
>
>>>
>
>>
>
>>>
>
>>
>
>>>> 'm running code that used to properly deal with this issue but "all of a sudden", all of my plots are red again...for the first time in *years*.
>
>>
>
>>>
>
>>
>
>>>>
>
>>
>
>>>
>
>>
>
>>>> I'm running IDL 7.0.6 (and not interested in upgrading) on Mac OS 10.8.5 and XQuartz 2.7.5.
>
>>
>
>>>
>
>>
>
>>>>
>
>>
>
>>>
>
>>
>
>>>> Unfortunately, I haven't been using IDL regularly and lots of changes have probably been applied to my system since I last had regular display functionality. I suspect it's the new XQuartz?
>
>>
>
>>>
>
>>
>
>>>>
>
>>
>
>>>
>
>>
>
>>>> thanks for any thoughts.
>
>>
>
>>>
>
>>
>
>>>
>
>>
>
>>>
>
>>
>
>>> Device, Decomposed=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 thue. ("Perhaps thou speakest truth.")
>
>
>
> ok, I think I figured it out. I just needed to explicitly define the color of the plot (color_line). I've never needed to do this before, but it worked!
>
>
>
> The annotations are all still red...guess I need to also explicitly give those colors in the xyouts commands.
>
>
>
> What's the "default" color? Does it use whatever is assigned to 255? Cause if so, that would explain it. (And maybe I changed my custom color table? this is starting to ring some bells...)
>
>
>
> kelle
>
>
>
> @colors_kc ; loads custom color table gives colors names
>
> color_line = black
>
> IF ~KEYWORD_SET(ps) THEN BEGIN
>
> ;set up for display to screen
>
> set_plot,'x'
>
> device, Decomposed=0 ;make colors work for 24-bit display
>
> print,'ye'
>
> color_line=white
>
> ENDIF
>
> plot, w, spec, [...], color=color_line

yep, just needed to have white as the last color. It was just a coincidence that I had modified the color table to have red as color 255...thus mimicking the Device, Decomposed = 0 problem. sneaky, sneaky.

I wonder, does that also mean that for good color table modification practice, one should also always keep black as color 0?

thanks!
kelle
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Run Fortran executable in IDL
Next Topic: log axis with negative numbers

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 17:32:03 PDT 2025

Total time taken to generate the page: 0.00441 seconds