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

#include <IRefPointUIUtils.h>

Inheritance diagram for IRefPointUIUtils:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IREFPOINTUIUTILS }
 

Public Member Functions

virtual IReferencePointDataQueryRefPointData (ILayoutControlData *layoutData)=0
 
virtual void ShowReferencePoint (ILayoutControlData *layoutData)=0
 
virtual void HideReferencePoint (ILayoutControlData *layoutData)=0
 
virtual void InvalidateReferencePoint (ILayoutControlData *layoutData, bool16 forceInval=kFalse)=0
 
virtual bool16 IsReferencePointShown (ILayoutControlData *layoutData)=0
 
virtual bool16 IsReferencePointLocked (ILayoutControlData *layoutData)=0
 
virtual void LockReferencePoint (ILayoutControlData *layoutData)=0
 
virtual void UnlockReferencePoint (ILayoutControlData *layoutData)=0
 
virtual void SetReferencePointVisible (ILayoutControlData *layoutData)=0
 
virtual void SetReferencePointInvisible (ILayoutControlData *layoutData)=0
 
virtual bool16 IsReferencePointVisible (ILayoutControlData *layoutData)=0
 
virtual ErrorCode ChangeReferencePoint (ILayoutControlData *layoutData, IReferencePointData::ReferencePointPosition newPosition, const PMPoint &newPoint, const PBPMRect &referenceFrame=kZeroRect)=0
 
virtual ErrorCode ChangeReferencePoint (ILayoutControlData *layoutData, IReferencePointData::ReferencePointPosition newPosition, const UIDList &items)=0
 
virtual void SetReferencePositionAndPoint (ILayoutControlData *layoutData, IReferencePointData::ReferencePointPosition position, const PBPMPoint &point)=0
 
virtual PBPMPoint GetPasteboardReferencePoint (ILayoutControlData *layoutData)=0
 
virtual bool16 PointInActiveReferencePoint (ILayoutControlData *layoutData, const PBPMPoint &point)=0
 
virtual bool16 WindowPointInActiveReferencePoint (ILayoutControlData *layoutData, const PMPoint &point)=0
 
virtual void SetDefaultState (ILayoutControlData *layoutData)=0
 
virtual void SetDefaultPosition (ILayoutControlData *layoutData)=0
 
virtual void SetReferencePointOffset (ILayoutControlData *layoutData, const PBPMPoint &offset)=0
 
virtual PBPMPoint GetReferencePointOffset (ILayoutControlData *layoutData)=0
 
virtual void SetReferenceFrame (ILayoutControlData *layoutData, const PBPMRect &referenceFrame)=0
 
virtual PBPMRect GetReferenceFrame (ILayoutControlData *layoutData)=0
 
virtual Transform::TransformOrigin GetReferencePointTransformOrigin (ILayoutControlData *layoutData)=0
 
virtual
IReferencePointData::ReferencePointPosition 
GetReferencePointPosition (ILayoutControlData *layoutData)=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

Utility interface for dealing with the reference point. Each layout view has its own reference point, which is indicated in the Transform Panel/Control Panel as a nine-point proxy. The reference point has several components: a pasteboard coordinate, and a position (see .h for ReferencePointPosition enum). The reference point is used for displaying information in the transform panel for selected page item coordinates, and as a reference point for certain commands (such as rotation, which is done around a reference point).

See Also
IRefPointUtils.h
ReferencePointPosition

Member Function Documentation

virtual ErrorCode IRefPointUIUtils::ChangeReferencePoint (ILayoutControlDatalayoutData,
IReferencePointData::ReferencePointPosition newPosition,
const PMPointnewPoint,
const PBPMRectreferenceFrame = kZeroRect 
)
pure virtual

Change the reference point for the layout view to the new values. Helper interface for generating and processing a kMoveReferencePointCmdBoss.

