mirror of
https://github.com/NuSkooler/enigma-bbs.git
synced 2025-06-10 14:44:40 +02:00
* Moved menus -> menus.json::menus
* Move prompts -> prompts.json::prompts * Default to 80x25 if NAWS/ENV/CPR term size negotiations fail. Seeing this with Netrunner. May need more work.
This commit is contained in:
parent
9ac2e9af6e
commit
0d9add70bd
8 changed files with 511 additions and 454 deletions
|
@ -194,16 +194,18 @@ function ViewController(options) {
|
|||
|
||||
setViewProp('maxLength');
|
||||
|
||||
|
||||
['styleSGR1', 'styleSGR2'].forEach(function styleSgr(style) {
|
||||
setViewProp(style, function(v) {
|
||||
//
|
||||
// styleSGRx: 1..25
|
||||
//
|
||||
for(var i = 1; i <= 25; i++) {
|
||||
setViewProp('styleSGR' + i, function(v) {
|
||||
if(_.isObject(v)) {
|
||||
view[style] = ansi.getSGRFromGraphicRendition(v, true);
|
||||
view['styleSGR' + i] = ansi.getSGRFromGraphicRendition(v, true);
|
||||
} else if(_.isString(v)) {
|
||||
view[style] = ansi.fromPipeCode(v);
|
||||
view['styleSGR' + i] = ansi.fromPipeCode(v);
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
setViewProp('fillChar', function(v) {
|
||||
if(_.isNumber(v)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue