diva.compat.trace
Class TraceView

java.lang.Object
  extended by diva.compat.trace.TraceView

public class TraceView
extends Object

TraceView is the part of the TracePane widget which controls the display of trace elements.

Version:
$Revision: 1.11 $
Author:
John Reekie (johnr@eecs.berkeley.edu)

Constructor Summary
TraceView()
          Construct a trace view.
 
Method Summary
 void clear()
          Clear the view.
 void drawModel()
          Draw the current model into the view.
 void drawTrace(TraceModel.Trace trace)
          Draw a new trace on the view.
 void drawTraceElement(TraceModel.Element elt)
          Draw a new trace element
 GraphicsPane getGraphicsPane()
          Return the graphics pane of this controller.
 TraceController getTraceController()
          Return the trace controller.
 TraceModel getTraceModel()
          Return the trace model being viewed.
 void setLayout(double x, double y, double width, double height, double spacing)
          Set the layout parameters of the trace.
 void setTimeScale(double scale)
          Set the scaling factor from traces time to coordinates
 void setTraceController(TraceController c)
          Set the trace controller.
 void setTraceModel(TraceModel model)
          Set the trace model and display all of its data
 void setTracePane(TracePane pane)
          Set the trace pane.
 void updateTraceElement(TraceModel.Element elt)
          Update the display of an existing trace element
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TraceView

public TraceView()
Construct a trace view. The trace cannot be used until it has a pane set with setTracePane(), which is called when the view is added to the pane.

Method Detail

clear

public void clear()
Clear the view. This removes all information about the figure from the view and from the renderer. Note that the model must not be cleared until after this method is called!


drawModel

public void drawModel()
Draw the current model into the view. This method assumes that none of the data in the model has been drawn yet.


drawTrace

public void drawTrace(TraceModel.Trace trace)
Draw a new trace on the view.


drawTraceElement

public void drawTraceElement(TraceModel.Element elt)
Draw a new trace element


getTraceController

public TraceController getTraceController()
Return the trace controller.


getTraceModel

public TraceModel getTraceModel()
Return the trace model being viewed.


getGraphicsPane

public GraphicsPane getGraphicsPane()
Return the graphics pane of this controller.


setTraceController

public void setTraceController(TraceController c)
Set the trace controller.


setLayout

public void setLayout(double x,
                      double y,
                      double width,
                      double height,
                      double spacing)
Set the layout parameters of the trace. The coordinates define the rectangular region of the first trace in the view.


setTimeScale

public void setTimeScale(double scale)
Set the scaling factor from traces time to coordinates


setTraceModel

public void setTraceModel(TraceModel model)
Set the trace model and display all of its data


setTracePane

public final void setTracePane(TracePane pane)
Set the trace pane. This is called by the TracePane.


updateTraceElement

public void updateTraceElement(TraceModel.Element elt)
Update the display of an existing trace element



Copyright © 2015 Central Laboratory of the Research Councils. All Rights Reserved.