InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
SnpCreateFrame Class Reference

#include <SnpCreateFrame.h>

Public Member Functions

UIDRef CreateRectangleFrame (ILayoutControlData *layoutControlData, const PMRect &boundsInPageCoords)
 
UIDRef CreateTextFrame (ILayoutControlData *layoutControlData, const PMRect &boundsInPageCoords)
 
UIDRef CreateRectangleGraphic (ILayoutControlData *layoutControlData, const PMRect &boundsInPageCoords)
 
UIDRef CreateSquareInFancyGraphic (ILayoutControlData *layoutControlData, const PMRect &boundsInPageCoords)
 
UIDRef CreateArrowGraphic (ILayoutControlData *layoutControlData, const PMRect &boundsInPageCoords)
 
bool16 SelectFrame (ISelectionManager *selectionManager, const UIDRef &frameUIDRef)
 
bool16 ActivateTextEditor ()
 

Detailed Description

  • How to to create frames(IGraphicFrameData) of various types on a spread positioned relative to the current page,
  • rectangle frame, text frame and various styled graphics are created,
  • how to use ILayoutControlData to find the active spread layer and page.
See Also
IGraphicFrameData
ILayoutControlData
SDKLayoutHelper
SnpGraphicHelper

Member Function Documentation

bool16 SnpCreateFrame::ActivateTextEditor ()

Activate kIBeamToolBoss if a text tool is not already active.

Returns
kTrue on success, kFalse otherwise.
UIDRef SnpCreateFrame::CreateArrowGraphic (ILayoutControlDatalayoutControlData,
const PMRectboundsInPageCoords 
)

Create a spline in the shape of an arrow with various graphic attributes applied so that it is drawn as a dashed line with an arrow head at one end.

Parameters
layoutControlDataIN gives the active spread layer the frame will be parented on and the page it will be positioned on.
boundsInPageCoordsIN bounding box of the frame in page co-ordinates.
Returns
UIDRef of created frame (IGraphicFrameData), UIDRef::gNull on failure.
UIDRef SnpCreateFrame::CreateRectangleFrame (ILayoutControlDatalayoutControlData,
const PMRectboundsInPageCoords 
)

Create a rectangle frame.

Parameters
layoutControlDataIN gives the active spread layer the frame will be parented on and the page it will be positioned on.
boundsInPageCoordsIN bounding box of the frame in page co-ordinates.
Returns
UIDRef of created frame (IGraphicFrameData), UIDRef::gNull on failure.
UIDRef SnpCreateFrame::CreateRectangleGraphic (ILayoutControlDatalayoutControlData,
const PMRectboundsInPageCoords 
)

Create a rectangular graphic.

Parameters
layoutControlDataIN gives the active spread layer the frame will be parented on and the page it will be positioned on.
boundsInPageCoordsIN bounding box of the frame in page co-ordinates.
Returns
UIDRef of created frame (IGraphicFrameData), UIDRef::gNull on failure.
UIDRef SnpCreateFrame::CreateSquareInFancyGraphic (ILayoutControlDatalayoutControlData,
const PMRectboundsInPageCoords 
)

Create a square parented inside a rectangular graphic with a fancy border.

Parameters
layoutControlDataIN gives the active spread layer the frame will be parented on and the page it will be positioned on.
boundsInPageCoordsIN bounding box of the frame in page co-ordinates.
Returns
UIDRef of created frame (IGraphicFrameData), UIDRef::gNull on failure.
UIDRef SnpCreateFrame::CreateTextFrame (ILayoutControlDatalayoutControlData,
const PMRectboundsInPageCoords 
)

Create a text frame.

Parameters
layoutControlDataIN gives the active spread layer the frame will be parented on and the page it will be positioned on.
boundsInPageCoordsIN bounding box of the frame in page co-ordinates.
Returns
UIDRef of created frame (IGraphicFrameData), UIDRef::gNull on failure.
bool16 SnpCreateFrame::SelectFrame (ISelectionManagerselectionManager,
const UIDRefframeUIDRef 
)

If the frame is a text frame activate the text editor and make a text selection to set the text caret at the start of the story, otherwise make a layout selection of the frame.

Parameters
selectionManager
frameUIDRef
Returns
kTrue on success, kFalse otherwise.