Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

CDE Style Manager & tcl/tk colors

34 views
Skip to first unread message

Dave Simonds

unread,
Jun 14, 1996, 3:00:00 AM6/14/96
to

I would like my tcl/tk application to pick up the palette set by the
enduser in the CDE Style Manager - Color. Can someone tell me how to do
this?

I have found that setting an option such as -background white for
listbox or text in my tcl/tk code has a very unfortunate result if the
user selects a palette with reverse text (white on dark color) in the
CDE Style Manager -- the text becomes invisible. Setting no colors at
all in the tcl app results in black text displayed on a fairly dark grey
background when the CDE default Style Manager palette is selected, a
color scheme which I expect most would find unpleasant. This behavior
puzzles me, since other windows in the CDE environment display black
text on an off-white or yellowish background when the CDE Style Manager
Default palette is in use.

If I can avoid it, I do not want to have to create the equivalent of a
second "Style Manager" for color within the tcl application itself.

Dave Simonds
d...@voa.gov

Larry W. Virden

unread,
Jun 18, 1996, 3:00:00 AM6/18/96
to

I didn't know that Tcl/Tk would cooperate wtih CDE at all. I wasn't able
to locate any mention of CDE in any of the FAQs. If there are changes
to Tcl/Tk that anyone has found necessary to get CDE and Tcl/Tk to cooperate,
please be sure to send me a note for the FAQs.
--
:s Larry W. Virden INET: lvi...@cas.org
:s <URL:http://www.teraform.com/%7Elvirden/> <*> O- "We are all Kosh."
:s Unless explicitly stated to the contrary, nothing in this posting should
:s be construed as representing my employer's opinions.

Jeffrey Hobbs

unread,
Jun 18, 1996, 3:00:00 AM6/18/96
to

In article <4q5rk8$2...@srv13s4.cas.org>,

Larry W. Virden <lvi...@cas.org> wrote:
>I didn't know that Tcl/Tk would cooperate wtih CDE at all. I wasn't able

I do much of my development on Solaris/CDE. The only problem with CDE is
some HCI idiot decided that it should set *Foreground and *Background in
the Xdefaults. If you remove them it will try it's best to replace them.
While annoying, it's not a real problem to work with.
--
Jeffrey Hobbs Office: 541/346-3998
Univ of Oregon CIS GRF email: jho...@cs.uoregon.edu
URL: http://www.cs.uoregon.edu/~jhobbs/

John Haxby

unread,
Jun 19, 1996, 3:00:00 AM6/19/96
to

Jeffrey Hobbs wrote:
>
> In article <4q5rk8$2...@srv13s4.cas.org>,
> Larry W. Virden <lvi...@cas.org> wrote:
> >I didn't know that Tcl/Tk would cooperate wtih CDE at all. I wasn't able
>
> I do much of my development on Solaris/CDE. The only problem with CDE is
> some HCI idiot decided that it should set *Foreground and *Background in
> the Xdefaults. If you remove them it will try it's best to replace them.
> While annoying, it's not a real problem to work with.

Something like

tk_setPalette \
foreground [option get . foreground Foreground] \
background [option get . background Background]

generally does the trick, provided you put it early enough in the
code.

--
John Haxby
These are my opinions, not my employer's.

0 new messages