Sorting Layouts

What would be right way to move print layout around Rhino. I would like to work out code to sort layouts by name. For example, I have page views C, A, B and I would like to get A, B, C.

First I took all pages (doc.Views.GetPageViews()) and changed their PageNumer to desired one. That didn’t work out. I assume there could be duplicate number and that would prevent change. Although I saw that page object kept new PageNumber in debug mode.

Next thought was maybe Rhino reorders pages just after change is made. So, pages are moving around after each step. Then it make sense to push pages to end. That didn’t work out either.

From there I assumed that maybe I should commit change somehow but can really find any reasonable method. Same time if I change PageName that is changing in Rhino window.

Happy to get any hint on that.

Hi @raul,

It isn’t possible to re-order layouts in Rhino 6, outside of using the Move/Copy feature of the layout tab context menu. In the Rhino WIP, however, setting the RhinoPageView.PageNumber property will change the layout tab order.

– Dale

Thank you @dale.
Will implement that when Rhino 7 comes out.

Is it still not possible to rearrange layout tabs in Rhino 8? I can’t seem to find a way.

Hi @l11,

In the Layouts panel, click the Layout column header.

Also, in the Layous panel, you can drag and drop to re-order.

– Dale

Thank you, I see I can rearrange the layout tabs in layout panel.

But why is it not possible to just drag these tabs? It’s already there when you open Rhino without having to open Layout Panel.
image

Hi @l11,

The viewport tabs are a Windows-only feature. At the point we make this cross-platform (so as to work on Mac), we’ll looking to reordering by dragging.

– Dale