本文整理汇总了C++中wxAuiPaneInfo::IsFixed方法的典型用法代码示例。如果您正苦于以下问题:C++ wxAuiPaneInfo::IsFixed方法的具体用法?C++ wxAuiPaneInfo::IsFixed怎么用?C++ wxAuiPaneInfo::IsFixed使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类wxAuiPaneInfo
的用法示例。
在下文中一共展示了wxAuiPaneInfo::IsFixed方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: wxAuiFloatingFrameBaseClass
wxAuiFloatingFrame::wxAuiFloatingFrame(wxWindow* parent,
wxAuiManager* owner_mgr,
const wxAuiPaneInfo& pane,
wxWindowID id /*= wxID_ANY*/,
long style /*=wxRESIZE_BORDER | wxSYSTEM_MENU | wxCAPTION |
wxFRAME_NO_TASKBAR | wxFRAME_FLOAT_ON_PARENT |
wxCLIP_CHILDREN
*/)
: wxAuiFloatingFrameBaseClass(parent, id, wxEmptyString,
pane.floating_pos, pane.floating_size,
style |
(pane.HasCloseButton()?wxCLOSE_BOX:0) |
(pane.HasMaximizeButton()?wxMAXIMIZE_BOX:0) |
(pane.IsFixed()?0:wxRESIZE_BORDER)
)
{
m_owner_mgr = owner_mgr;
m_moving = false;
m_mgr.SetManagedWindow(this);
m_solid_drag = true;
// find out if the system supports solid window drag.
// on non-msw systems, this is assumed to be the case
#ifdef __WXMSW__
BOOL b = TRUE;
SystemParametersInfo(38 /*SPI_GETDRAGFULLWINDOWS*/, 0, &b, 0);
m_solid_drag = b ? true : false;
#endif
SetExtraStyle(wxWS_EX_PROCESS_IDLE);
}
示例2: SetPaneWindow
void wxAuiFloatingFrame::SetPaneWindow(const wxAuiPaneInfo& pane)
{
m_pane_window = pane.window;
m_pane_window->Reparent(this);
wxAuiPaneInfo contained_pane = pane;
contained_pane.Dock().Center().Show().
CaptionVisible(false).
PaneBorder(false).
Layer(0).Row(0).Position(0);
// Carry over the minimum size
wxSize pane_min_size = pane.window->GetMinSize();
// if the frame window's max size is greater than the min size
// then set the max size to the min size as well
wxSize cur_max_size = GetMaxSize();
if (cur_max_size.IsFullySpecified() &&
(cur_max_size.x < pane.min_size.x ||
cur_max_size.y < pane.min_size.y)
)
{
SetMaxSize(pane_min_size);
}
SetMinSize(pane.window->GetMinSize());
m_mgr.AddPane(m_pane_window, contained_pane);
m_mgr.Update();
if (pane.min_size.IsFullySpecified())
{
// because SetSizeHints() calls Fit() too (which sets the window
// size to its minimum allowed), we keep the size before calling
// SetSizeHints() and reset it afterwards...
wxSize tmp = GetSize();
GetSizer()->SetSizeHints(this);
SetSize(tmp);
}
SetTitle(pane.caption);
if (pane.floating_size != wxDefaultSize)
{
SetSize(pane.floating_size);
}
else
{
wxSize size = pane.best_size;
if (size == wxDefaultSize)
size = pane.min_size;
if (size == wxDefaultSize)
size = m_pane_window->GetSize();
if (m_owner_mgr && pane.HasGripper())
{
if (pane.HasGripperTop())
size.y += m_owner_mgr->m_art->GetMetric(wxAUI_DOCKART_GRIPPER_SIZE);
else
size.x += m_owner_mgr->m_art->GetMetric(wxAUI_DOCKART_GRIPPER_SIZE);
}
SetClientSize(size);
}
if (pane.IsFixed())
{
SetWindowStyleFlag(GetWindowStyleFlag() & ~wxRESIZE_BORDER);
}
}
示例3: SetPaneWindow
void wxAuiFloatingFrame::SetPaneWindow(const wxAuiPaneInfo& pane)
{
m_pane_window = pane.window;
m_pane_window->Reparent(this);
wxAuiPaneInfo contained_pane = pane;
contained_pane.Dock().Center().Show().
CaptionVisible(false).
PaneBorder(false).
Layer(0).Row(0).Position(0);
// Carry over the minimum size
wxSize pane_min_size = pane.window->GetMinSize();
// if the frame window's max size is greater than the min size
// then set the max size to the min size as well
wxSize cur_max_size = GetMaxSize();
if (cur_max_size.IsFullySpecified() &&
(cur_max_size.x < pane.min_size.x ||
cur_max_size.y < pane.min_size.y)
)
{
SetMaxSize(pane_min_size);
}
SetMinSize(pane.window->GetMinSize());
m_mgr.AddPane(m_pane_window, contained_pane);
m_mgr.Update();
if (pane.min_size.IsFullySpecified())
{
// because SetSizeHints() calls Fit() too (which sets the window
// size to its minimum allowed), we keep the size before calling
// SetSizeHints() and reset it afterwards...
wxSize tmp = GetSize();
GetSizer()->SetSizeHints(this);
SetSize(tmp);
}
SetTitle(pane.caption);
// This code is slightly awkward because we need to reset wxRESIZE_BORDER
// before calling SetClientSize() below as doing it after setting the
// client size would actually change it, at least under MSW, where the
// total window size doesn't change and hence, as the borders size changes,
// the client size does change.
//
// So we must call it first but doing it generates a size event and updates
// pane.floating_size from inside it so we must also record its original
// value before doing it.
const bool hasFloatingSize = pane.floating_size != wxDefaultSize;
if (pane.IsFixed())
{
SetWindowStyleFlag(GetWindowStyleFlag() & ~wxRESIZE_BORDER);
}
if ( hasFloatingSize )
{
SetSize(pane.floating_size);
}
else
{
wxSize size = pane.best_size;
if (size == wxDefaultSize)
size = pane.min_size;
if (size == wxDefaultSize)
size = m_pane_window->GetSize();
if (m_owner_mgr && pane.HasGripper())
{
if (pane.HasGripperTop())
size.y += m_owner_mgr->m_art->GetMetric(wxAUI_DOCKART_GRIPPER_SIZE);
else
size.x += m_owner_mgr->m_art->GetMetric(wxAUI_DOCKART_GRIPPER_SIZE);
}
SetClientSize(size);
}
}