• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • kdeedu
  • Sitemap
  • Contact Us
 

kalzium

Avogadro::AutoRotateTool

Avogadro::AutoRotateTool Class Reference

#include <autorotatetool.h>

Inheritance diagram for Avogadro::AutoRotateTool:

Inheritance graph
[legend]

List of all members.


Detailed Description

Automatic molecule rotation.

Author:
Marcus D. Hanwell
This class handles the automatic rotation of the view so that the molecule can be shown in more detail.

Definition at line 52 of file autorotatetool.h.


Tool Methods

QPushButton * m_buttonStartStop
QPoint m_currentDraggingPosition
GLWidget * m_glwidget
bool m_leftButtonPressed
int m_maxRotation
bool m_midButtonPressed
QWidget * m_settingsWidget
QSlider * m_sliderX
QSlider * m_sliderY
QSlider * m_sliderZ
QPoint m_startDraggingPosition
int m_timerId
int m_xRotation
int m_yRotation
int m_zRotation
virtual QUndoCommand * mouseMove (GLWidget *, const QMouseEvent *)
virtual QUndoCommand * mousePress (GLWidget *, const QMouseEvent *)
virtual QUndoCommand * mouseRelease (GLWidget *, const QMouseEvent *)
virtual bool paint (GLWidget *widget)
virtual QWidget * settingsWidget ()
virtual int usefulness () const
virtual QUndoCommand * wheel (GLWidget *, const QWheelEvent *)
void disableTimer ()
void enableTimer ()
void resetRotations ()
void setXRotation (int i)
void setYRotation (int i)
void setZRotation (int i)
void toggleTimer ()
void resetRotation (int i)
void rotate () const
void timerEvent (QTimerEvent *event)

Public Member Functions

 AutoRotateTool (QObject *parent=0)
virtual ~AutoRotateTool ()
Description methods
virtual QString description () const
virtual QString name () const

Constructor & Destructor Documentation

Avogadro::AutoRotateTool::AutoRotateTool ( QObject *  parent = 0  ) 

Constructor.

Definition at line 45 of file autorotatetool.cpp.

Avogadro::AutoRotateTool::~AutoRotateTool (  )  [virtual]

Destructor.

Definition at line 55 of file autorotatetool.cpp.


Member Function Documentation

virtual QString Avogadro::AutoRotateTool::description (  )  const [inline, virtual]

Tool Description.

Reimplemented from Avogadro::Tool.

Definition at line 67 of file autorotatetool.h.

void Avogadro::AutoRotateTool::disableTimer (  )  [slot]

Definition at line 218 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::enableTimer (  )  [slot]

Definition at line 209 of file autorotatetool.cpp.

QUndoCommand * Avogadro::AutoRotateTool::mouseMove ( GLWidget *  widget,
const QMouseEvent *  event 
) [virtual]

Response to mouse movement.

Parameters:
widget the GLWidget where the even occurred
event the mouse event information

Implements Avogadro::Tool.

Definition at line 137 of file autorotatetool.cpp.

QUndoCommand * Avogadro::AutoRotateTool::mousePress ( GLWidget *  widget,
const QMouseEvent *  event 
) [virtual]

Callback methods for ui.actions on the canvas.

Implements Avogadro::Tool.

Definition at line 82 of file autorotatetool.cpp.

QUndoCommand * Avogadro::AutoRotateTool::mouseRelease ( GLWidget *  widget,
const QMouseEvent *  event 
) [virtual]

Response to mouse release.

Parameters:
widget the GLWidget where the even occurred
event the mouse event information

Implements Avogadro::Tool.

Definition at line 96 of file autorotatetool.cpp.

virtual QString Avogadro::AutoRotateTool::name (  )  const [inline, virtual]

Tool Name.

Implements Avogadro::Tool.

Definition at line 65 of file autorotatetool.h.

bool Avogadro::AutoRotateTool::paint ( GLWidget *  widget  )  [virtual]

Called by the GLWidget allowing overlay painting by the tool.

