<< id); \
108wxWindow* parent, wxWindowID
id,
constwxString& title,
constwxPoint& pos) :
109wxDialog(parent,
id, title, pos, wxDefaultSize, wxDEFAULT_DIALOG_STYLE),
110handle(parentHandle), structureWindow(cn3dFrame)
126 const string& cddName = structureSet->GetCDDName();
127 if(cddName.size() > 0)
128tName->SetLabel(cddName.c_str());
130 const string& cddDescr = structureSet->GetCDDDescription();
131 if(cddDescr.size() > 0) {
133 for(
i=j=0;
i<cddDescr.size(); ++
i, ++j) {
134 if(j > 60 && cddDescr[
i] ==
' ') {
138*tDescr << cddDescr[
i];
145 if(annots && annots->
Get().size() > 0) {
146*tDescr <<
"Annotation summary:\n\n";
147CAlign_annot_set::Tdata::const_iterator
a, ae = annots->
Get().end();
148 for(
a=annots->
Get().begin();
a!=ae; ++
a) {
149*tDescr << ((*a)->IsSetDescription() ? (*a)->GetDescription() :
string(
"")).c_str()
151 if((*a)->IsSetEvidence()) {
152CAlign_annot::TEvidence::const_iterator e, ee = (*a)->GetEvidence().end();
153 for(e=(*a)->GetEvidence().begin(); e!=ee; ++e) {
154 if((*e)->IsComment())
155*tDescr <<
" comment: "<< (*e)->GetComment().c_str() <<
'\n';
156 else if((*e)->IsReference() && (*e)->GetReference().IsPmid()) {
158*tDescr <<
" PubMed "<< pmid_str <<
'\n';
160 else if((*e)->IsBsannot()) {
161*tDescr <<
" structure:";
162 if((*e)->GetBsannot().GetFeatures().size() > 0 &&
163(*e)->GetBsannot().GetFeatures().front()->IsSetDescr() &&
164(*e)->GetBsannot().GetFeatures().front()->IsSetDescr() &&
165(*e)->GetBsannot().GetFeatures().front()->GetDescr().front()->IsName())
167(*e)->GetBsannot().GetFeatures().front()->GetDescr().front()->GetName().c_str();
168 if((*e)->GetBsannot().IsSetId() && (*e)->GetBsannot().GetId().front()->IsMmdb_id()) {
169 intmmdbID = (*e)->GetBsannot().GetId().front()->GetMmdb_id().Get();
170StructureSet::ObjectList::const_iterator o, oe = structureSet->objects.end();
171 for(o=structureSet->objects.begin(); o!=oe; ++o) {
172 if((*o)->mmdbID == mmdbID) {
173*tDescr <<
" ("<< (*o)->GetPDBID().c_str() <<
')';
187 if(structureSet->objects.size() > 0) {
188*tDescr <<
"Structure summary:\n";
189StructureSet::ObjectList::const_iterator o, oe = structureSet->objects.end();
190 for(o=structureSet->objects.begin(); o!=oe; ++o) {
191*tDescr <<
"\nPDB "<< (*o)->GetPDBID().c_str() <<
" (MMDB "<< (*o)->mmdbID <<
")\n";
194 typedeflist < string > ChainList;
198ChemicalGraph::MoleculeMap::const_iterator m, me = (*o)->graph->molecules.
end();
199 for(m=(*o)->graph->molecules.begin(); m!=me; ++m) {
200 if(m->second->IsProtein() || m->second->IsNucleotide()) {
202SequenceSet::SequenceList::const_iterator
203s, se = structureSet->sequenceSet->sequences.end();
204 for(s=structureSet->sequenceSet->sequences.begin(); s!=se; ++s) {
205 if((*s)->identifier == m->second->identifier) {
207descr.Printf(
"%s: gi %s (%s)", m->second->identifier->ToString().c_str(),
208gi_str.c_str(), (*s)->GetDescription().c_str());
215descr.Printf(
"%s: gi %s", m->second->identifier->ToString().c_str(), gi_str.c_str());
219}
else if(m->second->IsHeterogen()) {
221 const string& name = m->second->residues.find(1)->second->nameGraph;
222HetList::iterator
n= hetList.find(name);
223 if(
n== hetList.end())
232ChainList::const_iterator c, ce = chainList.end();
233 for(c=chainList.begin(); c!=ce; ++c)
234*tDescr <<
" "<< c->c_str() <<
'\n';
237 if(hetList.size() > 0) {
238*tDescr <<
"Heterogens: ";
239HetList::const_iterator h, he = hetList.end();
240 for(h=hetList.begin(); h!=he; ++h) {
241 if(h != hetList.begin())
245descr.Printf(
"%s (x%i)", h->first.c_str(), h->second);
247descr = h->first.c_str();
256CCdd_descr_set::Tdata::const_iterator d, de = cddRefs->
Get().end();
257 for(d=cddRefs->
Get().begin(); d!=de; ++d) {
258 if((*d)->IsReference() && (*d)->GetReference().IsPmid())
262bRef->Enable(
false);
265 if(cddAnnot->
Get().size() == 0)
266bAnnot->Enable(
false);
269topSizer->Fit(
this);
270topSizer->SetSizeHints(
this);
290 else if(event.GetId() ==
ID_B_REF) {
308wxBoxSizer *item0 =
newwxBoxSizer( wxVERTICAL );
310wxFlexGridSizer *item1 =
newwxFlexGridSizer( 2, 0, 0 );
311item1->AddGrowableCol( 1 );
313wxStaticText *item2 =
newwxStaticText( parent,
ID_TEXT,
"Name:", wxDefaultPosition, wxDefaultSize, 0 );
314item1->Add( item2, 0, wxALIGN_CENTRE|wxALL, 5 );
316wxStaticText *item3 =
newwxStaticText( parent,
ID_ST_NAME,
"", wxDefaultPosition, wxDefaultSize, 0 );
317item1->Add( item3, 0, wxGROW|wxALIGN_CENTER_VERTICAL|wxALL, 5 );
319item0->Add(item1, 0, wxGROW | wxALL, 5);
321wxTextCtrl *item4 =
newwxTextCtrl( parent,
ID_T_DESCR,
"", wxDefaultPosition, wxSize(-1,100), wxTE_MULTILINE|wxTE_READONLY );
322item0->Add(item4, 0, wxGROW | wxALL, 5);
324wxBoxSizer *item5 =
newwxBoxSizer( wxHORIZONTAL );
326wxButton *item6 =
newwxButton( parent,
ID_B_ANNOT,
"Show Annotations Panel", wxDefaultPosition, wxDefaultSize, 0 );
327item5->Add( item6, 0, wxGROW | wxALL, 5 );
329wxButton *item7 =
newwxButton( parent,
ID_B_REF,
"Show References Panel", wxDefaultPosition, wxDefaultSize, 0 );
330item5->Add(item7, 0, wxGROW | wxALL, 5);
332item5->Add( 20, 20, 0, wxALIGN_CENTRE| wxALL, 5 );
334wxButton *item8 =
newwxButton( parent,
ID_B_DONE,
"Dismiss", wxDefaultPosition, wxDefaultSize, 0 );
335item5->Add( item8, 0, wxGROW | wxALL, 5 );
337item0->Add( item5, 0, wxALIGN_CENTRE|wxALL, 5 );
341parent->SetAutoLayout(
TRUE);
342parent->SetSizer( item0 );
345item0->Fit( parent );
346item0->SetSizeHints( parent );
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
#define DECLARE_AND_FIND_WINDOW_RETURN_ON_ERR(var, id, type)
wxSizer * SetupCDDSplashDialog(wxWindow *parent, bool call_fit=TRUE, bool set_sizer=TRUE)
CDDSplashDialog ** handle
void OnCloseWindow(wxCloseEvent &event)
void OnButton(wxCommandEvent &event)
StructureWindow * structureWindow
void ShowCDDReferences(void)
void ShowCDDAnnotations(void)
const_iterator end() const
Include a standard set of the NCBI C++ Toolkit most basic headers.
#define END_SCOPE(ns)
End the previously defined scope.
#define BEGIN_SCOPE(ns)
Define a new scope.
static enable_if< is_arithmetic< TNumeric >::value||is_convertible< TNumeric, Int8 >::value, string >::type NumericToString(TNumeric value, TNumToStringFlags flags=0, int base=10)
Convert numeric value to string.
const Tdata & Get(void) const
Get the member data.
const Tdata & Get(void) const
Get the member data.
#define TRUE
bool replacment for C indicating true.
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