ofxMUI
A Multi-touch GUI implementation built with ofxDOM for openFrameworks.
ofx::MUI::Scope< DataType > Class Template Reference

A simple data plotter. More...

#include <Scope.h>

Inheritance diagram for ofx::MUI::Scope< DataType >:
ofx::MUI::Widget

Public Member Functions

 Scope (float x, float y, float width, float height)
 
 Scope (const std::string &id, float x, float y, float width, float height, std::size_t maxSize)
 
void onDraw () const override
 
void setMaxSize (std::size_t maxSize)
 
std::size_t getMaxSize () const
 
void setColor (const std::string &series, const ofColor &color)
 
void add (const std::string &series, const DataType &value)
 
void removeSeries (const std::string &series)
 
void clear ()
 
- Public Member Functions inherited from ofx::MUI::Widget
 Widget (float x, float y, float width, float height)
 
 Widget (const std::string &id, float x, float y, float width, float height)
 
virtual ~Widget ()
 Destroy this Widget.
 
bool isPointerOver () const
 
bool isPointerDown () const
 
void setDropTarget (bool dropTarget)
 Enable or disable the Widget as a drop target. More...
 
bool isDropTarget () const
 Determine if this Widget is a drop target. More...
 
void setDraggable (bool draggable)
 Set draggability for this Widget. More...
 
bool isDraggable () const
 Determine if draggability is enabled for this Widget. More...
 
bool isDragging () const
 Determine if this Widget is being dragged. More...
 
std::shared_ptr< StylesgetStyles () const
 Get the Styles for this Widget. More...
 
void setStyles (std::shared_ptr< Styles > styles)
 Set the Styles for this Widget. More...
 

Public Attributes

Axis< DataType > axes [2]
 

Protected Types

typedef std::deque< DataType > Buffer
 

Protected Attributes

std::size_t _maxSize
 The maximum number of data points to buffer.
 
std::unordered_map< std::string, std::pair< Buffer, ofColor > > _data
 A collection of data.
 
- Protected Attributes inherited from ofx::MUI::Widget
bool _isDropTarget = false
 True iff the Widget is a target for dragged Widgets.
 
bool _isDraggable = false
 True iff the Widget is configured to be dragged.
 
bool _isDragging = false
 True iff the widget is currently being dragged.
 
bool _isPointerOver = false
 True iff the pointer is over the widget.
 
bool _moveToFrontOnCapture = true
 True if the element should move to the fron upon pointer capture.
 

Additional Inherited Members

- Protected Member Functions inherited from ofx::MUI::Widget
void _onPointerEvent (DOM::PointerUIEventArgs &e)
 Default callback for built-in events, including dragging.
 
void _onPointerCaptureEvent (DOM::PointerCaptureUIEventArgs &e)
 Default callback for built-in events, including dragging.
 

Detailed Description

template<typename DataType>
class ofx::MUI::Scope< DataType >

A simple data plotter.


The documentation for this class was generated from the following file: