Bugfixes, tweak colors
This commit is contained in:
parent
9ca53df0ec
commit
53b9ae84a0
@ -233,11 +233,11 @@ class Editor
|
|||||||
$this->term->setCursor(1, $h);
|
$this->term->setCursor(1, $h);
|
||||||
if (!file_exists($readFrom)) {
|
if (!file_exists($readFrom)) {
|
||||||
echo "\e[97;41mFile does not exist\e[K\e[0m";
|
echo "\e[97;41mFile does not exist\e[K\e[0m";
|
||||||
break;
|
return;
|
||||||
}
|
}
|
||||||
if (!is_readable($readFrom)) {
|
if (!is_readable($readFrom)) {
|
||||||
echo "\e[97;41mFile not readable\e[K\e[0m";
|
echo "\e[97;41mFile not readable\e[K\e[0m";
|
||||||
break;
|
return;
|
||||||
}
|
}
|
||||||
$ext = strtolower(pathinfo($readFrom, PATHINFO_EXTENSION));
|
$ext = strtolower(pathinfo($readFrom, PATHINFO_EXTENSION));
|
||||||
switch ($ext) {
|
switch ($ext) {
|
||||||
@ -250,7 +250,7 @@ class Editor
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
echo "\e[97;41mUnable to read format: {$ext}\e[K\e[0m";
|
echo "\e[97;41mUnable to read format: {$ext}\e[K\e[0m";
|
||||||
break(2);
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->filename = $readFrom;
|
$this->filename = $readFrom;
|
||||||
@ -478,7 +478,7 @@ class Editor
|
|||||||
$node = $this->list->getNodeForIndex($this->currentRow);
|
$node = $this->list->getNodeForIndex($this->currentRow);
|
||||||
|
|
||||||
$this->term->setCursor(1, $h-1);
|
$this->term->setCursor(1, $h-1);
|
||||||
echo "\e[44;37m\e[K\e[1m{$this->shortfilename}\e[22m#\e[3m{$path}\e[37;23m";
|
echo "\e[40;37m\e[K\e[1m{$this->shortfilename}\e[22m#\e[3m{$path}\e[37;23m";
|
||||||
|
|
||||||
//$this->term->setCursor(1, $h);
|
//$this->term->setCursor(1, $h);
|
||||||
echo " = ";
|
echo " = ";
|
||||||
|
@ -128,7 +128,7 @@ class TreeList implements Countable
|
|||||||
$keys = array_keys($this->list);
|
$keys = array_keys($this->list);
|
||||||
echo "\e[{$screenRow};1H";
|
echo "\e[{$screenRow};1H";
|
||||||
if ($entryRow >= count($keys)) {
|
if ($entryRow >= count($keys)) {
|
||||||
echo ($selected?"\e[100;97m":"\e[0;90m")."\e[K";
|
echo ($selected?"\e[44;97m":"\e[0;90m")."\e[K";
|
||||||
if ($entryRow == count($keys)) echo str_repeat("\u{2574}",$columns);
|
if ($entryRow == count($keys)) echo str_repeat("\u{2574}",$columns);
|
||||||
echo "\e[0m";
|
echo "\e[0m";
|
||||||
//else echo "\e[90m\u{2805}\e[0m";
|
//else echo "\e[90m\u{2805}\e[0m";
|
||||||
@ -145,7 +145,7 @@ class TreeList implements Countable
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
echo "\e[{$screenRow};1H\e[0m";
|
echo "\e[{$screenRow};1H\e[0m";
|
||||||
echo ($selected?"\e[100;97m":"\e[0;37m")."\e[K";
|
echo ($selected?"\e[44;97m":"\e[0;37m")."\e[K";
|
||||||
echo "\e[90m".str_repeat("\u{258f} ",$entry->depth)."\e[37m";
|
echo "\e[90m".str_repeat("\u{258f} ",$entry->depth)."\e[37m";
|
||||||
|
|
||||||
if ($entry->closer) {
|
if ($entry->closer) {
|
||||||
|
Loading…
Reference in New Issue
Block a user