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

#include <IRenderingObjectUI.h>

Inheritance diagram for IRenderingObjectUI:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IRENDERINGOBJECTUI }
 
enum  ApplyAction { kNone = -1, kApplyToStroke, kApplyToFill }
 

Public Member Functions

virtual void DrawProxy (IGraphicsPort *gPort, const PMRect &r) const =0
 
virtual bool16 SupportsStroke () const =0
 
virtual bool16 SupportsFill () const =0
 
virtual void SelectSwatchHelper (UID gfxRenderUID, ApplyAction applyAction, bool16 swatchSelectionIsUnique=kFalse) const =0
 
virtual bool16 CustomDrawProxy ()=0
 
virtual bool16 GetProxyIconID (RsrcID &iconLarge, RsrcID &iconSmall)=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

Unless you have created your own form of rendering object – the equal of a color, gradient, tint, etc – you are unlikely to be interested in this interface. It allows the UI behavior of a rendering object to be refined.

Member Enumeration Documentation

Parameter used in SelectSwatchHelper().
Enumerator
kNone 

Unknown Action (error condition).

kApplyToStroke 

Action is to be applied to current stroke.

kApplyToFill 

Action is to be applied to current fill.

Member Function Documentation

virtual bool16 IRenderingObjectUI::CustomDrawProxy ()
pure virtual

Whether or not DrawProxy should be called to draw the proxy for this rendering object. If false, then the redering object is simply installed in the port and drawn.

virtual void IRenderingObjectUI::DrawProxy (IGraphicsPortgPort,
const PMRectr 
) const
pure virtual

By default, a rendering object is assumed to be a paint that can be installed on a port, and then 'filled.' This mechanism is used to draw the proxy control into the specified rectangle. This function, however, allows the implementation to override the proxy draw, painting an image, icon, etc.

Parameters
gPortthe port to draw into.
rthe rect to draw into.
virtual bool16 IRenderingObjectUI::GetProxyIconID (RsrcID & iconLarge,
RsrcID & iconSmall 
)
pure virtual

Returns an icon ID to draw in the proxy view. If there is none, the function returns false and the icon id is not modified.

virtual void IRenderingObjectUI::SelectSwatchHelper (UID gfxRenderUID,
ApplyAction applyAction,
bool16 swatchSelectionIsUnique = kFalse 
) const
pure virtual

Help determine how this swatch should be selected given the current active swatch selection in the graphic state and whether the selection applies to the current fill or stroke.

Parameters
gfxRenderUIDthe current active swatch UID in the graphic state.
applyActionwhether the action is to be applied to fill or stroke.
swatchSelectionIsUniqueindicate if the current selection already has the same swatch, gfxRenderUID, applied before this swatch is applied.
virtual bool16 IRenderingObjectUI::SupportsFill () const
pure virtual

Should return true if this rendering object can be applied to a fill.

virtual bool16 IRenderingObjectUI::SupportsStroke () const
pure virtual

Should return true if this rendering object can be applied to a stroke.