📄 seqgraphic_conf.cpp
字号:
/* * =========================================================================== * PRODUCTION $Log: seqgraphic_conf.cpp,v $ * PRODUCTION Revision 1000.3 2004/06/01 21:12:49 gouriano * PRODUCTION PRODUCTION: UPGRADED [GCC34_MSVC7] Dev-tree R1.24 * PRODUCTION * =========================================================================== *//* $Id: seqgraphic_conf.cpp,v 1000.3 2004/06/01 21:12:49 gouriano Exp $ * =========================================================================== * * PUBLIC DOMAIN NOTICE * National Center for Biotechnology Information * * This software/database is a "United States Government Work" under the * terms of the United States Copyright Act. It was written as part of * the author's official duties as a United States Government employee and * thus cannot be copyrighted. This software/database is freely available * to the public for use. The National Library of Medicine and the U.S. * Government have not placed any restriction on its use or reproduction. * * Although all reasonable efforts have been taken to ensure the accuracy * and reliability of the software and data, the NLM and the U.S. * Government do not and cannot warrant the performance or results that * may be obtained by using this software or data. The NLM and the U.S. * Government disclaim all warranties, express or implied, including * warranties of performance, merchantability or fitness for any particular * purpose. * * Please cite the author in any work or product based on this material. * * =========================================================================== * * Authors: Mike DiCuccio * * File Description: * */#include <ncbi_pch.hpp>#include <gui/widgets/seq_graphic/seqgraphic_conf.hpp>#include <gui/widgets/seq_graphic/color_conf.hpp>#include <gui/widgets/seq_graphic/pane_content_conf.hpp>BEGIN_NCBI_SCOPECSeqGraphicConfig::CSeqGraphicConfig(objects::CPluginConfigCache* config_cache, const string& delim) : CThemeSet(config_cache, "SeqGraphicView", delim), m_FeatRenderPolicy(new CRenderPolicyConfig(config_cache)), m_Content(new CPaneContentConf(config_cache)), m_Color(new CSeqGraphicColorConfig(config_cache)), m_Layout(new CLayoutConfig(config_cache)), m_Font(new CFontConfig(config_cache)), m_Decorations(new CFeatConfigDecorate(config_cache)){ // The order in which they are added, is the order in which they will display. AddSettingsSet(*m_FeatRenderPolicy); AddSettingsSet(*m_Content); AddSettingsSet(*m_Layout); AddSettingsSet(*m_Color); AddSettingsSet(*m_Decorations); AddSettingsSet(*m_Font); LoadCurrentSettings(eLoad_Current);}CSeqGraphicConfig::~CSeqGraphicConfig(){}bool CSeqGraphicConfig::GetHistogram(int type, int subtype) const{ return m_Content->GetHistogram(type, subtype);}void CSeqGraphicConfig::SetHistogram(int type, int subtype, bool hist){ m_Content->SetHistogram(type, subtype, hist);}void CSeqGraphicConfig::SetHistogramInherited(int type, int subtype, bool inherited){ m_Content->SetHistogramInherited(type, subtype, inherited);} bool CSeqGraphicConfig::GetShow(int type, int subtype) const{ return m_Content->GetShow(type, subtype);}void CSeqGraphicConfig::SetShow(int type, int subtype, bool show){ m_Content->SetShow(type, subtype, show);}void CSeqGraphicConfig::SetShowInherited(int type, int subtype, bool inherited){ m_Content->SetShowInherited(type, subtype, inherited);}CGlColor CSeqGraphicConfig::GetColor(int type, int subtype) const{ return m_Color->GetColor(type, subtype);}void CSeqGraphicConfig::SetColor(int type, int subtype, CGlColor color){ m_Color->SetColor(type, subtype, color);}void CSeqGraphicConfig::SetColorInherited(int type, int subtype, bool inherited){ m_Color->SetColorInherited(type, subtype, inherited);}CGlColor CSeqGraphicConfig::GetElementColor(CSeqGraphicColorConfig::EDisplayElement e) const{ return m_Color->GetElementColor(e);}void CSeqGraphicConfig::SetElementColor(CSeqGraphicColorConfig::EDisplayElement e, const CGlColor& c){ m_Color->SetElementColor(e, c);}CRenderPolicyConfig::ERenderPolicys CSeqGraphicConfig::GetFeaturePanelRenderPolicy() const{ return m_FeatRenderPolicy->GetRenderPolicy();}CLayoutConfig::ELayout CSeqGraphicConfig::GetLayout() const{ return m_Layout->GetLayout();}bool CSeqGraphicConfig::GetShowAlignments() const{ return m_Content->GetShowAlignments();}void CSeqGraphicConfig::SetShowAlignments(bool b){ m_Content->SetShowAlignments(b);}bool CSeqGraphicConfig::GetSmearAlignments() const{ // TO DO return false;}void CSeqGraphicConfig::SetSmearAlignments(bool ){ // TO DO}bool CSeqGraphicConfig::GetShowGraphs() const{ return m_Content->GetShowGraphs();}void CSeqGraphicConfig::SetShowGraphs(bool b){ m_Content->SetShowGraphs(b);}bool CSeqGraphicConfig::GetShowSegmentMap() const{ return m_Content->GetShowSegmentMap();}void CSeqGraphicConfig::SetShowSegmentMap(bool b){ m_Content->SetShowSegmentMap(b);}bool CSeqGraphicConfig::GetShowPWAlignLabels() const{ return m_Content->GetShowPWAlignLabels();}void CSeqGraphicConfig::SetShowPWAlignLabels(bool b){ m_Content->SetShowPWAlignLabels(b);}bool CSeqGraphicConfig::GetShowProtProd() const{ // TO DO return true;}void CSeqGraphicConfig::SetShowProtProd(bool){ // TO DO}TSeqPos CSeqGraphicConfig::GetOverviewCutoff() const{ // defines cut-off between overview and detailed modes return 400; // 400 bp per pixel}void CSeqGraphicConfig::SetOverviewCutoff(TSeqPos){ // TO DO}int CSeqGraphicConfig::GetRulerSpacer() const{ return m_Content->GetRulerSpacer();}void CSeqGraphicConfig::SetRulerSpacer(int spacer){ m_Content->SetRulerSpacer(spacer);} TSeqPos CSeqGraphicConfig::GetGenesCutoff() const{ // defines more adaptive cut-off // between overview and detailed modes // based on the number of visible genes return 5;}void CSeqGraphicConfig::SetGenesCutoff(TSeqPos){ // TO DO}END_NCBI_SCOPE/* * =========================================================================== * $Log: seqgraphic_conf.cpp,v $ * Revision 1000.3 2004/06/01 21:12:49 gouriano * PRODUCTION: UPGRADED [GCC34_MSVC7] Dev-tree R1.24 * * Revision 1.24 2004/05/21 22:27:55 gorelenk * Added PCH ncbi_pch.hpp * * Revision 1.23 2004/05/12 16:54:12 lebedev * Added option to specify a space between the ruler and the rest of the dispay * * Revision 1.22 2004/05/10 15:57:54 lebedev * Configuration option to show/hide segment maps added. * * Revision 1.21 2004/05/07 11:12:13 lebedev * Configuration option to show/hide labels for pairwise alignments and mate pairs added. * * Revision 1.20 2004/04/06 13:43:50 dicuccio * Added API to set/get default graph/alignment rendering status * * Revision 1.19 2004/03/30 13:54:50 lebedev * Use EDisplayElement list from CSeqGraphicColorConfig * * Revision 1.18 2004/03/22 16:52:52 rsmith * add Smear Alignment setting. Always false for now. * * Revision 1.17 2004/03/02 15:26:38 lebedev * Configure minimum number of genes as a cut-off between * overview and detailed mode. * * Revision 1.16 2004/02/13 18:13:19 lebedev * Methods for specifying Overview/Detail resolution cutoff added * * Revision 1.15 2004/02/12 14:56:05 rsmith * Add skeleton methods GetShowAligments/Graphs and ProtProds. * * Revision 1.14 2004/02/05 16:05:09 rsmith * add decorations settings * * Revision 1.13 2004/02/04 21:28:48 rsmith * Add font configuration * * Revision 1.12 2004/02/04 15:17:28 rsmith * add CLayout member and methods * * Revision 1.11 2004/01/20 19:45:13 rsmith * Add definition of method GetFeaturePanelRenderPolicy * * Revision 1.10 2004/01/20 19:33:48 dicuccio * Removed return from functions returning void * * Revision 1.9 2004/01/20 19:24:45 ucko * Give the newly declared destructor a (trivial) body, to avoid link errors. * * Revision 1.8 2004/01/20 14:01:40 rsmith * Extensive rewrite to inherit from CThemeSet. Interface has been preserved. * * Revision 1.7 2003/12/30 15:05:57 dicuccio * Fixed compiler warnings on MSVC * * Revision 1.6 2003/12/29 14:52:24 rsmith * Get throws instead of returning special values on failure. * * Revision 1.5 2003/12/22 19:38:36 dicuccio * Code reformatting * * Revision 1.4 2003/12/22 12:55:51 lebedev * Old files removed * * Revision 1.3 2003/11/21 12:56:22 rsmith * Added ClearHistograms() to fix bug when loading data from the PluginConfigCache. * * Revision 1.2 2003/11/18 20:34:15 rsmith * Get/set all histogram settings. Add back in old get/set element colors (background, selectionsm etc.). * * Revision 1.1 2003/10/31 14:07:49 dicuccio * Initial revision * * =========================================================================== */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -