From a7bab83cc82b77a6ebfecd443cb99e42ded5793c Mon Sep 17 00:00:00 2001 From: mfranz Date: Thu, 23 Mar 2006 17:44:10 +0000 Subject: [PATCH] make puListBox inherit puList colors (otherwise the GUI style isn't respected, and black text on dark grey is a bit hard to read). TODO: - submit that for inclusion in plib's puAuxList - drop custom version and use plib's (after 0.9.10) --- src/GUI/puList.cxx | 14 ++++++++++++++ src/GUI/puList.hxx | 3 +++ 2 files changed, 17 insertions(+) diff --git a/src/GUI/puList.cxx b/src/GUI/puList.cxx index b99ccd405..4654084ad 100644 --- a/src/GUI/puList.cxx +++ b/src/GUI/puList.cxx @@ -116,4 +116,18 @@ puList::init (int w, int h) close(); } +void +puList::setColourScheme (float r, float g, float b, float a) +{ + puObject::setColourScheme(r, g, b, a); + _list_box->setColourScheme(r, g, b, a); +} + +void +puList::setColour (int which, float r, float g, float b, float a) +{ + puObject::setColour(which, r, g, b, a); + _list_box->setColour(which, r, g, b, a); +} + // end of puList.cxx diff --git a/src/GUI/puList.hxx b/src/GUI/puList.hxx index 2b4946a00..414a097a5 100644 --- a/src/GUI/puList.hxx +++ b/src/GUI/puList.hxx @@ -27,6 +27,9 @@ class puList : public puGroup // TODO: other string value funcs virtual char * getListStringValue (); virtual int getListIntegerValue(); + virtual void setColourScheme (float r, float g, float b, float a); + virtual void setColour (int which, float r, float g, float b, float a); + protected: virtual void init (int w, int h); -- 2.39.5