Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

SC 4.8 Internals Toolbox and bounds.top

20 views
Skip to first unread message

Alec Hole

unread,
Jun 25, 2018, 4:43:50 PM6/25/18
to superca...@googlegroups.com

Hi,


I've just updated an external to use the new SC 4.8 Internals Toolbox. Previously getting the value for bounds.top returned the top y coordinate of an object, now when I query the bounds of any draw graphic it always returns 1.0.

Here's the code I'm using to fetch the bounds of the draw graphic:


NSSize pixelSize;
ObjectInfoHandle hinfo = nil;
ObjectInfo *info;
SCErr err = isOK;
unsigned char destinationObject[maxstring];
CFStringGetPascalString((CFStringRef) theDestGraphic, destinationObject, maxstring, kCFStringEncodingMacRoman);

if (GetObjectInfo(par, destinationObject, &hinfo) == isOK){
HLock((Handle)hinfo);
info
= *hinfo;
CGFloat grcTop = (info->bounds.top);
}







Is this a bug or has something changed in order to access this correctly?


All the best,


Alec

Reply all
Reply to author
Forward
0 new messages