OpenStructure
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ics_editor.hh
Go to the documentation of this file.
1 //------------------------------------------------------------------------------
2 // This file is part of the OpenStructure project <www.openstructure.org>
3 //
4 // Copyright (C) 2008-2011 by the OpenStructure authors
5 //
6 // This library is free software; you can redistribute it and/or modify it under
7 // the terms of the GNU Lesser General Public License as published by the Free
8 // Software Foundation; either version 3.0 of the License, or (at your option)
9 // any later version.
10 // This library is distributed in the hope that it will be useful, but WITHOUT
11 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12 // FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
13 // details.
14 //
15 // You should have received a copy of the GNU Lesser General Public License
16 // along with this library; if not, write to the Free Software Foundation, Inc.,
17 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 //------------------------------------------------------------------------------
19 #ifndef OST_ICS_EDITOR_HE
20 #define OST_ICS_EDITOR_HE
21 /*
22  Author: Marco Biasini
23  */
24 
25 #include <ost/mol/module_config.hh>
26 #include <ost/geom/geom.hh>
27 
28 #include "handle_type_fw.hh"
29 #include "editor_base.hh"
30 namespace ost { namespace mol {
31 
35 public:
36  friend class EntityHandle;
37  ~ICSEditor();
38 protected:
39  ICSEditor(const EntityHandle& ent, EditMode mode);
40 
41  void Update();
42 public:
43  ICSEditor(const ICSEditor& rhs);
44 
45  ICSEditor& operator=(const ICSEditor& rhs);
46 
55  void SetBondLength(const BondHandle& bond, Real length);
56 
66 
67  bool SetAngle(const AtomHandle& atom_a, const AtomHandle& atom_b,
68  const AtomHandle& atom_c, Real angle);
69 
77  void SetTorsionAngle(TorsionHandle torsion, Real angle,
78  bool update_others=true);
80  void RotateTorsionAngle(TorsionHandle torsion, Real delta,
81  bool update_others=true);
82 
83  void RotateTorsionAngle(const AtomHandle& atom_a,
84  const AtomHandle& atom_b,
85  const AtomHandle& atom_c,
86  const AtomHandle& atom_d,
87  Real angle,
88  bool update_others=true);
89 
90  void SetTorsionAngle(const AtomHandle& atom_a, const AtomHandle& atom_b,
91  const AtomHandle& atom_c, const AtomHandle& atom_d,
92  Real angle, bool update_others=true);
93 
95  void UpdateXCS();
96 };
97 
98 }} // ns
99 
105 #endif
Handle to atom datatype.
Definition: atom_handle.hh:37
float Real
Definition: base.hh:44
Protein or molecule.
editor for internal molecule coordinates
Definition: ics_editor.hh:34
#define DLLEXPORT_OST_MOL
Named torsion (dihedral) angle.
chemical bond
Definition: bond_handle.hh:34
base class for entity editors
Definition: editor_base.hh:46