Tools get painted last in the overall scheme.

Parameters:
widget the GLWidget to paint to

Reimplemented from Avogadro::Tool.

Definition at line 150 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::resetRotation ( int  i  )  [signal]

void Avogadro::AutoRotateTool::resetRotations (  )  [slot]

Definition at line 228 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::rotate (  )  const [protected]

Definition at line 64 of file autorotatetool.cpp.

QWidget * Avogadro::AutoRotateTool::settingsWidget (  )  [virtual]

Returns:
the settings widget for the tool.

Reimplemented from Avogadro::Tool.

Definition at line 234 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::setXRotation ( int  i  )  [slot]

Definition at line 184 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::setYRotation ( int  i  )  [slot]

Definition at line 189 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::setZRotation ( int  i  )  [slot]

Definition at line 194 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::timerEvent ( QTimerEvent *  event  )  [protected]

Reimplemented from QObject.

Definition at line 173 of file autorotatetool.cpp.

void Avogadro::AutoRotateTool::toggleTimer (  )  [slot]

Definition at line 199 of file autorotatetool.cpp.

int Avogadro::AutoRotateTool::usefulness (  )  const [virtual]

Determines the ordering of the tools.

More useful tools are placed first. It is up to the tool designer to be humble about their usefulness value.

Returns:
usefulness value

Reimplemented from Avogadro::Tool.

Definition at line 59 of file autorotatetool.cpp.

virtual QUndoCommand* Avogadro::AutoRotateTool::wheel ( GLWidget *  widget,
const QWheelEvent *  event 
) [inline, virtual]

Response to mouse wheel movement.

Parameters:
widget the GLWidget where the even occurred
event the mouse wheel event information

Implements Avogadro::Tool.

Definition at line 78 of file autorotatetool.h.


Member Data Documentation

QPushButton* Avogadro::AutoRotateTool::m_buttonStartStop [protected]

Definition at line 114 of file autorotatetool.h.

QPoint Avogadro::AutoRotateTool::m_currentDraggingPosition [protected]

Definition at line 103 of file autorotatetool.h.

GLWidget* Avogadro::AutoRotateTool::m_glwidget [protected]

Definition at line 99 of file autorotatetool.h.

bool Avogadro::AutoRotateTool::m_leftButtonPressed [protected]

Definition at line 100 of file autorotatetool.h.

int Avogadro::AutoRotateTool::m_maxRotation [protected]

Definition at line 108 of file autorotatetool.h.

bool Avogadro::AutoRotateTool::m_midButtonPressed [protected]

Definition at line 101 of file autorotatetool.h.

QWidget* Avogadro::AutoRotateTool::m_settingsWidget [protected]

Definition at line 113 of file autorotatetool.h.

QSlider* Avogadro::AutoRotateTool::m_sliderX [protected]

Definition at line 115 of file autorotatetool.h.

QSlider* Avogadro::AutoRotateTool::m_sliderY [protected]

Definition at line 116 of file autorotatetool.h.

QSlider* Avogadro::AutoRotateTool::m_sliderZ [protected]

Definition at line 117 of file autorotatetool.h.

QPoint Avogadro::AutoRotateTool::m_startDraggingPosition [protected]

Definition at line 102 of file autorotatetool.h.

int Avogadro::AutoRotateTool::m_timerId [protected]

Definition at line 104 of file autorotatetool.h.

int Avogadro::AutoRotateTool::m_xRotation [protected]

Definition at line 105 of file autorotatetool.h.

int Avogadro::AutoRotateTool::m_yRotation [protected]

Definition at line 106 of file autorotatetool.h.

int Avogadro::AutoRotateTool::m_zRotation [protected]

Definition at line 107 of file autorotatetool.h.


The documentation for this class was generated from the following files:
  • autorotatetool.h
  • autorotatetool.cpp

kalzium

Skip menu "kalzium"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdeedu

Skip menu "kdeedu"
  • kalzium
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  •   docs
  •   src
  • parley
  •   stepcore
Generated for kdeedu by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal