neo-blessed/test/widget-shrink-fail-2.js

44 lines
632 B
JavaScript
Raw Normal View History

2014-01-12 12:19:54 +00:00
var blessed = require('blessed');
var screen = blessed.screen({
2015-07-22 02:23:57 +00:00
autoPadding: true,
warnings: true
2014-01-12 12:19:54 +00:00
});
var tab = blessed.box({
parent: screen,
top: 2,
left: 0,
right: 0,
bottom: 0,
scrollable: true,
keys: true,
vi: true,
alwaysScroll: true,
scrollbar: {
ch: ' '
},
style: {
scrollbar: {
inverse: true
}
}
});
tab._.data = blessed.text({
parent: tab,
top: 0,
left: 3,
height: 'shrink',
width: 'shrink',
content: '',
tags: true
});
tab._.data.setContent(require('util').inspect(process, null, 6));
screen.key('q', function() {
screen.destroy();
2014-01-12 12:19:54 +00:00
});
screen.render();