mirror of
https://github.com/embarklabs/neo-blessed.git
synced 2025-02-27 01:50:44 +00:00
experimental angle improvement.
This commit is contained in:
parent
c435b03bdc
commit
245b3f44b1
@ -1113,6 +1113,23 @@ Screen.prototype._getAngle = function(lines, x, y) {
|
||||
angle |= 1 << 0;
|
||||
}
|
||||
|
||||
// Experimental: fixes this situation:
|
||||
// +----------+
|
||||
// | <-- empty space here, should be a T angle
|
||||
// +-------+ |
|
||||
// | | |
|
||||
// +-------+ |
|
||||
// | |
|
||||
// +----------+
|
||||
// if (uangles[lines[y][x][1]]) {
|
||||
// if (lines[y + 1] && cdangles[lines[y + 1][x][1]]) {
|
||||
// if (!this.options.ignoreDockContrast) {
|
||||
// if (lines[y + 1][x][0] !== attr) return ch;
|
||||
// }
|
||||
// angle |= 1 << 0;
|
||||
// }
|
||||
// }
|
||||
|
||||
return angleTable[angle] || ch;
|
||||
};
|
||||
|
||||
@ -9132,6 +9149,10 @@ var dangles = {
|
||||
'\u2502': true // '│'
|
||||
};
|
||||
|
||||
var cdangles = {
|
||||
'\u250c': true // '┌'
|
||||
};
|
||||
|
||||
// Every ACS angle character can be
|
||||
// represented by 4 bits ordered like this:
|
||||
// [langle][uangle][rangle][dangle]
|
||||
|
Loading…
x
Reference in New Issue
Block a user