InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ISelectionFilter Class Referenceabstract

#include <ISelectionFilter.h>

Inheritance diagram for ISelectionFilter:
IPMUnknown

Public Member Functions

virtual void FilterSelection (UIDList &itemsToSelect, Selection::Action &replaceOrAdd, UIDList &currentSelection, IConcreteSelection *concreteSelection)=0
 
virtual void FilterDeselect (UIDList &itemsToSelect, UIDList &currentSelection, IConcreteSelection *concreteSelection)=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

Defines the interface for a selection filter. Used so plugins can put restrictions (filters) on what gets selected.

Typical use case is inlines, where only one can be selected, or guides, which aren't selected at same time as regular page items.

The selection filters are called whenever the selection changes (inside SelectUtils). Everyone should be using these selection utilities to do selection.

Member Function Documentation

virtual void ISelectionFilter::FilterDeselect (UIDListitemsToSelect,
UIDListcurrentSelection,
IConcreteSelectionconcreteSelection 
)
pure virtual

This is the filter used from SelectUtils::DeselectPageItems(). For example StandOffSelectionFilter deselects standoff pageitems if the main item gets deselected.

Parameters
itemsToSelectUIDList
currentSelectioncurrent Selection
concreteSelectionis the selection boss.
virtual void ISelectionFilter::FilterSelection (UIDListitemsToSelect,
Selection::Action & replaceOrAdd,
UIDListcurrentSelection,
IConcreteSelectionconcreteSelection 
)
pure virtual

Can change the list of items to select and whether to replace or add the list to the existing selection. This filter is used on all selection types except for Marquee and select all

Parameters
itemsToSelectUIDList
replaceOrAddSelection action
currentSelectioncurrent Selection
concreteSelectionis the selection boss.