#3788 Annotations. Mirror global annotations into view annotation collection. Not thorougly testet yet

This commit is contained in:
Bjørn Erik Jensen
2018-12-03 13:14:04 +01:00
parent 918efd3a27
commit 11e2fe29d4
33 changed files with 1605 additions and 104 deletions

View File

@@ -22,6 +22,7 @@
#include "RimGridView.h"
#include "RimProject.h"
#include "RimAnnotationCollection.h"
#include "RimAnnotationGroupCollection.h"
#include "AnnotationCommands/RicTextAnnotation3dEditor.h"
@@ -149,6 +150,20 @@ bool RimTextAnnotation::isActive()
return m_isActive();
}
//--------------------------------------------------------------------------------------------------
/// Returns true if annotation can be displayed due to all toggles that affect this annotation
//--------------------------------------------------------------------------------------------------
bool RimTextAnnotation::isVisible() const
{
RimAnnotationGroupCollection* coll;
firstAncestorOrThisOfType(coll);
bool visible = true;
if (coll) visible = coll->isVisible();
if(visible) visible = m_isActive;
return visible;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------