/usr/include/BALL/VIEW/WIDGETS/SDWidget.h is in libballview1.4-dev 1.4.3~beta1-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 99 100 101 102 103 104 105 106 107 | #ifndef BALL_VIEW_WIDGETS_SDWIDGET_H
#define BALL_VIEW_WIDGETS_SDWIDGET_H
#ifndef BALL_COMMON_GLOBAL_H
# include <BALL/COMMON/global.h>
#endif
#ifndef BALL_DATATYPE_OPTIONS_H
# include <BALL/DATATYPE/options.h>
#endif
#include <BALL/KERNEL/system.h>
#include <QtGui/QWidget>
namespace BALL
{
namespace VIEW
{
///
class BALL_VIEW_EXPORT SDWidget
: public QWidget
{
Q_OBJECT
public:
/** @name Constant Definitions
*/
//@{
/// Option names
struct BALL_VIEW_EXPORT Option
{
/** show hydrogen atoms.
*/
static const char* SHOW_HYDROGENS;
};
/// Default values for options
struct BALL_VIEW_EXPORT Default
{
static const bool SHOW_HYDROGENS;
};
//@}
///
SDWidget(QWidget *parent = 0, bool show_hydrogens = false);
///
SDWidget(const System& system, QWidget *parent = 0);
///
virtual ~SDWidget();
/** @name Public Attributes
*/
//@{
/// options
Options options;
/** Resets the options to default values.
*/
void setDefaultOptions();
//@}
///
void plot(const System& system, bool create_sd = true);
///
System& getSystem() {return system_;};
///
const System& getSystem() const {return system_;};
///
void setSystem(const System& system) {system_ = system;};
///
void clear();
QSize sizeHint() const;
protected slots:
void exportImage_();
protected:
void setup_();
void paintEvent(QPaintEvent *event);
void renderSD_(QPaintDevice* paint_device);
void drawFrame_();
QPointF getEndpoint_(QRectF& character_boundary, QPointF from, QPointF to, bool character_is_from);
System system_;
bool resize_to_parent_;
Vector3 upper_;
Vector3 lower_;
};
}
}
#endif
|