alninfo_table.hpp
上传用户:yhdzpy8989
上传日期:2007-06-13
资源大小:13604k
文件大小:5k
- /*
- * ===========================================================================
- * PRODUCTION $Log: alninfo_table.hpp,v $
- * PRODUCTION Revision 1000.1 2004/04/12 19:33:03 gouriano
- * PRODUCTION PRODUCTION: UPGRADED [CATCHUP_003] Dev-tree R1.7
- * PRODUCTION
- * ===========================================================================
- */
- #ifndef GUI_CORE_VIEW_ALIGN___ALNINFO_TABLE__HPP
- #define GUI_CORE_VIEW_ALIGN___ALNINFO_TABLE__HPP
- /* $Id: alninfo_table.hpp,v 1000.1 2004/04/12 19:33:03 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:
- * CAlnInfoTable -- text (tabular) view of alignment, intended for internal
- * NCBI use
- */
- #include <gui/widgets/fl/table_panel.hpp>
- #include <objtools/alnmgr/alnvec.hpp>
- BEGIN_NCBI_SCOPE
- USING_SCOPE(objects);
- class CAlnInfoTable : public CTablePanelBase
- {
- public:
- // enumerated list of our viewing modes
- enum EMode {
- eSegments,
- eSequence,
- eScores
- };
- CAlnInfoTable(int x, int y, int w, int h, const char* label = NULL);
- // update the table to reflect the contents of a given alignment manager
- void Update(CAlnVec& aln_mgr);
- // handle resize nicely
- void resize(int x, int y, int w, int h);
- // set the viewing mode
- void SetMode(EMode mode);
- protected:
- // our current viewing mode
- EMode m_Mode;
- // a reference to our alignment manager
- CRef<CAlnVec> m_AlnMgr;
- // Flek overloads
- virtual int handle(int event);
- //virtual void get_style(Flv_Style& s, int row, int col);
- virtual void draw_cell(TableContext ctx, int row, int col,
- int x, int y, int w, int h);
- // internal function to adjust our column widths
- void x_SetColWidths();
- };
- END_NCBI_SCOPE
- #endif // GUI_CORE_VIEW_ALIGN___ALNINFO_TABLE__HPP
- /*
- * ===========================================================================
- * $Log: alninfo_table.hpp,v $
- * Revision 1000.1 2004/04/12 19:33:03 gouriano
- * PRODUCTION: UPGRADED [CATCHUP_003] Dev-tree R1.7
- *
- * Revision 1.7 2003/12/09 15:51:24 dicuccio
- * Deprecated Fl_Toggle_Tree - replaced with Flu_Tree_Browser. Added CTreeBrowser
- * as a standard tree interface
- *
- * Revision 1.6 2003/09/29 15:41:07 dicuccio
- * Deprecated gui/scope.hpp. Merged gui/core/types.hpp into gui/types.hpp. Made
- * all menu bars flat (used FL_FLAT_BOX)
- *
- * Revision 1.5 2003/09/24 18:25:36 dicuccio
- * Inherit from CTablePanelBase. Cleaned up rendering code.
- *
- * Revision 1.4 2003/09/04 14:53:09 dicuccio
- * Inherit from FL_Table_Row, not Fl_Table
- *
- * Revision 1.3 2003/07/25 13:44:48 dicuccio
- * Replaced Flv_Table with Fl_Table
- *
- * Revision 1.2 2003/06/02 16:06:22 dicuccio
- * Rearranged src/objects/ subtree. This includes the following shifts:
- * - src/objects/asn2asn --> arc/app/asn2asn
- * - src/objects/testmedline --> src/objects/ncbimime/test
- * - src/objects/objmgr --> src/objmgr
- * - src/objects/util --> src/objmgr/util
- * - src/objects/alnmgr --> src/objtools/alnmgr
- * - src/objects/flat --> src/objtools/flat
- * - src/objects/validator --> src/objtools/validator
- * - src/objects/cddalignview --> src/objtools/cddalignview
- * In addition, libseq now includes six of the objects/seq... libs, and libmmdb
- * replaces the three libmmdb? libs.
- *
- * Revision 1.1 2003/03/03 18:29:55 dicuccio
- * Initial revision
- *
- * ===========================================================================
- */