Hi,
I have 2 questions:
1. Is there a way to remove the 'x' button from a docking window?
My goal here is to use as content window one of the docking windows since I want the blue caption (on windows anyways) to appear for the content window as well
2. Is there a way to change the background color of the caption?
Eran
wxIFM - Remove the 'X' button? Topic is solved
-
- Filthy Rich wx Solver
- Posts: 235
- Joined: Sun Oct 10, 2004 2:53 am
I will say this: Do not make the content window dockable. wxIFM is not designed to function without a content window, and the fact that it does so is just because it took 5 minutes to enable the functionality. Please simply specify your content window as the content window without making it dockable.
You can remove the "X" from a window by setting data.m_hideable = false; in the DefaultChildData when adding a child to wxIFM. This prevents that window from being hidden by the user. Warning:This value may not be respected through the entire library. Not respecting this value is considered to be a bug. Please report instances where this value is not respected. It would of course be preferable if you fixed instances where it is not respected and reported the bug with a patch included. =)
p.s. This value was documented here: http://www.snakesoft.net/wxifm/docs/htm ... _base.html I admit it is not in an obvious spot and I will correct this and update the documentation.
Edit: I updated the online documentation and the member is now documented at http://www.snakesoft.net/wxifm/docs/htm ... _data.html as well.
You can remove the "X" from a window by setting data.m_hideable = false; in the DefaultChildData when adding a child to wxIFM. This prevents that window from being hidden by the user. Warning:This value may not be respected through the entire library. Not respecting this value is considered to be a bug. Please report instances where this value is not respected. It would of course be preferable if you fixed instances where it is not respected and reported the bug with a patch included. =)
p.s. This value was documented here: http://www.snakesoft.net/wxifm/docs/htm ... _base.html I admit it is not in an obvious spot and I will correct this and update the documentation.
Edit: I updated the online documentation and the member is now documented at http://www.snakesoft.net/wxifm/docs/htm ... _data.html as well.
Code: Select all
m_canvas = new O3SGLCanvas(this, wxID_ANY,
wxDefaultPosition, wxDefaultSize);
data->m_name = _("Renderer");
data->m_orientation = IFM_ORIENTATION_RIGHT;
data->m_child = m_canvas;
data->m_hideable = O3D_FALSE;
data->m_tabify = O3D_FALSE;
wxIFM 1.0.5 has been released. I will make the update and try this feature.
-
- Filthy Rich wx Solver
- Posts: 235
- Joined: Sun Oct 10, 2004 2:53 am
-
- Filthy Rich wx Solver
- Posts: 235
- Joined: Sun Oct 10, 2004 2:53 am
Re: wxIFM - Remove the 'X' button?
To remove the "X" button, set wxIFMDefaultChildData::m_hideable to false when you add the child to wxIFM. However, in wxIFM 1.0.5 the functionality does not work. There is a patch available to get this functionality working again in this thread: http://forums.wxwidgets.org/viewtopic.php?t=5359eranif wrote:1. Is there a way to remove the 'x' button from a docking window?
Yes there is. As of wxIFM 1.0.5, certain "look and feel" settings can be configured. To change the background color, you would do this:2. Is there a way to change the background color of the caption?
Code: Select all
wxIFMCaptionConfig &config = wxIFMDefaultPanelPlugin::GetCaptionConfig();
config.set_caption_color(wxColour(50,50,50));
Documentation for configuration stuff:
http://www.snakesoft.net/wxifm/docs/htm ... 5fbaf42fc0
http://www.snakesoft.net/wxifm/docs/htm ... lugin.html
http://www.snakesoft.net/wxifm/docs/htm ... onfig.html
http://www.snakesoft.net/wxifm/docs/htm ... onfig.html