00001 //--- < FINDDRAWABLE.H > --------| ViewGraph - A Flexible Graph view Framework | 00002 // 00003 // This class provides the algorithm to find the 00004 // objects that fit the viewport. This class assumes 00005 // all objects passed to it are visible at the 00006 // current magnification level. 00007 // 00008 // Below is the default finder class, feel free to 00009 // roll your own for things like caching etc. 00010 // 00011 // $Author: botik32 $ 00012 // $Revision: 1.1.1.1 $ 00013 // $Date: 2004/03/26 10:50:21 $ 00014 //-----------------------------------------------------------------------------/ 00015 00016 #ifndef FINDDRAWABLE_H 00017 #define FINDDRAWABLE_H 00018 00019 // The simplest, dumb finder. This class 00020 // takes every node in the passed list and tries it 00021 // against the canvas. 00022 template<class VC, class NL> class DefaultFindDrawable 00023 { 00024 private: 00025 // View provides us with the rectfit() function we need 00026 // in order to decide on drawability 00027 VC *view; 00028 public: 00029 // the view has all the necessary parameters such as viewport 00030 // magnification and offset 00031 NL* find_drawable( NL *candidates ); 00032 DefaultFindDrawable( VC * ); 00033 }; 00034 00035 #endif 00036 00037 /// $Log: finddrawable.h,v $ 00038 /// Revision 1.1.1.1 2004/03/26 10:50:21 botik32 00039 /// Initial release 00040 /// 00041 /// Revision 1.1.1.1 2004/03/26 08:53:33 botik 00042 /// initial import 00043 /// 00044 /// 00045 /// Revision 1.1 2003/10/15 13:00:42 botik 00046 /// Added finddrawable class. Modified objectdisplay.h to 00047 /// fit the changes. 00048 ///