Parameters
layoutData[IN] the ILayoutControlData for the view.
newPosition[IN] the new reference position
newPoint[IN] the new point in pasteboard coordinates
referenceFrame[IN] the new reference point. Use kZeroRect if not relevant.
Returns
ErrorCode the result of the command.
See Also
GetReferenceFrame
kMoveReferencePointCmdBoss
virtual ErrorCode IRefPointUIUtils::ChangeReferencePoint (ILayoutControlDatalayoutData,
IReferencePointData::ReferencePointPosition newPosition,
const UIDListitems 
)
pure virtual

Change just the position of the reference point for the layout view given a set of page items.

Parameters
layoutData[IN] the ILayoutControlData for the view.
newPosition[IN] the new reference point position
items[IN] a UIDList reference to the list of page items to use for computing the reference point position of.
Returns
ErrorCode the result of the command
See Also
kMoveReferencePointCmdBoss
virtual PBPMPoint IRefPointUIUtils::GetPasteboardReferencePoint (ILayoutControlDatalayoutData)
pure virtual

Return the reference point for the layout view.

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
PBPMPoint the reference point in pasteboard coordinates.
virtual PBPMRect IRefPointUIUtils::GetReferenceFrame (ILayoutControlDatalayoutData)
pure virtual

Return the reference frame for the layout view. A reference frame is a rectangle relative to which offset values are displayed in the transform palette/control strip when the content offset preference is set. Comes into play when a page item inside another is selected (e.g. an image). The reference frame is the parent frame.

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
PBPMRect the reference frame in global pasteboard coordinates.
See Also
ITransformPanelPrefs.h
GetShowContentOffset
virtual PBPMPoint IRefPointUIUtils::GetReferencePointOffset (ILayoutControlDatalayoutData)
pure virtual

Obsolete, do not use. Get the reference point offset for the layout view. Used when the position is kOther and value is relative to the center. Currently unused.

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
PBPMPoint the offset value in pasteboard coordinates.
virtual Transform::TransformOrigin IRefPointUIUtils::GetReferencePointTransformOrigin (ILayoutControlDatalayoutData)
pure virtual

Return the current reference point location for the layout view.

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
ReferencePointLocation a structure describing reference point location, position and spread offset.
See Also
ReferencePointLocation
virtual void IRefPointUIUtils::HideReferencePoint (ILayoutControlDatalayoutData)
pure virtual

Hide the reference point for the layout view.

Parameters
layoutData[IN] the ILayoutControlData for the view.
virtual void IRefPointUIUtils::InvalidateReferencePoint (ILayoutControlDatalayoutData,
bool16 forceInval = kFalse 
)
pure virtual

Invalidate the screen location of the reference point for the layout view. This is automatically called when the reference point is hidden or show or moved, so it shouldn't be required in most cases.

Parameters
layoutData[IN] the ILayoutControlData for the view.
forceInval[IN]kTrue to force the invalidation even if the reference point is hidden, kFalse to only invalidate when shown.
virtual bool16 IRefPointUIUtils::IsReferencePointLocked (ILayoutControlDatalayoutData)
pure virtual

Is the reference point locked for the layout view. When locked, reference point will not be updated during selection changes.

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
bool16 kTrue if locked, kFalse if unlocked.
virtual bool16 IRefPointUIUtils::IsReferencePointShown (ILayoutControlDatalayoutData)
pure virtual

Is the reference point shown for the layout view? Note that the reference point will actually only be drawn when it is shown and visible.

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
bool16 kTrue if shown, kFalse is hidden.
virtual bool16 IRefPointUIUtils::IsReferencePointVisible (ILayoutControlDatalayoutData)
pure virtual

Is the reference point visible/drawn for the layout view and selection?

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
bool16 kTrue if reference point drawn, kFalse if not.
See Also
IReferencePointSuite.h
virtual void IRefPointUIUtils::LockReferencePoint (ILayoutControlDatalayoutData)
pure virtual

Lock the reference point for the layout view.

Parameters
layoutData[IN] the ILayoutControlData for the view.
virtual bool16 IRefPointUIUtils::PointInActiveReferencePoint (ILayoutControlDatalayoutData,
const PBPMPointpoint 
)
pure virtual

Test to see if the given point "hits" the reference point. Used by trackers and includes a small slop rect.

