You are on page 1of 1

CHAPTER 1: Layout Layout windows and layout views 43

Related documentation

 “Closing a document”

Related API

kLayoutPresentationBoss

Iterating through open layout windows


Solution

1. Use IDocumentList to list the documents that are open in the application. See “Iterating through
documents”.

2. Use IPresentationList on each document to list the windows open on it.

Related API

kLayoutPresentationBoss

Acquiring a reference to a layout view


Solution

If you have an IActiveContext interface, use IActiveContext::GetContextView.

If you have a layout window (kLayoutPresentationBoss) reference, use IPanelControlData::FindWidget. Call


with widgetId=kLayoutWidgetBoss) to get the window’s layout view.

To work with the layout view that is editing the document:

1. Use ILayoutUIUtils::QueryFrontView to get the layout view of the front document.

2. Use ILayoutUIUtils::QueryFrontLayoutData to get the ILayoutControlData interface for the layout view
of the front document.

Related API

kLayoutWidgetBoss

Setting the spread targeted for edit operations


Solution

Use kSetSpreadCmdBoss.

You might also like