BALL
1.4.2
|
#include <BALL/VIEW/WIDGETS/editableScene.h>
Classes | |
class | EditOperation |
Public Types | |
enum | EditMode { EDIT__MODE = PICKING__MODE + 1 } |
Public Types inherited from BALL::VIEW::Scene | |
enum | ModeType { ROTATE__MODE = 0, MOVE__MODE, PICKING__MODE } |
enum | ModeAction { TRANSLATE_ACTION, ZOOM_ACTION, ROTATE_ACTION, ROTATE_CLOCKWISE_ACTION } |
Different Mouse Mode actions. More... | |
enum | WindowType { CONTROL_WINDOW = 0, LEFT_EYE_WINDOW, RIGHT_EYE_WINDOW } |
Public Slots | |
virtual void | mousePressEvent (QMouseEvent *e) |
virtual void | mouseMoveEvent (QMouseEvent *e) |
virtual void | mouseReleaseEvent (QMouseEvent *e) |
virtual void | wheelEvent (QWheelEvent *qmouse_event) |
void | createNewMolecule () |
void | saturateWithHydrogens () |
void | optimizeStructure () |
void | computeBondOrders () |
void | setEditElementType (int element_number) |
int | getEditElementType () |
Public Slots inherited from BALL::VIEW::Scene | |
void | createCoordinateSystem () |
Create an coordinate system at current position. More... | |
void | createCoordinateSystemAtOrigin () |
Create an coordinate system at origin. More... | |
String | exportPNG () |
Export PNG image and return the filename. More... | |
void | exportPOVRay () |
void | exportNextPOVRay () |
Export to POVRay whithout showing file dialog. More... | |
void | printScene () |
void | showExportPNGDialog () |
show an dialog to save an PNG file to More... | |
void | showExportVRMLDialog () |
opens the VIEW/DIALOGS/GeometryExportDialog for vrml and stl export More... | |
void | setPreview (bool state) |
Enable or disable model previews e.g. while rotating. More... | |
bool | usePreview () const |
Returns the state of the preview mode. More... | |
virtual void | switchShowWidget () |
void | addGlWindow () |
void | exitStereo () |
void | enterActiveStereo () |
void | enterDualStereo () |
void | enterDualStereoDifferentDisplays () |
void | clearRecordedAnimation () |
void | startAnimation () |
void | stopAnimation () |
void | switchToLastMode () |
void | switchShowGrid () |
void | showInfos () |
Popup informations for object under mouse cursor. More... | |
void | setupViewVolume () |
void | storeViewPoint () |
void | restoreViewPoint () |
Signals | |
void | newEditOperation (EditableScene::EditOperation &eo) |
Public Member Functions | |
EditableScene () | |
EditableScene (QWidget *parent_widget, const char *name=NULL, Qt::WFlags w_flags=0) | |
Default Constructor. More... | |
EditableScene (const EditableScene &eScene, QWidget *parent_widget=NULL, const char *name=NULL, Qt::WFlags wflags=0) | |
Copy constructor. More... | |
virtual | ~EditableScene () |
Destructor. More... | |
void | initializeWidget (MainControl &main_control) |
void | checkMenu (MainControl &main_control) |
void | initializePreferencesTab (Preferences &preferences) |
void | finalizePreferencesTab (Preferences &preferences) |
virtual void | applyPreferences () |
void | showContextMenu (QPoint pos) |
virtual void | setMode (ModeType mode) |
void | addStructure (String name) |
void | setCursor (String c) |
void | setElementCursor () |
Public Member Functions inherited from BALL::VIEW::Scene | |
Scene () | |
Scene (QWidget *parent_widget, const char *name=NULL, Qt::WFlags w_flags=0) | |
Scene (const Scene &scene, QWidget *parent_widget=NULL, const char *name=NULL, Qt::WFlags wflags=0) | |
virtual | ~Scene () |
virtual void | clear () |
void | set (const Scene &scene) |
const Scene & | operator= (const Scene &scene) |
virtual bool | exportScene (Renderer &er) const |
virtual void | fetchPreferences (INIFile &inifile) |
virtual void | writePreferences (INIFile &inifile) |
virtual bool | isValid () const |
virtual void | dump (std::ostream &s=std::cout, Size depth=0) const |
Stage * | getStage () |
const Stage * | getStage () const |
void | setCamera (const Camera &camera) |
std::list< Camera > & | getAnimationPoints () |
void | setDefaultLighting (bool update_GL=true) |
void | initializePreferencesTab (Preferences &preferences) |
void | finalizePreferencesTab (Preferences &preferences) |
GLRenderer & | getGLRenderer () |
void | setGLRenderer (GLRenderer &renderer) |
float | getMousePositionX () |
float | getMousePositionY () |
bool | exportPNG (const String &filename) |
virtual void | setWidgetVisible (bool state) |
void | setOffScreenRendering (bool enabled, Size factor) |
virtual void | paintEvent (QPaintEvent *e) |
virtual bool | eventFilter (QObject *object, QEvent *event) |
ModeType | getMode () const |
virtual void | projectionModeChanged () |
void | rotate (float degree_right, float degree_up) |
void | rotateClockwise (float degree) |
void | move (Vector3 v) |
void | moveComposites (const std::list< Composite * > &composites, Vector3 v) |
void | rotateComposites (const std::list< Composite * > &composites, float degree_right, float degree_up, float degree_clockwise=0) |
bool | isAnimationRunning () const |
void | setTurnPoint (const Vector3 &v) |
const Vector3 & | getTurnPoint () const |
void | setFullScreen (bool state) |
void | setFPSEnabled (bool state) |
void | showText (const String &text, Size font_size=20) |
bool | isUpdateRunning () const |
void | resetTracking () |
bool | inMoveMode () const |
Position | prepareGridTextures (const RegularData3D &grid, const ColorMap &map) |
void | updateGL () |
Public Member Functions inherited from BALL::VIEW::ModularWidget | |
void | setWorkingDirFromFilename_ (String filename) |
virtual void | showHelp (const String &url) |
ModularWidget (const char *name="<ModularWidget>") | |
ModularWidget (const ModularWidget &widget) | |
virtual | ~ModularWidget () |
virtual void | destroy () |
QAction * | insertMenuEntry (Position parent_id, const String &name, const QObject *receiver=0, const char *slot=0, const String &description="", QKeySequence accel=QKeySequence()) |
void | setMenuHint (const String &hint) |
void | setMenuHelp (const String &url) |
virtual void | registerForHelpSystem (const QObject *object, const String &url) |
void | setIcon (const String &filename, bool add_to_main_toolbar=true) |
bool | lockComposites () |
bool | unlockComposites () |
Unlock the Composites. More... | |
MainControl * | getMainControl () const |
virtual void | setStatusbarText (const String &text, bool important=false) |
virtual void | setStatusbarText (const QString &text, bool important=false) |
More... | |
String | getWorkingDir () |
Implemented for convenience. More... | |
void | setWorkingDir (const String &dir) |
Implemented for convenience. More... | |
FragmentDB & | getFragmentDB () const |
virtual void | finalizeWidget (MainControl &main_control) |
virtual bool | canHandle (const String &) const |
virtual bool | openFile (const String &) |
Public Member Functions inherited from BALL::Embeddable | |
Embeddable (const String &identifier="<Embeddable>") | |
Embeddable (const Embeddable &embeddable) | |
virtual | ~Embeddable () |
void | setIdentifier (const String &identifier) |
const String & | getIdentifier () const |
void | unregisterThis () |
virtual void | registerThis () |
Public Member Functions inherited from BALL::VIEW::ConnectionObject | |
ConnectionObject () | |
virtual | ~ConnectionObject () |
void | registerConnectionObject (ConnectionObject &object) |
void | unregisterConnectionObject (ConnectionObject &object) |
bool | isConnectionObjectRegistered (const ConnectionObject &object) |
ConnectionObject * | getParent () const |
ConnectionObject * | getRoot () |
Protected Slots | |
virtual void | editMode_ () |
void | deleteAtom_ () |
void | changeElement_ () |
void | changeAtomElement_ () |
void | createBond_ () |
void | deleteBond_ () |
void | changeBondOrder_ () |
void | activatedOrderItem_ (QAction *action) |
void | moveAtom_ () |
void | atomProperties_ () |
void | createMolecule_ () |
void | addStructure_ () |
void | setFormalCharge_ () |
Protected Slots inherited from BALL::VIEW::Scene | |
virtual void | rotateMode_ () |
virtual void | pickingMode_ () |
virtual void | moveMode_ () |
virtual void | showViewPoint_ () |
Show the viewpoint and the look at point in the statusline of the mainwidget. More... | |
virtual void | setViewPoint_ () |
Set the viewpoint. More... | |
virtual void | resetCamera_ () |
Reset the camera to standard values. More... | |
virtual void | resetRepresentationsForRenderer_ (RenderSetup &rs) |
virtual void | dropEvent (QDropEvent *e) |
virtual void | dragEnterEvent (QDragEnterEvent *e) |
void | dummySlot () |
Static Protected Attributes | |
static bool | only_highlighted_ |
Static Protected Attributes inherited from BALL::VIEW::Scene | |
static float | mouse_sensitivity_ |
static float | mouse_wheel_sensitivity_ |
static bool | show_light_sources_ |
static float | animation_smoothness_ |
static Position | screenshot_nr_ |
static Position | pov_nr_ |
static Position | vrml_nr_ |
static bool | offscreen_rendering_ |
Additional Inherited Members | |
Static Public Member Functions inherited from BALL::VIEW::Scene | |
static void | setAnimationSmoothness (float value) |
static float | getAnimationSmoothness () |
static void | setMouseSensitivity (float sensitivity) |
static float | getMouseSensitivity () |
static void | setMouseWheelSensitivity (float sensitivity) |
static float | getMouseWheelSensitivity () |
static void | setShowLightSources (bool state) |
static bool | showLightSourcesEnabled () |
static bool | stereoBufferSupportTest () |
static void | setScreenShotNumber (Position pos) |
static void | setPOVNumber (Position pos) |
static void | setVRMLNumber (Position pos) |
Static Public Member Functions inherited from BALL::VIEW::ModularWidget | |
static void | registerWidget (ModularWidget *mwidget) throw (Exception::NullPointer) |
Static Protected Member Functions inherited from BALL::Embeddable | |
static void | registerInstance_ (const std::type_info &type, const Embeddable *instance) |
static void | unregisterInstance_ (const Embeddable *instance) |
static Size | countInstances_ (const std::type_info &type) |
static Embeddable * | getInstance_ (const std::type_info &type, Position index) |
static Embeddable * | getInstance_ (const std::type_info &type, const String &identifier) |
Extended 3D view for editing molecules. The editing functionality is implemented as an own mode.
Definition at line 42 of file editableScene.h.
Enumerator | |
---|---|
EDIT__MODE |
Definition at line 89 of file editableScene.h.
BALL::VIEW::EditableScene::EditableScene | ( | ) |
BALL::VIEW::EditableScene::EditableScene | ( | QWidget * | parent_widget, |
const char * | name = NULL , |
||
Qt::WFlags | w_flags = 0 |
||
) |
Default Constructor.
BALL::VIEW::EditableScene::EditableScene | ( | const EditableScene & | eScene, |
QWidget * | parent_widget = NULL , |
||
const char * | name = NULL , |
||
Qt::WFlags | wflags = 0 |
||
) |
Copy constructor.
|
virtual |
Destructor.
|
protectedslot |
void BALL::VIEW::EditableScene::addStructure | ( | String | name | ) |
|
protectedslot |
|
protectedvirtual |
Add the widgets actions to the (main) toolbar. This method is needed to enable ordering the entries. It is called in Mainframe.
Reimplemented from BALL::VIEW::Scene.
|
virtual |
Apply the preferences of the specific tab. In this method the widget can extract any changed values from its preferences tab (if required). This method is called automatically by the applyPreferencesTab from the MainControl object if the apply button in the Preferences dialog is pressed.
preferences | the Preferences dialog of the MainControl |
Reimplemented from BALL::VIEW::Scene.
|
protectedslot |
|
protectedslot |
|
protectedslot |
|
protected |
|
protectedslot |
|
virtual |
Menu checking method. This method is called by MainControl::checkMenus before a popup menu is shown. The menus rotate mode and picking mode each will be checked if this scene is in the corresponding mode.
main_control | the MainControl object whose menus should be checked |
Reimplemented from BALL::VIEW::Scene.
|
slot |
|
protectedslot |
|
protectedslot |
|
slot |
|
protectedslot |
|
protectedslot |
|
protected |
|
protectedvirtualslot |
|
virtual |
Remove the preferences tab. This method can remove a preferences widget (if created in initializePreferencesTab) from the Preferences dialog of the MainControl. This method is called automatically by MainControl::aboutToExit() at the end of the application.
preferences | the Preferences dialog of the MainControl |
Reimplemented from BALL::VIEW::ModularWidget.
|
protected |
|
protected |
|
slot |
Given a 3-dim. Coordinates (in Viewing Volume) getScreenPosition computes the 2-dim Coordinates on Screen.
|
protected |
|
virtual |
Initialize a preferences tab for the widget (if needed). This method can be used to create preferences widgets that can be inserted into the Preferences dialog with the method insertTab. This method is called automatically by MainControl::show at the start of the application.
preferences | the Preferences dialog of the MainControl |
Reimplemented from BALL::VIEW::ModularWidget.
|
virtual |
ModularWidget methods.Initialize the popup menu Display and the menus of this scene:
main_control | the MainControl object to be initialized with this scene |
Reimplemented from BALL::VIEW::Scene.
|
protected |
|
protectedvirtual |
Catch key events.
Reimplemented from BALL::VIEW::Scene.
|
protectedvirtual |
Reimplemented from BALL::VIEW::Scene.
|
virtualslot |
|
virtualslot |
|
virtualslot |
|
protectedslot |
|
signal |
|
protectedvirtual |
Handles messages sent by other registered ConnectionObject objects. Filters for SceneMessage and sets the Camera appropriate or updates the visualization.
message | the pointer to the message that should be processed |
Reimplemented from BALL::VIEW::Scene.
|
slot |
|
protectedvirtual |
|
protected |
|
slot |
void BALL::VIEW::EditableScene::setCursor | ( | String | c | ) |
|
slot |
void BALL::VIEW::EditableScene::setElementCursor | ( | ) |
|
protectedslot |
|
virtual |
Reimplemented from BALL::VIEW::Scene.
void BALL::VIEW::EditableScene::showContextMenu | ( | QPoint | pos | ) |
|
virtualslot |
|
protected |
Definition at line 214 of file editableScene.h.
|
protected |
Definition at line 227 of file editableScene.h.
|
protected |
Definition at line 220 of file editableScene.h.
|
protected |
Definition at line 225 of file editableScene.h.
|
protected |
Definition at line 215 of file editableScene.h.
|
protected |
Definition at line 229 of file editableScene.h.
|
protected |
Definition at line 215 of file editableScene.h.
|
protected |
Definition at line 217 of file editableScene.h.
|
protected |
Definition at line 218 of file editableScene.h.
|
protected |
Definition at line 214 of file editableScene.h.
|
protected |
Definition at line 235 of file editableScene.h.
|
protected |
Definition at line 214 of file editableScene.h.
|
protected |
Definition at line 237 of file editableScene.h.
|
protected |
Definition at line 238 of file editableScene.h.
|
protected |
Definition at line 231 of file editableScene.h.
|
protected |
Definition at line 230 of file editableScene.h.
|
protected |
Definition at line 236 of file editableScene.h.
|
protected |
Definition at line 214 of file editableScene.h.
|
staticprotected |
Definition at line 223 of file editableScene.h.
|
protected |
Definition at line 214 of file editableScene.h.
|
protected |
Definition at line 239 of file editableScene.h.
|
protected |
Definition at line 241 of file editableScene.h.
|
protected |
Definition at line 240 of file editableScene.h.
|
protected |
Definition at line 234 of file editableScene.h.