• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
6

Is there a way to calculate the area of a shape?

Engaged ,
May 09, 2007 May 09, 2007

Copy link to clipboard

Copied

I work in toy packaging and the size of the warning we have to use is dictated by the size of the package. On most items, it's pretty straight forward, LxW... But that doesn't always work, as the packaging isn't always that simple. Is there a way to get Illustrator to give me the area of a shape?

Thanks!
TOPICS
Feature request

Views

175.6K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Advocate ,
Jul 20, 2023 Jul 20, 2023

Copy link to clipboard

Copied

@JETalmage 

Im dont think its as easy as to subtract or add to calculate certain sub-items. Thing is, they can also overlap half, but there is no way to find out how much then. Perhaps better method would be duplicate the object and expand all. Then do area check.

 

Im running in an issue where a live PathFinder items, one is created by holding alt when ie subtracting 2 items. The object because a pluginItem, these have hardly anything in script in terms of parameters of arguments.

 

EDIT

I have done some testing, lots of it, and i believe i have a working version now for also pluginItems, so items which are created from the pathfinder panel when alt is pressed when clicking ie subtract. Ive also found a workaround to get compoundpathitem with sub-items. I simply duplicate that object and then use trim, they i loop over all the parts. That way we dont have the issue with the polarity. Because half overlapping sub items are now trimmed and thus result in a proper path item

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 31, 2023 Aug 31, 2023

Copy link to clipboard

Copied

This discussion rank pretty high if you google calculate area in illustrator, so I thought I share what I found. I could not get the scripts etc posted earlier to work (maybe to no surprise since it's 16 years old) but since Illustrator still does not calculate area on it's own in 2023, I'm guessing there might be more people looking for a solution.

I found this, which works great (on a mac at least), works on single, multiple and combined shapes – very useful, and free: https://gist.github.com/bryanbuchanan/11387501

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Aug 31, 2023 Aug 31, 2023

Copy link to clipboard

Copied

LATEST

@tynell

 

Ive worked on that scripted and added a dialog and more functions. You can find it here https://github.com/schroef/Illustrator-Scripts/blob/master/GetShapeArea-dialog.jsx

 

I can can show multiple digits, 2 different units and can also show real world size. Currently still only m2

Ive also solved issues with pluginitemsshape and compoundshape items

 

Though there is one issue with very complex shapes. But there is a solution, if we group multiple compoundshape items first, then run trim function then the script

real area option example.pngusing intersecting parts option.pngissue -with 2 shapes and compund cutout works now v012.pnggetShapreArea-v012.png

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines