Panda3D
Public Types | Public Member Functions | List of all members
WinStatsGraph Class Reference

This is just an abstract base class to provide a common pointer type for the various kinds of graphs that may be created for a WinStatsMonitor. More...

#include "winStatsGraph.h"

Inheritance diagram for WinStatsGraph:
WinStatsPianoRoll WinStatsStripChart

Public Types

enum  DragMode {
  DM_none, DM_scale, DM_left_margin, DM_right_margin,
  DM_guide_bar, DM_new_guide_bar, DM_sizing
}
 

Public Member Functions

 WinStatsGraph (WinStatsMonitor *monitor)
 
virtual void changed_graph_size (int graph_xsize, int graph_ysize)
 Called when the user has resized the window, forcing a resize of the graph. More...
 
virtual void clicked_label (int collector_index)
 Called when the user single-clicks on a label. More...
 
virtual void force_redraw ()
 Called when it is necessary to redraw the entire graph. More...
 
virtual void new_collector (int collector_index)
 Called whenever a new Collector definition is received from the client. More...
 
virtual void new_data (int thread_index, int frame_number)
 Called whenever new data arrives. More...
 
void set_pause (bool pause)
 Changes the pause flag for the graph. More...
 
virtual void set_scroll_speed (double scroll_speed)
 Called when the user selects a new scroll speed from the monitor pulldown menu, this should adjust the speed for the graph to the indicated value. More...
 
virtual void set_time_units (int unit_mask)
 Called when the user selects a new time units from the monitor pulldown menu, this should adjust the units for the graph to the indicated mask if it is a time-based graph. More...
 
void user_guide_bars_changed ()
 Called when the user guide bars have been changed. More...
 

Detailed Description

This is just an abstract base class to provide a common pointer type for the various kinds of graphs that may be created for a WinStatsMonitor.

Definition at line 29 of file winStatsGraph.h.

Member Function Documentation

◆ changed_graph_size()

void WinStatsGraph::changed_graph_size ( int  graph_xsize,
int  graph_ysize 
)
virtual

Called when the user has resized the window, forcing a resize of the graph.

Reimplemented in WinStatsStripChart, and WinStatsPianoRoll.

Definition at line 111 of file winStatsGraph.cxx.

◆ clicked_label()

void WinStatsGraph::clicked_label ( int  collector_index)
virtual

Called when the user single-clicks on a label.

Reimplemented in WinStatsStripChart, and WinStatsPianoRoll.

Definition at line 153 of file winStatsGraph.cxx.

◆ force_redraw()

void WinStatsGraph::force_redraw ( )
virtual

Called when it is necessary to redraw the entire graph.

Reimplemented in WinStatsStripChart, and WinStatsPianoRoll.

Definition at line 104 of file winStatsGraph.cxx.

◆ new_collector()

void WinStatsGraph::new_collector ( int  collector_index)
virtual

Called whenever a new Collector definition is received from the client.

Reimplemented in WinStatsStripChart.

Definition at line 90 of file winStatsGraph.cxx.

Referenced by WinStatsStripChart::new_collector(), and WinStatsMonitor::new_collector().

◆ new_data()

void WinStatsGraph::new_data ( int  thread_index,
int  frame_number 
)
virtual

Called whenever new data arrives.

Reimplemented in WinStatsStripChart, and WinStatsPianoRoll.

Definition at line 97 of file winStatsGraph.cxx.

Referenced by WinStatsMonitor::new_data().

◆ set_pause()

void WinStatsGraph::set_pause ( bool  pause)

Changes the pause flag for the graph.

When this flag is true, the graph does not update in response to new data.

Definition at line 136 of file winStatsGraph.cxx.

Referenced by WinStatsMonitor::open_piano_roll(), WinStatsMonitor::open_strip_chart(), and WinStatsMonitor::set_pause().

◆ set_scroll_speed()

void WinStatsGraph::set_scroll_speed ( double  scroll_speed)
virtual

Called when the user selects a new scroll speed from the monitor pulldown menu, this should adjust the speed for the graph to the indicated value.

Reimplemented in WinStatsStripChart.

Definition at line 128 of file winStatsGraph.cxx.

Referenced by WinStatsMonitor::open_piano_roll(), and WinStatsMonitor::set_scroll_speed().

◆ set_time_units()

void WinStatsGraph::set_time_units ( int  unit_mask)
virtual

Called when the user selects a new time units from the monitor pulldown menu, this should adjust the units for the graph to the indicated mask if it is a time-based graph.

Reimplemented in WinStatsStripChart, and WinStatsPianoRoll.

Definition at line 120 of file winStatsGraph.cxx.

Referenced by WinStatsMonitor::set_time_units().

◆ user_guide_bars_changed()

void WinStatsGraph::user_guide_bars_changed ( )

Called when the user guide bars have been changed.

Definition at line 144 of file winStatsGraph.cxx.

Referenced by WinStatsMonitor::user_guide_bars_changed().


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