Parameters
layoutData[IN] the ILayoutControlData for the view.
point[IN] the point in pasteboard coordinates to use for hittesting.
Returns
bool16 kTrue if hit within a small slop value of reference point, kFalse if not.
virtual IReferencePointData* IRefPointUIUtils::QueryRefPointData (ILayoutControlDatalayoutData)
pure virtual

Query the IRefencePointData interface for this layout view.

Parameters
layoutData[IN] the ILayoutControlData for the view.
Returns
IReferencePointData*, caller must release.
virtual void IRefPointUIUtils::SetDefaultPosition (ILayoutControlDatalayoutData)
pure virtual

Obsolete, do not use.

virtual void IRefPointUIUtils::SetDefaultState (ILayoutControlDatalayoutData)
pure virtual

Recompute the reference point for the layout window based on the selection and change it. Called in response to selection changes and updates the reference point to the same reference position on the new selection. Also saves the reference position as the new session default, since the last-user set position is always the new default position for new views and documents. Session preference is stored in IID_IDEFAULTREFPOINTPOSITION on kWorkspaceBoss.

Parameters
layoutData[IN] the ILayoutControlData for the view.
See Also
CalculateReferencePoint
ChangeReferencePoint
virtual void IRefPointUIUtils::SetReferenceFrame (ILayoutControlDatalayoutData,
const PBPMRectreferenceFrame 
)
pure virtual

Set the reference frame for the layout view. A reference frame is a rectangle relative to which offset values are displayed in the transform palette/control strip when the content offset preference is set. Comes into play when a page item inside another is selected (e.g. an image). The reference frame is the parent frame.

Parameters
layoutData[IN] the ILayoutControlData for the view.
referenceFrame[IN] in global pasteboard coordinates
virtual void IRefPointUIUtils::SetReferencePointInvisible (ILayoutControlDatalayoutData)
pure virtual

Does the current selection have a hidden reference point?

Parameters
layoutData[IN] the ILayoutControlData for the view.
See Also
IReferencePointSuite.h
virtual void IRefPointUIUtils::SetReferencePointOffset (ILayoutControlDatalayoutData,
const PBPMPointoffset 
)
pure virtual

Obsolete, do not use. Set the reference point offset for the layout view. Used when the position is kOther and value is relative to the center.

Parameters
layoutData[IN] the ILayoutControlData for the view.
offset[IN] the value in global pasteboard coordinates.
virtual void IRefPointUIUtils::SetReferencePointVisible (ILayoutControlDatalayoutData)
pure virtual

Does the current selection have a visible reference point?

Parameters
layoutData[IN] the ILayoutControlData for the view.
See Also
IReferencePointSuite.h
virtual void IRefPointUIUtils::SetReferencePositionAndPoint (ILayoutControlDatalayoutData,
IReferencePointData::ReferencePointPosition position,
const PBPMPointpoint 
)
pure virtual

Set the reference position and point for the layout view. This is a helper function used by the move reference point command and shouldn't be used directly.

Parameters
layoutData[IN] the ILayoutControlData for the view.
position[IN] the new reference position
point[IN] the new reference point in global pasteboard coordinates.
See Also
ChangeReferencePoint
kMoveReferencePointCmdBoss
virtual void IRefPointUIUtils::ShowReferencePoint (ILayoutControlDatalayoutData)
pure virtual

Show the refence point for the layout view.

Parameters
layoutData[IN] the ILayoutControlData for the view.
virtual void IRefPointUIUtils::UnlockReferencePoint (ILayoutControlDatalayoutData)
pure virtual

Unlock the reference point for the layout view.

Parameters
layoutData[IN] the ILayoutControlData for the view.
virtual bool16 IRefPointUIUtils::WindowPointInActiveReferencePoint (ILayoutControlDatalayoutData,
const PMPointpoint 
)
pure virtual

Test to see if the given point "hits" the reference point. Used by trackers and includes a small slop rect.

Parameters
layoutData[IN] the ILayoutControlData for the view.
point[IN] the point in local window coordinates to use for hittesting.
Returns
bool16 kTrue if hit within a small slop value of reference point, kFalse if not.