RE: [gtkmm] How to determine the background color of the Gtk::Ent ry
- From: Eli Hadad <eli_hadad sheernetworks com>
- To: "'xigorj sezam net'" <xigorj sezam net>, Eli Hadad <eli_hadad sheernetworks com>
- Cc: "'gtkmm-list gnome org'" <gtkmm-list gnome org>
- Subject: RE: [gtkmm] How to determine the background color of the Gtk::Ent ry
- Date: Fri, 19 Mar 2004 17:17:53 +0200
Thanks,
It works.
I still have problem getting the color of the window, for some reason I get
different gray inside the Entry,
when gettingand using the background color of the main window.
MyEntry->modify_base(Gtk::STATE_NORMAL,
MyWin->get_style()->get_background());
Is this themes issue ?
Eli
-----Original Message-----
From: Igor Jovanovic [mailto:xigorj sezam net]
Sent: Thursday, March 18, 2004 9:43 PM
To: Eli Hadad
Cc: 'gtkmm-list gnome org'
Subject: Re: [gtkmm] How to determine the background color of the Gtk::Entry
On Thu, 2004-03-18 at 08:59, Eli Hadad wrote:
> Hi all,
>
> I am trying to set the backgroung color of an Entry, i.e. the editable
area.
> I first try setting the Style of the entry itself, than read that it can't
> be done to windowless widgets.
> So I added the Entry to EventBox and changed the EventBox's Style and this
> again didn't work.
>
> In TextView it is possible working on it's TextBuffer.
> What is the way to do it for Entry ?
>
> BTW: I am tring to create an Entry with a background color of it's window,
> so it will looks like
> a Label, is there a better/simple way to it.
This works fine.
Gdk::Color colRed;
colRed.set_rgb_p (1, 0, 0);
YourEntry->modify_base(Gtk::STATE_NORMAL, colRed);
You wont need an event box for this :-))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]