File: Editor.h

package info (click to toggle)
pymol 2.4.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 43,312 kB
  • sloc: cpp: 480,106; python: 79,860; ansic: 28,343; javascript: 6,792; sh: 47; makefile: 30; csh: 8
file content (98 lines) | stat: -rw-r--r-- 3,899 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98

/* 
A* -------------------------------------------------------------------
B* This file contains source code for the PyMOL computer program
C* copyright 1998-2000 by Warren Lyford Delano of DeLano Scientific. 
D* -------------------------------------------------------------------
E* It is unlawful to modify or remove this copyright notice.
F* -------------------------------------------------------------------
G* Please see the accompanying LICENSE file for further information. 
H* -------------------------------------------------------------------
I* Additional authors of this source file include:
-* 
-* 
-*
Z* -------------------------------------------------------------------
*/
#ifndef _H_Editor
#define _H_Editor

#include"Ortho.h"
#include"ButMode.h"
#include"ObjectMolecule.h"

#define cEditorSele1 "pk1"
#define cEditorSele2 "pk2"
#define cEditorSele3 "pk3"
#define cEditorSele4 "pk4"
#define cEditorFragPref "_pkfrag"
#define cEditorBasePref "_pkbase"
#define cEditorSet    "pkset"
#define cEditorBond   "pkbond"
#define cEditorRes    "pkresi"
#define cEditorChain  "pkchain"
#define cEditorObject "pkobject"
#define cEditorComp   "pkmol"
#define cEditorLink   "pkfrag"
#define cEditorDihedral "_pkdihe"
#define cEditorDihe1    "_pkdihe1"
#define cEditorDihe2    "_pkdihe2"
#define cEditorDrag    "_drag"
#define cEditorMeasure "_auto_measure"

#define EDITOR_SCHEME_OBJ 1
#define EDITOR_SCHEME_FRAG 2
#define EDITOR_SCHEME_DRAG 3

int EditorInit(PyMOLGlobals * G);
int EditorActive(PyMOLGlobals * G);
void EditorRender(PyMOLGlobals * G, int state);
int EditorLogState(PyMOLGlobals * G, int pkresi);
void EditorFavorOrigin(PyMOLGlobals * G, float *v1);

void EditorFree(PyMOLGlobals * G);
void EditorSetDrag(PyMOLGlobals * G, CObject * obj, int sele, int quiet,
                   int state);
void EditorReadyDrag(PyMOLGlobals * G, int state);
void EditorPrepareDrag(PyMOLGlobals * G, CObject * obj, int sele, int index,
                       int state, int mode);
int EditorDraggingObjectMatrix(PyMOLGlobals *G);
void EditorDrag(PyMOLGlobals * G, CObject * obj, int index, int mode, int state,
                float *pt, float *mov, float *z_dir);

void EditorActivate(PyMOLGlobals * G, int state, int enable_bond);
CObject *EditorDragObject(PyMOLGlobals * G);
pymol::Result<> EditorReplace(PyMOLGlobals* G, const char* elem, int geom,
    int valence, const char* name = "", int quiet = 1);
pymol::Result<> EditorAttach(PyMOLGlobals* G, const char* elem, int geom,
    int valence, const char* name, int quiet);
pymol::Result<> EditorRemove(PyMOLGlobals * G, int hydrogen, int quiet);
pymol::Result<> EditorHFill(PyMOLGlobals * G, int quiet=1);
pymol::Result<> EditorHFix(PyMOLGlobals * G, const char *sele, int quiet);
pymol::Result<> EditorCycleValence(PyMOLGlobals * G, int quiet=1);
void EditorInactivate(PyMOLGlobals * G);

int EditorIsAnActiveObject(PyMOLGlobals * G, ObjectMolecule * obj);

pymol::Result<> EditorSelect(PyMOLGlobals* G, const char* s0, const char* s1,
    const char* s2, const char* s3, int pkresi, int pkbond, int quiet);
pymol::Result<> EditorTorsion(PyMOLGlobals * G, float angle);
pymol::Result<> EditorInvert(PyMOLGlobals * G, int quiet);

PyObject *EditorAsPyList(PyMOLGlobals * G);
int EditorFromPyList(PyMOLGlobals * G, PyObject * list);
void EditorGetNextMultiatom(PyMOLGlobals * G, char *name);
int EditorGetSinglePicked(PyMOLGlobals * G, char *name);
int EditorIsBondMode(PyMOLGlobals * G);
int EditorDeselectIfSelected(PyMOLGlobals * G, ObjectMolecule * obj, int index,
                             int update);
void EditorDefineExtraPks(PyMOLGlobals * G);
int EditorGetNFrag(PyMOLGlobals * G);
void EditorUpdate(PyMOLGlobals * G);
void EditorMouseInvalid(PyMOLGlobals * G);
int EditorGetScheme(PyMOLGlobals * G);
void EditorDihedralInvalid(PyMOLGlobals * G, ObjectMolecule * obj);

void EditorInvalidateShaderCGO(PyMOLGlobals * G);

#endif