Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:02:55

0001 // Created by: Ilya SEVRIKOV
0002 // Copyright (c) 2016 OPEN CASCADE SAS
0003 //
0004 // This file is part of Open CASCADE Technology software library.
0005 //
0006 // This library is free software; you can redistribute it and/or modify it under
0007 // the terms of the GNU Lesser General Public License version 2.1 as published
0008 // by the Free Software Foundation, with special exception defined in the file
0009 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0010 // distribution for complete text of the license and disclaimer of any warranty.
0011 //
0012 // Alternatively, this file may be used under the terms of Open CASCADE
0013 // commercial license or contractual agreement.
0014 
0015 #ifndef _AIS_TrihedronOwner_HeaderFile
0016 #define _AIS_TrihedronOwner_HeaderFile
0017 
0018 #include <SelectMgr_EntityOwner.hxx>
0019 #include <SelectMgr_SelectableObject.hxx>
0020 #include <Prs3d_DatumParts.hxx>
0021 
0022 //! Entity owner for selection management of AIS_Trihedron object.
0023 class AIS_TrihedronOwner : public SelectMgr_EntityOwner
0024 {
0025   DEFINE_STANDARD_RTTIEXT(AIS_TrihedronOwner, SelectMgr_EntityOwner)
0026 public:
0027 
0028   //! Creates an owner of AIS_Trihedron object.
0029   Standard_EXPORT AIS_TrihedronOwner (const Handle(SelectMgr_SelectableObject)& theSelObject,
0030                                       const Prs3d_DatumParts theDatumPart,
0031                                       const Standard_Integer thePriority);
0032 
0033   //! Returns the datum part identifier.
0034   Prs3d_DatumParts DatumPart() const { return myDatumPart; }
0035 
0036   //! Highlights selectable object's presentation.
0037   Standard_EXPORT virtual void HilightWithColor (const Handle(PrsMgr_PresentationManager)& thePM,
0038                                                  const Handle(Prs3d_Drawer)& theStyle,
0039                                                  const Standard_Integer theMode) Standard_OVERRIDE;
0040 
0041   //! Returns true if the presentation manager thePM
0042   //! highlights selections corresponding to the selection mode aMode.
0043   Standard_EXPORT Standard_Boolean IsHilighted (const Handle(PrsMgr_PresentationManager)& thePM,
0044                                                 const Standard_Integer theMode) const Standard_OVERRIDE;
0045 
0046   //! Removes highlighting from the owner of a detected
0047   //! selectable object in the presentation manager thePM.
0048   Standard_EXPORT virtual void Unhilight (const Handle(PrsMgr_PresentationManager)& thePM,
0049                                           const Standard_Integer theMode) Standard_OVERRIDE;
0050 
0051 protected:
0052   Prs3d_DatumParts myDatumPart; //!< part of datum selected
0053 };
0054 
0055 DEFINE_STANDARD_HANDLE (AIS_TrihedronOwner, SelectMgr_EntityOwner)
0056 
0057 #endif // _AIS_TrihedronOwner_HeaderFile