A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/doxyhtml/dock__notebook_8cpp_source.html below:

NCBI C++ ToolKit: src/gui/widgets/wx/dock_notebook.cpp Source File

43 #include <wx/settings.h> 45 #include <wx/button.h> 46 #include <wx/aui/aui.h> 49 # include <Carbon/Carbon.h> 69

wxAUI_NB_TAB_EXTERNAL_MOVE |

70

wxAUI_NB_SCROLL_BUTTONS |

71

wxAUI_NB_WINDOWLIST_BUTTON |

72

wxAUI_NB_CLOSE_ON_ACTIVE_TAB |

82

, m_DockContainer( &container )

83

, m_OutsideDrag(

false

)

86

SetLabel(

wxT

(

"dock_notebook"

) );

89

wxAuiDockArt* dock_art = m_mgr.GetArtProvider();

90

dock_art->SetMetric( wxAUI_DOCKART_PANE_BORDER_SIZE, 0 );

117  size_t

index = GetPageIndex(child);

118  int

selpage = GetSelection();

125  if

(selpage != wxNOT_FOUND &&

126

selpage >= (

int

)GetPageCount() &&

128

SetSelection(selpage-1);

136  size_t

index = GetPageIndex(old_child);

141  int

other_index = (index == 0) ? 1 : 0;

142

SetSelection(other_index);

145

InsertPage(index, new_child,

ToWxString

(

label

),

false

, wxNullBitmap);

146

new_child->Reparent(

this

);

152  int

page_ix = GetPageIndex( page );

153  if

( page_ix == wxNOT_FOUND ){

158

wxString old_label = GetPageText( page_ix );

159  if

(

label

== old_label ){

163

SetPageText( page_ix,

label

);

175  switch

(viewOption) {

202

SetSelection(other_index);

204

InsertPage(

m_HitTabIndex

, page, caption,

false

, wxNullBitmap);

206

AddPage(page, caption);

213  if

(GetPageCount() == 0) {

219

wxPoint client_pt = ScreenToClient(screen_pt);

220

wxAuiTabCtrl* tabs = GetTabCtrlFromPoint(client_pt);

221

wxWindow* over_tab =

NULL

;

223  if

(tabs && tabs->TabHitTest(client_pt.x, client_pt.y, &over_tab)) {

232

wxRect rc = GetClientRect();

234  if

(rc.Contains(client_pt)) {

249  int

index =

event

.GetSelection();

250

wxWindow* page = GetPage(index);

265  int

sel = GetSelection();

267

wxWindow* page = GetPage(sel);

269

vector<IWMClient*> clients;

272  if

(clients.size()) {

281  if

(event.GetSelection() == event.GetOldSelection())

289  int

sel =

event

.GetOldSelection();

291

wxWindow* page = GetPage(sel);

299

sel =

event

.GetSelection();

301

wxWindow* page = GetPage(sel);

303 #ifdef __WXOSX_COCOA__ 304

vector<IWMClient*> clients;

307  if

(clients.size()) {

310

cl_w->SendSizeEvent();

330 #if (wxMAJOR_VERSION == 2 && wxMINOR_VERSION < 9) 352

wxPoint screen_pt = ::wxGetMousePosition();

353

wxPoint client_pt = ScreenToClient(screen_pt);

356

wxAuiTabCtrl* src_tabs = (wxAuiTabCtrl*)evt.GetEventObject();

357

wxAuiTabCtrl* dest_tabs = GetTabCtrlFromPoint(client_pt);

359  if

(dest_tabs == src_tabs)

362

src_tabs->SetCursor(wxCursor(wxCURSOR_ARROW));

368

wxPoint pt = dest_tabs->ScreenToClient(screen_pt);

369

wxWindow* dest_location_tab;

372  if

(dest_tabs->TabHitTest(pt.x, pt.y, &dest_location_tab)) {

373  int

src_idx = evt.GetSelection();

374  int

dest_idx = dest_tabs->GetIdxFromWindow(dest_location_tab);

377  if

((src_idx == dest_idx) || dest_idx == -1 ||

378

#

if

(wxMAJOR_VERSION == 2 && wxMINOR_VERSION < 9)

379

(src_idx > dest_idx && m_last_drag_x <= pt.x) ||

380

(src_idx < dest_idx && m_last_drag_x >= pt.x)) {

381

m_last_drag_x = pt.x;

383

(src_idx > dest_idx && m_lastDragX <= pt.x) ||

384

(src_idx < dest_idx && m_lastDragX >= pt.x)) {

390

wxWindow* src_tab = dest_tabs->GetWindowFromIdx(src_idx);

392

dest_tabs->MovePage(src_tab, dest_idx);

393

dest_tabs->SetActivePage((

size_t

)dest_idx);

394

dest_tabs->DoShowHide();

395

dest_tabs->Refresh();

396 #if (wxMAJOR_VERSION == 2 && wxMINOR_VERSION < 9) 397

m_last_drag_x = pt.x;

415  int

index = evt.GetSelection();

421

wxAuiTabCtrl* ctrl =

dynamic_cast<

wxAuiTabCtrl*

>

(evt.GetEventObject());

422  if

(GetCapture() == ctrl) {

423

ctrl->ReleaseMouse();

439  int

sel_ix = GetSelection();

440  if

( sel_ix < 0 ){

return

; }

442

wxWindow* sel_page = GetPage( sel_ix );

443  if

( sel_page ==

NULL

){

return

; }

445

wxAuiTabCtrl* tab_ctrl;

448  if

( FindTab( sel_page, &tab_ctrl, &tab_ix ) ){

450 #if defined(__WXMSW__) 451

tab_ctrl->HandlePaint();

454

tab_ctrl->MakeTabVisible( tab_ix, tab_ctrl );

476 #if (wxMAJOR_VERSION == 2 && wxMINOR_VERSION < 9) 477

dc.SetBrush(m_bkbrush);

479

dc.SetBrush(m_bkBrush);

481

dc.SetPen(*wxTRANSPARENT_PEN);

482

dc.DrawRectangle(-1, -1, rect.GetWidth()+2, rect.GetHeight()+2);

485

dc.SetPen(*wxGREY_PEN);

486

dc.DrawLine(0, rect.GetHeight()-1, rect.GetWidth(), rect.GetHeight()-1);

517

wxColour cl_back = wxSystemSettings::GetColour(wxSYS_COLOUR_BTNFACE);

518

wxBrush brush(cl_back);

520

dc.SetPen(*wxTRANSPARENT_PEN);

522

dc.DrawRectangle(x, y, w, h);

524 #ifdef __WXMAC__THIS_CODE_NEEDS_TO_BE_CHANGED_EVERYTIME_OSX_UPGRADED 527

HIRect rect = CGRectMake(x, y, w, h);

529

HIThemeSplitterDrawInfo

info

;

530  info

.state = kThemeStateActive;

531  info

.adornment = kThemeAdornmentNone;

533

WindowRef wr = WindowRef(this->MacGetTopLevelWindowRef());

535

QDBeginCGContext (GetWindowPort(wr), &

context

);

536

HIThemeDrawPaneSplitter(&rect, &

info

,

context

, kHIThemeOrientationInverted);

537

QDEndCGContext(GetWindowPort(wr), &

context

);

549  int

col = -1,

row

= -1;

CDockContainer is a window that hosts docked windows.

void OnTabClosePressed(wxWindow *page)

void OnUpdateTabOrder(CDockNotebook &notebook)

void GetClientsInWindow(wxWindow *window, vector< IWMClient * > &clients)

CDockNotebookTabArt - a customized version of wxAuiSimpleTabArt that renders background differently.

virtual wxAuiTabArt * Clone()

virtual void DrawBackground(wxDC &dc, wxWindow *wnd, const wxRect &rect)

CDockNotebookTabArt()

CDockNotebookTabArt.

CDockNotebook - an extended version of wxAuiNotebook capable of working with Dock Manager and Window ...

void OnTabEndDrag(wxAuiNotebookEvent &event)

virtual void Cont_Remove(wxWindow *child)

void OnTabBeginDrag(wxAuiNotebookEvent &event)

CDockNotebook(CDockContainer &container)

void RefreshPageByWindow(wxWindow *page)

CDockContainer * m_DockContainer

void InsertPageAtHitPoint(wxWindow *page, const wxString &caption)

string x_GetPageNameByWindow(wxWindow *window)

virtual void Cont_Replace(wxWindow *old_child, wxWindow *new_child)

virtual void SetDockContainer(CDockContainer *cont)

virtual EDockEffect DropTest(const wxPoint &screen_pt, wxWindow *&target)

void OnTabDragMotion(wxAuiNotebookEvent &event)

void OnPageClose(wxAuiNotebookEvent &event)

void OnPageChanging(wxAuiNotebookEvent &event)

void MakeSelectionVisible()

virtual CDockContainer * GetDockContainer()

void OnPageChanged(wxAuiNotebookEvent &event)

CDockPanel - a container with a title bar (caption) hosting a single client window (IWMClient).

CDockSplitter = an extended version of CSplitter capable of working with Dock Manager and Window Mana...

CDockContainer * m_DockContainer

virtual void Cont_Remove(wxWindow *child)

virtual void SetDockContainer(CDockContainer *cont)

virtual void x_DrawSeparator(wxDC &dc, int x, int y, int w, int h)

virtual CDockContainer * GetDockContainer()

virtual void Cont_Replace(wxWindow *old_child, wxWindow *new_child)

CDockSplitter(CDockContainer &container, CSplitter::ESplitType type)

CDockSplitter.

static CGuiRegistry & GetInstance()

access the application-wide singleton

int GetInt(const string &key, int default_val=0) const

retrieve values by section and key.

CSplitter - container with resizable separators.

bool FindChild(const wxWindow *child, int &col, int &row) const

bool InsertToCell(wxWindow *child, int col, int row)

If cell [col, row] exists and vacant - adds widget to the container.

ESplitType

ESplitMode - splitter orientation.

IDockableWindow - repersents a window that can be docked in Dock Manager.

IWClient - abstract Window Manager client.

virtual wxWindow * GetWindow()=0

returns a pointer to the wxWindow representing the client

ELabel

Different flavors of label types for different GUI aspects.

@ eDetailed

Detailed name.

@ eContent

Short name with content.

@ eTypeAndContent

Short name with content and type.

virtual string GetClientLabel(IWMClient::ELabel ltype=IWMClient::eDefault) const =0

returns the client label (name) to be displayed in UI

const int kNotebookStyle

CDockNotebook.

@ eCmdParentHide

tool tip parent window shown

@ eCmdParentShow

tool tip parent window activated

#define END_NCBI_SCOPE

End previously defined NCBI scope.

#define BEGIN_NCBI_SCOPE

Define ncbi namespace.

static const char label[]

static SLJIT_INLINE sljit_ins l(sljit_gpr r, sljit_s32 d, sljit_gpr x, sljit_gpr b)

#define row(bind, expected)

static CS_CONTEXT * context

wxString ToWxString(const string &s)

void BroadcastCommandToChildWindows(wxWindow *window, int cmd_id, int cmd_data=0)

Sends command event with id 'cmd_id' to window and all its children.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4