Extract Layout Information to Grasshopper

Hello there,

I’m looking to extract the information from the Layouts Panel - Name and Size of layouts(Ideally there would also be a column for scale!) and use the info in Grasshopper to make a Drawing Schedule.

Making this more complex is that I would like to get the information from multiple files without having them open.

I believe there is a python script which works in a similar way to batch plot the layouts from selected files, so hopefully this is possible.

Can anyone help?

Here I think you can find most of the properties you need.
As for the scale, I don’t believe a page has a scale, only a detail can have a scale. If you only have one detail on the page you could use that for the scale:

Amazing, thank you!

I forgot to mention though, that I have zero experience with scripting other than Grasshopper…

Think I should try to start with this?

Yes, as it opens a whole new world of possibilities :slight_smile:
Best is to start with Rhino Python primer to learn the basics of interacting with Rhino first.

Great, thanks for your advice.

Incidentally when I referred to the scale, that was more of a Rhino wish - it would be good if there were an extra column in the layouts panel for scale. Since, as you say you could have multiple details per layout, perhaps there could be a dropdown in that column where you can pick a scale which is referenced from all the details on the sheet.

Also another column for “template name” would be good in addition to the size column - for having “A1” is more useful than 841 x 594mm…

these wishes make total sense, but to not leave them unnoticed, you better make a separate thread for that, as this one is about extracting data from within Grasshopper.

1 Like

Yes, I think I will.

Edit: I’ve just seen this wish has been made. Hopefully it will be added in v8.

something like this?

That’s not exactly what I meant, but that is a very useful tool nonetheless.

What I meant was the following:

I’ve added in the two columns I’d like to see. In this example, the sheet has details at 1:20, 1:10 and 1:5 scale. I would like to be able to choose the ‘main’ scale of this drawing from the dropdown which populates automatically with the scales of all the details on the sheet.

If there is only one detail on the sheet, or if all details are the same scale then this would just automatically show the detail scale.

Hope this is clear!

I cannot interact with Rhino this way I think, but what I can make is a popup that lists the scales that are being used by the details on page. Then adding a new detail with the page detail could be done by an alternative command that sets the detail scale to be the same as the page scale at creation time.
The paper names (A1, A2, etc.) can be easily derived from the page sizes, so that is not difficult to add either. You will then however not see it in the page layout tab as in your photoshopped version.

Yeah - hopefully Mcneel Team will add these extra columns during v8 development. Your custom tools are really good! Do you have all these scripts saved somewhere - maybe you could put them on food4rhino? For my purposes though, most of the time I will probably just duplicate layouts and edit them that way.

My main priority with this thread is just to try to get the layout names (and sizes if possible) from multiple files into Grasshopper - I already have a GH definition set up that writes schedules to Excel. I will try to figure this out if I ever get the time!

For now I just put things I make into my github page, because that’s by far the most elegant solution to keep my code up to date without having to upload stuff constantly. I’ll see if I can add the above to those as well but still have some testing to do to make it work correctly. If you download github for desktop and open my pythonscripts this way, you can synch whenever there is a new update.

1 Like