NCBI C++ ToolKit
view_feattable.cpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id: view_feattable.cpp 40880 2018-04-25 20:26:58Z katargir $
2  * ===========================================================================
3  *
4  * PUBLIC DOMAIN NOTICE
5  * National Center for Biotechnology Information
6  *
7  * This software/database is a "United States Government Work" under the
8  * terms of the United States Copyright Act. It was written as part of
9  * the author's official duties as a United States Government employee and
10  * thus cannot be copyrighted. This software/database is freely available
11  * to the public for use. The National Library of Medicine and the U.S.
12  * Government have not placed any restriction on its use or reproduction.
13  *
14  * Although all reasonable efforts have been taken to ensure the accuracy
15  * and reliability of the software and data, the NLM and the U.S.
16  * Government do not and cannot warrant the performance or results that
17  * may be obtained by using this software or data. The NLM and the U.S.
18  * Government disclaim all warranties, express or implied, including
19  * warranties of performance, merchantability or fitness for any particular
20  * purpose.
21  *
22  * Please cite the author in any work or product based on this material.
23  *
24  * ===========================================================================
25  *
26  * Authors: Mike DiCuccio
27  *
28  * File Description:
29  *
30  */
31 
32 #include <ncbi_pch.hpp>
33 
35 
39 
40 #include <gui/objutils/utils.hpp>
41 #include <gui/objutils/label.hpp>
43 
44 #include <corelib/ncbistre.hpp>
45 
46 #include <serial/typeinfo.hpp>
47 
48 #include <gui/types.hpp>
49 
52 
54 #include <objmgr/util/sequence.hpp>
55 
56 #include <wx/menu.h>
57 #include <wx/sizer.h>
58 #include <wx/statusbr.h>
59 
60 
63 
64 
66  "Feature Table View", // type name
67  "feature_table_view", // icon alias TODO
68  "Show tabular information about features",
69  "The Feature Table View provides a tabular break-down of features for the sequence",
70  "FEAT_TABLE_VIEW", // help ID
71  "Sequence", // category
72  false, // not a singleton
73  "Seq-loc",
75 );
76 
77 /*
78  info.AddApplicableUserType(CGUIUserType::sm_Tp_Annotation, CGUIUserType::sm_SbTp_Features);
79  info.AddApplicableUserType(CGUIUserType::sm_Tp_Feature);
80  info.AddApplicableUserType(CGUIUserType::sm_Tp_Location);
81  info.AddApplicableUserType(CGUIUserType::sm_Tp_Sequence);
82  info.AddApplicableUserType(CGUIUserType::sm_Tp_Sequence_ID);
83  info.AddApplicableUserType(CGUIUserType::sm_Tp_Sequence_Set);
84  info.AddApplicableUserType(CGUIUserType::sm_Tp_EntrezGeneRecord, "");
85  // command info
86  CPluginCommand& args = info.SetViewCommand(CPluginCommand::eCommand_new_view);
87  args.AddArgument("loc", "Location to display",
88  CSeq_loc::GetTypeInfo());
89 
90  CPluginArg& arg =
91  args.AddOptionalArgument("annot", "Limit to Annotation",
92  CSeq_annot::GetTypeInfo());
93  arg.SetHidden(true);
94 */
95 
97  eCmdFind = 13000,
101  //eCmdSettings,
103 };
104 
105 /*
106 static
107 DEFINE_MENU(ViewMenu)
108  SUBMENU("&View")
109  SUBMENU(VIEW_UI_NAME)
110  MENU_ITEM(eCmdFind, "Find...")
111  MENU_ITEM(eCmdSelectActiveColumns, "Select Active Columns")
112  MENU_ITEM(eCmdVisibleRangeChange, "Visible Range Change...")
113  MENU_ITEM(eCmdFilter, "Filter...")
114  MENU_ITEM(eCmdExportToCSV, "Export as Spreadsheet")
115  //MENU_SEPARATOR()
116  //MENU_ITEM(eCmdSettings, "Settings...")
117  END_SUBMENU()
118  END_SUBMENU()
119 END_MENU()
120 
121 
122 static
123 DEFINE_MENU(PopupMenu)
124  MENU_ITEM(eCmdFind, "Find...")
125  MENU_ITEM(eCmdSelectActiveColumns, "Select Active Columns")
126  MENU_ITEM(eCmdVisibleRangeChange, "Visible Range Change...")
127  MENU_ITEM(eCmdFilter, "Filter...")
128  MENU_ITEM(eCmdExportToCSV, "Export as Spreadsheet")
129  //MENU_SEPARATOR()
130  //MENU_ITEM(eCmdSettings, "Settings...")
131 END_MENU()
132 */
133 
134 ///////////////////////////////////////////////////////////////////////////////
135 /// CSelFeatHandle
137 {
138 public:
139  CSelFeatHandle( const CFeatTableDS::SFeatureRow& feat_row ) : m_FeatRow( feat_row ) {}
141 
142 protected:
144 };
145 
146 
147 ///////////////////////////////////////////////////////////////////////////////
148 /// CFeatTableView
150  : m_Panel()
151  , m_StatusBar()
152  , m_FTblWidget()
153  , m_DataSource( new CFeatTableDS() )
154 {
155 }
156 
158 {
159  _ASSERT(m_Panel);
160  return m_Panel;
161 }
162 
164 {
165  static bool initialized = false;
166 
167  // this code should execute only once
168  if( ! initialized ){
169  // register commands
170  //CUICommandRegistry& cmd_reg = m_Workbench->GetUICommandRegistry();
171  //cmd_reg->RegisterCommand( ... );
172 
173  // register icons
174  //wxFileArtProvider& provider = m_Workbench->GetFileArtProvider();
175  //provider.RegisterFileAlias( ... );
176 
177  initialized = true;
178  }
179 }
180 
182 {
184 
185  //CUICommandRegistry& cmd_reg = m_Workbench->GetUICommandRegistry();
186 
187  //m_MenuBarMenu.reset( new wxMenu() );
188 
189  /* TODO commands
190  wxMenu* view_menu = new wxMenu();
191  wxMenu* dm_menu = new wxMenu();
192 
193  cmd_reg->AppendMenuItem(*dm_menu, eCmdChooseSeq);
194  cmd_reg->AppendMenuItem(*dm_menu, eCmdColorByScore);
195 
196  view_menu->Append(wxID_ANY, wxT("Dot Matrix"), dm_menu);
197  m_MenuBarMenu->Append(wxID_ANY, wxT("&View"), view_menu);
198 
199  // create menu
200  m_RootItem.reset(CreateMenuItems(ViewMenu));
201 
202  // init view icon
203  CRef<CResourceManager> mgr = CResourceManager::GetInstance();
204  m_Icon = mgr->GetImage(VIEW_ICON_ALIAS);
205  */
206 }
207 
208 
209 // override function to suppress Navigation toolbar
211 {
213 }
214 
215 
216 void CFeatTableView::CreateViewWindow(wxWindow* parent)
217 {
218  _ASSERT( !m_FTblWidget );
219 
220  m_Panel = new wxPanel( parent );
221 
222  // main sizer
223  wxBoxSizer* main_sizer = new wxBoxSizer( wxVERTICAL );
224  m_Panel->SetSizer( main_sizer );
225 
228 
229  m_DataSource->AddListener(this);
230 
233 
234  main_sizer->Add( m_FTblWidget, 1, wxEXPAND );
235 
236  // wxStatusBar
237  m_StatusBar = new wxStatusBar( m_Panel );
238  main_sizer->Add( m_StatusBar, 0, wxEXPAND );
239 
240  //m_Panel->PushEventHandler( new CCommandTransferHandler( m_AlnWidget ) );
241  m_Panel->PushEventHandler( new CCommandToFocusHandler( m_Panel ) );
242 }
243 
244 
246 {
247  if( GetWindow() ){
248  m_Panel->PopEventHandler( true );
249 
251 
253 
254  GetWindow()->Destroy();
255  m_Panel = NULL;
256  m_FTblWidget = NULL;
257  m_StatusBar = NULL;
258  }
259 }
260 
261 
263 {
264  /// restore our table's settings
268 }
269 
270 
272 {
273  /// save our table's settings
277 }
278 
279 
281 {
283 }
284 
286 {
287  if( objects.size() != 1 ){
288  return NULL;
289  }
290 
291  const CObject* object = objects[0].object.GetPointer();
292  CScope* scope = objects[0].scope.GetPointer();
293 
294  for(;;){
295  const CSeq_annot* annot = dynamic_cast<const CSeq_annot*>(object);
296  if( annot ){
297  //! We can fetch CSeq_annot_Handle here.
298  m_OrigObject.Reset( annot );
299  break;
300  }
301 
302  const CSeq_id* seq_id = dynamic_cast<const CSeq_id*>(object);
303  if( seq_id ){
305  loc->SetId( *seq_id );
306 
307  m_OrigObject.Reset( loc );
308  break;
309  }
310 
311  const CSeq_loc* seq_loc = dynamic_cast<const CSeq_loc*>(object);
312  if( seq_loc ){
313  m_OrigObject.Reset( seq_loc );
314  break;
315  }
316 
317  break;
318  }
319 
320  m_Scope.Reset( scope );
321 
322  return m_OrigObject.IsNull() ? NULL : scope;
323 }
324 
326 {
327  if( x_HasProject() ){
329 
330  //m_Sel = CSeqUtils::GetAnnotSelector( CSeq_annot::TData::e_Ftable );
331  //m_DataSource->SetSelector( m_Sel );
332 
333  // LoadSettings();
334  }
335 
337 }
338 
339 
340 
341 
342 bool CFeatTableView::InitView(TConstScopedObjects& objects, const objects::CUser_object* params)
343 {
345 
346  return CProjectView::InitView( objects, params );
347 }
348 
350 {
351  if( evt.GetSubtype() & CProjectViewEvent::eData ){
353  }
354 }
355 
356 
358 {
359  x_Update();
361 }
362 
363 
365 {
366  return m_OrigObject.GetPointer();
367 }
368 
372 
373 // handles incoming selection broadcast (overriding CView virtual function)
374 void CFeatTableView::x_OnSetSelection( CSelectionEvent& evt )
375 {
376  //m_StatusBar->SetMessage( "No features." );
377 
378  if( evt.HasObjectSelection() ){ // set Object Selection
379  m_FTblWidget->ClearSelection();
380 
381  TConstObjects sel_objs;
382  evt.GetAllObjects( sel_objs );
383 
384  CScope& scope = *m_DataSource->GetScope();
385 
386  ITERATE( TConstObjects, it_obj, sel_objs ){
387  const CObject& obj = **it_obj;
388 
389  CObjectIndex::TResults results;
390  m_ObjectIndex.GetMatches( obj, scope, results );
391 
392  ITERATE( CObjectIndex::TResults, it_r, results ){
393  const CSelFeatHandle* fh = (const CSelFeatHandle*)(*it_r);
394  m_FTblWidget->SelectDataRow( fh->GetFeatureRow().row_idx );
395  }
396  }
397 
398  //m_FTblWidget->ScrollSelectionToVisible();
399 
400  x_UpdateStatusMessage(); // prepare our status bar message
401  }
402 }
403 
405 {
408 }
409 
411 {
412  //CProjectView::OnWidgetRangeChanged();
414 }
415 
417 {
419 }
420 
422 {
423  if(m_FTblWidget && x_HasProject()) {
424  m_StatusBar->SetStatusText( wxT("Searching for features...") );
425 
426  m_FTblWidget->Update();
427 
428  // prepare our status bar message
429  //x_UpdateStatusMessage();
430  }
431 }
432 
433 
435 {
436  // prepare our status bar message
437  string status_msg;
438 
439  int total_feats = m_DataSource->GetNumRows();
440  status_msg = NStr::IntToString( total_feats ) + " feature";
441  if( total_feats != 1 ){
442  status_msg += "s";
443  }
444 
445  int visible_feats = m_FTblWidget->GetNumRowsVisible();
446  if( visible_feats != total_feats ){
447  status_msg += ", " + NStr::IntToString( visible_feats );
448  status_msg += " filtered";
449  }
450 
451  int sel_num = m_FTblWidget->GetSelectedItemCount();
452  if( sel_num > 0 ){
453  status_msg += ", " + NStr::IntToString(sel_num);
454  status_msg += " selected";
455  }
456 
457  m_StatusBar->SetStatusText( ToWxString( status_msg ) );
458 }
459 
461 {
463 }
464 
466 {
467  if( m_FTblWidget && x_HasProject() ){
468  CScope* scope = x_GetScope();
469 
470  // add Object selections
471  TConstObjects sel_objs;
472  m_FTblWidget->GetSelection( sel_objs );
473 
474  ITERATE( TConstObjects, it, sel_objs ){
475  objs.push_back( SConstScopedObject(*it, scope) );
476  }
477  }
478 }
479 
480 
482 {
483  if (x_HasProject()) {
484  // Object Selection
485  TConstObjects sel_objs;
486  m_FTblWidget->GetSelection( sel_objs );
487  evt.AddObjectSelection( sel_objs );
488  }
489 }
490 
491 
492 //rebuild index that is used for selection handling
493 
495 {
496  if( m_DataSource ) {
497  CScope& scope = *m_DataSource->GetScope();
498  m_ObjectIndex.Clear( &scope );
499 
500  for( int row = 0; row < m_DataSource->GetNumRows(); ++row ){
501  const CFeatTableDS::SFeatureRow& sfeat = m_DataSource -> GetFeatureRow( row );
502  const CSeq_feat& feat = m_DataSource -> GetFeature( row );
503  m_ObjectIndex.Add( new CSelFeatHandle( sfeat ), feat );
504  }
505  }
506 }
507 
509 {
510  //TSeqRange range = m_FTblWidget->GetSelectionVisibleRange();
511 
512  /* !TBD
513  CRef<CSeq_loc> loc( new CSeq_loc() );
514  loc->SetInt().SetFrom( range.GetFrom() );
515  loc->SetInt().SetTo( range.GetTo() );
516  loc->SetId( * m_OrigLoc -> GetId() );
517  vrange.AddLocation( *loc );
518  */
519 }
520 
521 
522 void CFeatTableView::SetRegistryPath(const string& reg_path)
523 {
524  m_RegPath = reg_path;
525 }
526 
527 
528 /*
529 void CFeatTableView::OnSettings()
530 {
531  CFeatTablePreferenceDialog dlg;
532  dlg.CenterOnActive();
533 
534  CFeatTableWidget::EVisibleRangeMethod method;
535 
536  // set dialog with current setting - Default is Scroll To
537  method = m_FTblWidget->GetVisibleRangeMethod();
538  if( method == CFeatTableWidget::eEntirelyContained ){
539  dlg.SetEntirelyContained();
540  } else if( method == CFeatTableWidget::eIntersection ){
541  dlg.SetIntersection();
542  } else {
543  dlg.SetScrollTo();
544  }
545 
546  if( dlg.ShowModal() ){
547  // visible range method
548  if (dlg.EntirelyContainedMethod()) {
549  method = CFeatTableWidget::eEntirelyContained;
550  } else if (dlg.ScrollToMethod()) {
551  method = CFeatTableWidget::eScrollTo;
552  } else if (dlg.IntersectionMethod()) {
553  method = CFeatTableWidget::eIntersection;
554  }
555 
556  m_FTblWidget->SetVisibleRangeMethod( method );
557 
558  //? m_DataSource->SetSelector(m_Sel);
559  }
560 }
561 */
562 
563 ///////////////////////////////////////////////////////////////////////////////
564 /// CFeatTableViewFactory
566 {
567  static string sid("feature_table_view_factory");
568  return sid;
569 }
570 
572 {
573  static string slabel("Feature Table View Factory");
574  return slabel;
575 }
576 
577 
579 {
580  string alias = GetViewTypeDescriptor().GetIconAlias();
581  provider.RegisterFileAlias(
582  ToWxString(alias), wxT("feature_table_view.png")
583  );
584 }
585 
586 
588 {
590 }
591 
592 
594 {
595  return new CFeatTableView();
596 }
597 
598 
600 {
601  return NULL;
602 }
603 
604 bool CFeatTableViewFactory::IsCompatibleWith( const CObject& object, objects::CScope& )
605 {
606  const type_info& type = typeid(object);
607 
608  if( typeid(CSeq_loc) == type ) return true;
609  if( typeid(CSeq_id) == type ) return true;
610 
611  if( typeid(CSeq_annot) == type ){
612  const CSeq_annot& annot = dynamic_cast<const CSeq_annot&>(object);
613  return annot.IsFtable();
614  }
615 
616  return false;
617 }
618 
619 
621 {
622  bool found_good = false;
623  bool found_bad = false;
624  for( size_t i = 0; i < objects.size(); i++ ){
625  if( IsCompatibleWith( *objects[i].object, *objects[i].scope ) ){
626  found_good = true;
627  } else {
628  found_bad = true;
629  }
630  }
631 
632  if( found_good ){
633  return fCanShowSeparated | (found_bad ? fCanShowSome : fCanShowAll);
634  }
635  return 0; // can show nothing
636 }
637 
638 
640 {
641  if( objects.size() < 2 ){
642  return true;
643  }
644  // verify that all the objects has the same seq-id
646  TRanges ranges;
648  const CSeq_loc* loc = dynamic_cast<const CSeq_loc*> (iter->object.GetPointer());
649  if (loc) {
650  CScope* scope = const_cast<CScope*>(iter->scope.GetPointer());
651  CSeq_id_Handle idh = sequence::GetIdHandle(*loc, scope);
652  TSeqRange range = loc->GetTotalRange();
653  ranges[idh] += range;
654  }
655  }
656  if (ranges.size() == 1) {
657  CRef<objects::CScope> scope = objects[0].scope;
658  CRef<CSeq_loc> loc(new CSeq_loc);
659  TRanges::iterator iter = ranges.begin();
660  loc->SetInt().SetFrom(iter->second.GetFrom());
661  loc->SetInt().SetTo (iter->second.GetTo());
662  loc->SetId(*iter->first.GetSeqId());
663 
664  objects.clear();
665  objects.push_back(
666  SConstScopedObject(loc, scope)
667  );
668  return true;
669  } else {
670  return false;
671  }
672 }
673 
674 
vector< TRangeWithFuzz > TRanges
Definition: Seq_loc.cpp:4277
CEvent - generic event implementation TODO TODO - Attachments.
Definition: event.hpp:86
CFeatTableDS Data source for Feature Table widget.
virtual int GetNumRows() const
Returns the number of rows in the model.
CRef< objects::CScope > GetScope() const
void Init(const CSerialObject &obj, objects::CScope &scope, const objects::SAnnotSelector *sel=0)
CFeatTableView.
CFeatTableWidget.
Definition: feat_table.hpp:63
void SetVisibleRange(const objects::CSeq_loc &loc)
set the visible range for the widget.
Definition: feat_table.cpp:133
void GetSelection(TConstObjects &objs) const
Get the selected objects.
Definition: feat_table.cpp:160
void SetDataSource(CFeatTableDS *ds)
access the data source in a typesafe manner
Definition: feat_table.cpp:93
CRegistryWriteView GetWriteView(const string &section)
get a read-write view at a particular level.
Definition: registry.cpp:462
static CGuiRegistry & GetInstance()
access the application-wide singleton
Definition: registry.cpp:400
CRegistryReadView GetReadView(const string &section) const
get a read-only view at a particular level.
Definition: registry.cpp:428
void Clear(objects::CScope *scope)
void Add(ISelObjectHandle *obj_handle, CObject &obj)
CObject –.
Definition: ncbiobj.hpp:180
virtual void x_UpdateContentLabel()
virtual objects::CScope * x_GetScope() const
virtual bool x_HasProject() const
CProjectViewEvent.
Definition: document.hpp:62
EEventSubtype GetSubtype() const
Definition: document.hpp:96
CProjectViewTypeDescriptor - holds description of a project view type.
CProjectView.
virtual void OnWidgetSelChanged()
virtual bool InitView(TConstScopedObjects &objects, const objects::CUser_object *params)
initialize view with data, inside this function the view must call CProjectService::AttachView to con...
class CRegistryReadView provides a nested hierarchical view at a particular key.
Definition: reg_view.hpp:58
CScope –.
Definition: scope.hpp:92
CSelFeatHandle.
const CFeatTableDS::SFeatureRow & m_FeatRow
const CFeatTableDS::SFeatureRow & GetFeatureRow() const
CSelFeatHandle(const CFeatTableDS::SFeatureRow &feat_row)
CSelectionEvent CSelectionEvent is used for broadcasting selection between views.
Definition: obj_event.hpp:68
bool AddObjectSelection(const CObject &obj)
Definition: obj_event.cpp:177
bool IsFtable(void) const
Definition: Seq_annot.cpp:177
namespace ncbi::objects::
Definition: Seq_feat.hpp:58
CViewTypeDescriptor - holds description of a view type.
Definition: view.hpp:98
void LoadTableSettings(const CRegistryReadView &view, bool byName=false)
void SaveTableSettings(CRegistryWriteView &view, bool saveSorting=true) const
int GetNumRowsVisible() const
virtual const CViewTypeDescriptor & GetViewTypeDescriptor() const
returns a Descriptor for the View Type supported by the Factory
IView - represents a standard visual part of Workbench UI.
Definition: view.hpp:73
CFingerprint identifies an instance of IWMClient and is used for labeling layout positions.
Definition: wm_client.hpp:58
Definition: map.hpp:338
Definition: set.hpp:45
virtual void RegisterFileAlias(const wxArtID &anId, const wxArtClient &aClient, const wxSize &aSize, const wxString &aName, long aType=wxBITMAP_TYPE_ANY, int anIndex=-1)
static const struct name_t names[]
static int type
Definition: getdata.c:31
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
Definition: ncbimisc.hpp:815
#define NULL
Definition: ncbistd.hpp:225
virtual const CViewTypeDescriptor & GetTypeDescriptor() const
return an object providing meta information about thei view type
virtual bool InitView(TConstScopedObjects &objects, const objects::CUser_object *params)
initialize view with data, inside this function the view must call CProjectService::AttachView to con...
virtual void CreateViewWindow(wxWindow *parent)
create Window corresponding to the view
wxStatusBar * m_StatusBar
void x_OnFeatTableEvent(CEvent *)
virtual string GetExtensionIdentifier() const
CFeatTableViewFactory.
virtual IView * CreateInstanceByFingerprint(const TFingerprint &fingerprint) const
if fingerprint is recognized - creates and returns a new instance
virtual int TestInputObjects(TConstScopedObjects &objects)
tests input objects (probably using object conversion, or not) and returns a combination of ETestResu...
virtual bool x_MergeObjects(TConstScopedObjects &objects)
virtual void x_Update()
CRef< objects::CScope > m_Scope
virtual void LoadSettings()
CRef< CFeatTableDS > m_DataSource
void x_InitMenuResources()
virtual void SetRegistryPath(const string &reg_path)
CObjectIndex m_ObjectIndex
CFeatTableView()
CFeatTableView.
virtual void OnProjectChanged()
virtual void RegisterIconAliases(wxFileArtProvider &provider)
called by the framework to give Factory a chance to register images used by view
virtual void GetSelection(CSelectionEvent &evt) const
get selection for broadcasting
virtual bool IsCompatibleWith(const CObject &object, objects::CScope &scope)
CFeatTableWidget * m_FTblWidget
virtual void DestroyViewWindow()
destroy Window corresponding to the view
void x_PostAttachToProject()
virtual void x_SetVisibleRange(const objects::CSeq_loc &loc)
virtual void x_UpdateStatusMessage()
virtual const CProjectViewTypeDescriptor & GetProjectViewTypeDescriptor() const
returns a Descriptor for the View Type supported by the Factory
virtual void x_RebuildObjectIndex()
virtual void GetVisibleRanges(CVisibleRange &vrange) const
populate a visible range event for broadcasting
virtual void OnWidgetRangeChanged()
virtual IView * CreateInstance() const
creates a view instance
virtual string GetExtensionLabel() const
returns a displayable label for this extension ( please capitalize the key words - "My Extension" )
virtual void x_CreateMenuBarMenu()
initializes m_MenuBarMenu; override in derived classes
virtual void SaveSettings() const
CConstRef< CSerialObject > m_OrigObject
original data object passed to the view
virtual wxWindow * GetWindow()
returns a pointer to the wxWindow representing the client
objects::CScope * x_PreAttachToProject(TConstScopedObjects &objects)
virtual const CObject * x_GetOrigObject() const
virtual void GetCompatibleToolBars(vector< string > &names)
returns the names of toolbars compatible with this class (toolbars that are relevant and useful in th...
virtual void OnWidgetSelChanged()
virtual void RemoveListener(CEventHandler *listener)
Remove a listener.
vector< CConstRef< CObject > > TConstObjects
Definition: objects.hpp:64
virtual const string & GetIconAlias() const
Definition: ui_object.cpp:130
#define ON_EVENT(type, id, handler)
#define END_EVENT_MAP()
Ends definition of Command Map.
#define BEGIN_EVENT_MAP(thisClass, baseClass)
Begins definition of Command Map for CEventHandler-derived class.
virtual void AddListener(CEventHandler *listener, int pool_name=ePool_Default)
Add a listener.
vector< SConstScopedObject > TConstScopedObjects
Definition: objects.hpp:65
void SetId(CSeq_id &id)
set the 'id' field in all parts of this location
Definition: Seq_loc.cpp:3474
TRange GetTotalRange(void) const
Definition: Seq_loc.hpp:913
void SetInt(TInt &v)
Definition: Seq_loc.hpp:983
CSeq_id_Handle GetIdHandle(const CSeq_loc &loc, CScope *scope)
TObjectType * GetPointer(void) const THROWS_NONE
Get pointer,.
Definition: ncbiobj.hpp:1684
bool IsNull(void) const THROWS_NONE
Check if pointer is null – same effect as Empty().
Definition: ncbiobj.hpp:1401
void Reset(void)
Reset reference object.
Definition: ncbiobj.hpp:1439
void Reset(void)
Reset reference object.
Definition: ncbiobj.hpp:773
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
static string IntToString(int value, TNumToStringFlags flags=0, int base=10)
Convert int to string.
Definition: ncbistr.hpp:5084
@ e_Whole
whole sequence
Definition: Seq_loc_.hpp:100
int i
#define wxT(x)
Definition: muParser.cpp:41
range(_Ty, _Ty) -> range< _Ty >
NCBI C++ stream class wrappers for triggering between "new" and "old" C++ stream libraries.
@ eSimilarObjectsAccepted
#define row(bind, expected)
Definition: string_bind.c:73
our actual features
Definition: type.c:6
#define _ASSERT
USING_SCOPE(objects)
EFeatTableCommands
@ eCmdSelectActiveColumns
@ eCmdExportToCSV
@ eCmdFind
@ eCmdVisibleRangeChange
@ eCmdFilter
CProjectViewTypeDescriptor s_FeatTableViewTypeDescr("Feature Table View", "feature_table_view", "Show tabular information about features", "The Feature Table View provides a tabular break-down of features for the sequence", "FEAT_TABLE_VIEW", "Sequence", false, "Seq-loc", eSimilarObjectsAccepted)
wxString ToWxString(const string &s)
Definition: wx_utils.hpp:173
Modified on Tue Apr 23 07:38:34 2024 by modify_doxy.py rev. 669887