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

Home » Public Forums » archive » Discrete Color Bars
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: Discrete Color Bars [message #66187 is a reply to message #65716] Wed, 22 April 2009 19:05 Go to previous message
claydodo is currently offline  claydodo
Messages: 4
Registered: April 2009
Junior Member
On Mar 16, 12:17 pm, David Fanning <n...@dfanning.com> wrote:
> Folks,
>
> Colorbar is a nice program, very useful, etc. But it comes
> up short when you need a color legend with just a handful
> of colors. You have to have fairly specialized knowledge
> to get the underlying Plot command to do what you want it
> to do. And then you almost always have the problem that
> the colorbar annotations do not line up with the actual
> colors.
>
> The problem has come home to roost one time too many
> when I started to need limited color bars on a regular
> basis. Too much fooling around!
>
> So I sat down today and wrote what I wished I had
> written years ago: a discrete color bar program, namedDCBar. Annotations are centered under the colors, and
> the annotations can be rotated if you need more space.
> The color bar can be displayed either horizontally
> or vertically, and you can specify the colors you want
> to use as color names, color indices into the current
> color table, or as 24-bit integers that can be decomposed
> into RGB colors. The program works with the other suite
> of color programs found in the Coyote Library, and will
> need some of them to work properly.
>
> You can learn more about the program and see examples
> in this article:
>
>   http://www.dfanning.com/color_tips/discretecb.html
>
> The program itself is provided without a paid subscription
> on my web page. ;-)
>
>   http://www.dfanning.com/programs/dcbar.pro
>
> Donations, of course, are always appreciated and matched
> by Coyote before being passed on to worthy organizations
> devoted to helping those who need the help.
>
> Cheers,
>
> David
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming:http://www.dfanning.com/
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")

Thanks, David.

I suggest to add an option that can make the labels NOT centered in
the middle of the bins, but aligned to the border of them. This would
be good for showing value ranges.

e.g. to make a bar like this:
[ | | | ]
0 10 20 30 40

Just active this feature when ( nElements(labels) EQ ncolors + 1 )
would be good.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: image correlation
Next Topic: Re: idl-envi resolv_all

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

Current Time: Wed Oct 08 17:51:52 PDT 2025

Total time taken to generate the page: 0.00365 seconds