Jump to content
Developer Wiki and Function Reference Links ×

Edit path directly on doubleclicking the 2dpath object


Recommended Posts

I've got a custom 2dpath object in SDK.

I want to edit the path directly when doubleclicking.

According to what I can find, this is what should make it work:

EObjectEvent CObjThePoly2D_EventSink::OnInitXProperties(CodeRefID objectID)
// obtain the interfact for accessing the extended properties
using namespace VectorWorks::Extension;
VCOMPtr	extProps( IID_ExtendedProps );
extProps->SetObjectPropertyChar( objectID, kObjXPropSupportProxyObjects, true);

gSDK->SetObjectPropertyChar(objectID, kObjXPropEditGroup, kEditGroupPath);

return kObjectEventNoErr;

it doesn't, and using any other option kEditGroupProfile, kEditGroupPath, kEditGroupCustom has no other result.

When doubleclicking the path, I see a polyline. When doubleclicking that again I can finaly edit the path..



Edited by hippothamus
Link to comment
  • 3 weeks later...

Answer provided by the sdk mailinglist:

extProps->SetObjectProperty(objectID, kObjXPropSpecialEdit, Sint8(kSpecialEditReshape));
extProps->SetObjectProperty(objectID, kObjXIs2DSurfaceEligable, true);
extProps->SetObjectProperty(objectID, kObjXPropEditGroup, Sint8(kEditGroupCustom));

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...