casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Profile2dDM.h
Go to the documentation of this file.
00001 //# Profile2dDM.h: Drawing Method for 2d Profile DisplayDatas
00002 //# Copyright (C) 2003
00003 //# Associated Universities, Inc. Washington DC, USA.
00004 //#
00005 //# This library is free software; you can redistribute it and/or modify it
00006 //# under the terms of the GNU Library General Public License as published by
00007 //# the Free Software Foundation; either version 2 of the License, or (at your
00008 //# option) any later version.
00009 //#
00010 //# This library is distributed in the hope that it will be useful, but WITHOUT
00011 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00012 //# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
00013 //# License for more details.
00014 //#
00015 //# You should have received a copy of the GNU Library General Public License
00016 //# along with this library; if not, write to the Free Software Foundation,
00017 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
00018 //#
00019 //# Correspondence concerning AIPS++ should be addressed as follows:
00020 //#        Internet email: aips2-request@nrao.edu.
00021 //#        Postal address: AIPS++ Project Office
00022 //#                        National Radio Astronomy Observatory
00023 //#                        520 Edgemont Road
00024 //#                        Charlottesville, VA 22903-2475 USA
00025 //#
00026 //# $Id$
00027 
00028 #ifndef TRIALDISPLAY_PROFILE2DDM_H
00029 #define TRIALDISPLAY_PROFILE2DDM_H
00030 
00031 #include <casa/aips.h>
00032 #include <display/Display/DisplayEnums.h>
00033 #include <display/Display/WorldCanvasHolder.h>
00034 #include <display/DisplayDatas/CachingDisplayMethod.h>
00035 #include <display/DisplayDatas/Profile2dDD.h>
00036 namespace casa { //# NAMESPACE CASA - BEGIN
00037 
00038 // <summary> 
00039 // A DisplayMethod to draw Profiles
00040 // </summary>
00041 //
00042 // <use visibility=export>
00043 // 
00044 // <reviewed reviewer="" date="yyyy/mm/dd" tests="" demos="">
00045 // </reviewed>
00046 // 
00047 // <prerequisite>
00048 //   <li> DisplayMethod
00049 //   <li> CachingDisplayMethod
00050 // </prerequisite>
00051 //
00052 // <etymology>
00053 // </etymology>
00054 // <synopsis> 
00055 // 
00056 // </synopsis> 
00057 
00058 class Profile2dDM : public CachingDisplayMethod {
00059 
00060   public:
00061 
00062   // Constructor.
00063   Profile2dDM(WorldCanvas *worldCanvas, 
00064                 AttributeBuffer *wchAttributes,
00065                 AttributeBuffer *ddAttributes,
00066                 CachingDisplayData *dd);
00067   
00068   // Destructor.
00069   virtual ~Profile2dDM();
00070   
00071   // Clean up (ie. delete any existing cached display list).
00072   virtual void cleanup();
00073   
00074   // Draw into a cached drawing list, called by draw function.
00075   virtual Bool drawIntoList(Display::RefreshReason reason,
00076                             WorldCanvasHolder &wcHolder);
00077   
00078   protected:
00079   
00080   // (Required) default constructor.
00081   Profile2dDM();
00082   
00083   // (Required) copy constructor.
00084   Profile2dDM(const Profile2dDM &other);
00085   
00086   // (Required) copy assignment.
00087   void operator=(const Profile2dDM &other);
00088   
00089   private:
00090   // <group>
00091   // Set the appropriate styes and rules for drawing the profile
00092   void setStyles(WorldCanvas *wc, Profile2dDD *parent);
00093   // Restore the appropriate styles and rules after drawing
00094   // is completed
00095   void restoreStyles(WorldCanvas *wc);
00096   // </group>
00097 };
00098 
00099 
00100 } //# NAMESPACE CASA - END
00101 
00102 #endif