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/custom__tree_8cpp_source.html below:

NCBI C++ ToolKit: src/gui/packages/pkg_sequence_edit/custom_tree.cpp Source File

31 #include <wx/dcclient.h> 32 #include <wx/settings.h> 33 #include <wx/renderer.h> 34 #include <wx/msgdlg.h> 41  for

(

size_t i

= 0;

i

<

m_List

.size();

i

++) {

61  for

(

size_t i

= 0;

i

< m_List.size();

i

++) {

74  for

(

size_t i

= 0;

i

<

m_List

.size();

i

++) {

82  m_All

.push_back(item);

83  for

(

size_t i

= 0;

i

< item->

m_List

.size();

i

++) {

92  for

(

size_t i

= 0;

i

<

m_List

.size();

i

++) {

102  for

(

size_t i

= 0;

i

< item->

m_List

.size();

i

++) {

111

wxRendererNative&

rnd

= wxRendererNative::GetDefault();

112

wxSize cbSize =

rnd

.GetCheckBoxSize(

this

);

115  m_SB_width

= wxSystemSettings::GetMetric(wxSYS_VSCROLL_X);

116

wxPaintDC dc(

this

);

119  m_MIN_height

= wxSystemSettings::GetMetric(wxSYS_SMALLICON_Y);

135  for

(

size_t i

= 0;

i

< v.size();

i

++) {

136  string

p = q.empty() ? v[

i

] : q +

" "

+ v[

i

];

137  if

(!q.empty() && dc.GetTextExtent(p).GetWidth() > width) {

156

vector<string> v =

Split

(item.

GetText

(), dc, width - x);

164

wxClientDC dc(

this

);

165  const int

height = GetClientSize().GetY();

166  int

width = GetClientSize().GetX();

189

wxPaintDC dc(

this

);

201

wxRendererNative&

rnd

= wxRendererNative::GetDefault();

205  const int

width = GetClientSize().GetX();

206  const int

height = GetClientSize().GetY();

207  for

(

size_t i

= 0;

i

<

m_Visible

.size() && yy < height; yy += h,

i

++) {

212

vector<string> v =

Split

(item.

GetText

(), dc, width - x);

219

dc.SetTextForeground(wxSystemSettings::GetColour(wxSYS_COLOUR_HIGHLIGHTTEXT));

220

wxBrush brush(wxSystemSettings::GetColour(wxSYS_COLOUR_HIGHLIGHT));

222

dc.DrawRectangle(0, yy, width, h);

225

dc.SetTextForeground(wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOWTEXT));

229  if

(item.

m_List

.size()) {

244  for

(

auto

& s : v) {

245

dc.DrawText(s, x, y);

254

wxPen pen(highlited ? wxSystemSettings::GetColour(wxSYS_COLOUR_HIGHLIGHTTEXT) : wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOWTEXT));

257  int

x0 = rect.GetLeft() + 1;

258  int

x1 = rect.GetRight() - 1;

259  int

xm = (x0 + x1) / 2;

260  int

y0 = rect.GetTop() + (rect.GetHeight() + 2) / 4;

261  int

y1 = y0 + rect.GetHeight() / 2;

262

dc.DrawLine(x0, y0, x1, y0);

263

dc.DrawLine(x1, y0, xm, y1);

264

dc.DrawLine(xm, y1, x0, y0);

267  int

x0 = rect.GetLeft() + (rect.GetWidth() + 2) / 4;

268  int

x1 = x0 + rect.GetWidth() / 2;

269  int

y0 = rect.GetTop() + 1;

270  int

y1 = rect.GetBottom() - 1;

271  int

ym = (y0 + y1) / 2;

272

dc.DrawLine(x0, y0, x1, ym);

273

dc.DrawLine(x1, ym, x0, y1);

274

dc.DrawLine(x0, y1, x0, y0);

291

wxClientDC dc(

this

);

296  const int

width = GetClientSize().GetX();

297  const int

height = GetClientSize().GetY();

300  for

(

size_t i

= 0;

i

<

m_Visible

.size() && yy < height; yy += h,

i

++) {

303  if

(y < yy || y >= yy + h) {

308  if

(x >= cx && x < cx + m_CB_width && y >= cy && y < cy +

m_CB_height

) {

321

wxCommandEvent e(wxEVT_LISTBOX,

GetId

());

322

e.SetEventObject(GetParent());

330

wxCommandEvent e(wxEVT_LISTBOX_DCLICK,

GetId

());

331

e.SetEventObject(GetParent());

358  for

(

auto

& it : item->

m_List

) {

374  for

(

auto

& it : item->

m_List

) {

375  if

(!it->m_Checked) {

386  const int

height = GetClientSize().GetY();

388  if

(fullheight <= height) {

392

SetScrollbar(wxVERTICAL, 0, 0, 0);

396  if

(

m_Start

+ height > fullheight) {

403

SetScrollbar(wxVERTICAL,

m_Start

, height, fullheight);

410  const

wxEventType&

type

= evt.GetEventType();

411  const int

height = GetClientSize().GetY();

412  if

(

type

== wxEVT_SCROLLWIN_TOP) {

416  else if

(

type

== wxEVT_SCROLLWIN_BOTTOM) {

420  else if

(

type

== wxEVT_SCROLLWIN_LINEUP) {

424  else if

(

type

== wxEVT_SCROLLWIN_LINEDOWN) {

428  else if

(

type

== wxEVT_SCROLLWIN_PAGEUP) {

432  else if

(

type

== wxEVT_SCROLLWIN_PAGEDOWN) {

436  else if

(

type

== wxEVT_SCROLLWIN_THUMBTRACK ||

type

== wxEVT_SCROLLWIN_THUMBRELEASE) {

437  if

(evt.GetPosition() >= 0) {

447  int delta

= evt.GetWheelDelta();

vector< CCustomTreeItem * > m_List

virtual string GetText() const =0

CCustomTreeItem * m_Parent

virtual ~CCustomTreeItem()

void OnSetFocus(wxFocusEvent &evt)

void PropagateCheck(CCustomTreeItem *item, bool check)

void OnKillFocus(wxFocusEvent &evt)

void OnPaint(wxPaintEvent &evt)

void SetCurrentItem(CCustomTreeItem *p)

vector< CCustomTreeItem * > m_All

void OnDblClick(wxMouseEvent &evt)

void OnClick(wxMouseEvent &evt)

void OnSize(wxSizeEvent &evt)

void DrawExpander(wxDC &dc, wxRect &rect, bool open, bool highlited)

void CheckParent(CCustomTreeItem *item, bool check)

void OnWheel(wxMouseEvent &evt)

static vector< string > Split(string str, wxDC &dc, int width)

void OnScroll(wxScrollWinEvent &evt)

void ExpandItem(CCustomTreeItem *item, bool expand)

CCustomTreeItem * m_Current

int ItemHeight(const CCustomTreeItem &item, wxDC &dc, int width)

vector< CCustomTreeItem * > m_List

vector< CCustomTreeItem * > m_Visible

void CheckItem(CCustomTreeItem *item, bool check, bool propagate=true)

static const char * str(char *buf, int n)

const CSeq_id & GetId(const CSeq_loc &loc, CScope *scope)

If all CSeq_ids embedded in CSeq_loc refer to the same CBioseq, returns the first CSeq_id found,...

#define END_NCBI_SCOPE

End previously defined NCBI scope.

#define BEGIN_NCBI_SCOPE

Define ncbi namespace.

static list< string > & Split(const CTempString str, const CTempString delim, list< string > &arr, TSplitFlags flags=0, vector< SIZE_TYPE > *token_pos=NULL)

Split a string using specified delimiters.

static size_t rnd(size_t minimal, size_t maximal)

Int4 delta(size_t dimension_, const Int4 *score_)


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