本文整理汇总了TypeScript中phosphor-dockpanel.DockPanel.insertBottom方法的典型用法代码示例。如果您正苦于以下问题:TypeScript DockPanel.insertBottom方法的具体用法?TypeScript DockPanel.insertBottom怎么用?TypeScript DockPanel.insertBottom使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类phosphor-dockpanel.DockPanel
的用法示例。
在下文中一共展示了DockPanel.insertBottom方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: main
/**
* The main application entry point.
*/
function main(): void {
var r1 = createContent('Red');
var r2 = createContent('Red');
var r3 = createContent('Red');
var b1 = createContent('Blue');
var b2 = createContent('Blue');
var g1 = createContent('Green');
var g2 = createContent('Green');
var g3 = createContent('Green');
var y1 = createContent('Yellow');
var y2 = createContent('Yellow');
var panel = new DockPanel();
panel.id = 'main';
var cmSource = new CodeMirrorWidget({
mode: 'text/typescript',
lineNumbers: true,
tabSize: 2,
});
cmSource.loadTarget('./index.ts');
cmSource.title.text = 'Source';
var cmCss = new CodeMirrorWidget({
mode: 'text/css',
lineNumbers: true,
tabSize: 2,
});
cmCss.loadTarget('./index.css');
cmCss.title.text = 'CSS';
panel.insertLeft(cmSource);
panel.insertRight(b1, cmSource);
panel.insertBottom(y1, b1);
panel.insertLeft(g1, y1);
panel.insertBottom(b2);
panel.insertTabAfter(cmCss, cmSource);
panel.insertTabAfter(r1, cmCss);
panel.insertTabBefore(g2, b2);
panel.insertTabBefore(y2, g2);
panel.insertTabBefore(g3, y2);
panel.insertTabBefore(r2, b1);
panel.insertTabBefore(r3, y1);
panel.attach(document.body);
window.onresize = () => { panel.update() };
}
示例2: createSidePanel
function createSidePanel(app: App): DockPanel {
let panel = new DockPanel();
let pianoRollWidget = new PianoRoll();
let instrumentWidget = new InstrumentEditor();
let oscWidget = new Oscilloscope();
panel.insertRight(instrumentWidget);
panel.insertRight(oscWidget, instrumentWidget);
panel.insertBottom(pianoRollWidget);
return panel;
}
示例3: createContent
let g1 = createContent('White');
g1.id = 'my-plot-container';
let g2 = createContent('Green');
let g3 = createContent('Green');
let y1 = createContent('Yellow');
y1.id = 'my-hero-form-container';
let y2 = createContent('Yellow');
let panel = new DockPanel();
panel.id = 'main';
panel.insertBottom(y1);
panel.insertLeft(g1, y1);
panel.insertBottom(b2);
panel.insertTabBefore(g2, b2);
panel.insertTabBefore(y2, g2);
panel.insertTabBefore(g3, y2);
panel.insertTabBefore(r3, y1);
panel.insertLeft(b1);
panel.insertBottom(r1, b1);
panel.insertTabBefore(r2, b1);
panel.attach(document.body);
window.onresize = () => { panel.update(); };