1 /* 2 * highlt.h 3 * AYM 1998-09-20 4 */ 5 6 7 /* 8 This file is part of Yadex. 9 10 Yadex incorporates code from DEU 5.21 that was put in the public domain in 11 1994 by Rapha�l Quinet and Brendon Wyber. 12 13 The rest of Yadex is Copyright � 1997-2003 Andr� Majorel and others. 14 15 This program is free software; you can redistribute it and/or modify it under 16 the terms of the GNU General Public License as published by the Free Software 17 Foundation; either version 2 of the License, or (at your option) any later 18 version. 19 20 This program is distributed in the hope that it will be useful, but WITHOUT 21 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 22 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. 23 24 You should have received a copy of the GNU General Public License along with 25 this program; if not, write to the Free Software Foundation, Inc., 59 Temple 26 Place, Suite 330, Boston, MA 02111-1307, USA. 27 */ 28 29 30 #include "edwidget.h" 31 #include "objid.h" 32 33 34 class highlight_c : public edwidget_c 35 { 36 public : 37 highlight_c (void); set(Objid & obj)38 void set (Objid& obj) { this->obj = obj; } 39 40 /* Methods declared in edwidget */ unset()41 void unset () { obj.nil (); } 42 void draw (); 43 void undraw (); can_undraw()44 int can_undraw () { return 1; } // I have the ability to undraw myself. need_to_clear()45 int need_to_clear () { return 0; } // I know how to undraw myself. clear()46 void clear () { obj_disp.nil (); } 47 48 private : 49 Objid obj; // The object we should highlight 50 Objid obj_disp; // The object that is really highlighted 51 }; 52 53