Home > DMT_EditorControl > getSplitScreenIdByTabId
DMT_EditorControl.getSplitScreenIdByTabId() method
使用标签页 ID 获取分屏 ID
签名
typescript
function getSplitScreenIdByTabId(tabId: string): Promise<string | undefined>;1
参数名
参数 | 类型 | 描述 |
|---|---|---|
tabId | string | 标签页 ID |
返回值
Promise<string | undefined>
分屏 ID
示例
javascript
// 1. 打开一个原理图页,拿到它的标签页 ID
const pages = await eda.dmt_Schematic.getAllSchematicPagesInfo();
const tabId = await eda.dmt_EditorControl.openDocument(pages[0].uuid);
// 2. 查询该标签页所在的分屏
const splitScreenId = await eda.dmt_EditorControl.getSplitScreenIdByTabId(tabId);
console.log('tabId:', tabId);
console.log('splitScreenId:', splitScreenId);1
2
3
4
5
6
7
8
2
3
4
5
6
7
8