hoaproject / Console

The Hoa\Console library.
https://hoa-project.net/
366 stars 32 forks source link

Features not Windows compatible #3

Closed osaris closed 11 years ago

osaris commented 11 years ago

I've tested Console/Cursor & Console/Window under Windows 7 64 bits with PHP 5.4.5 and Hoa master (hoaproject/Central@d24743570d84a59f88fd3af1dce35cab7bb97c14).

Here is the list of methods that doesn't work :

Hoa\Console\Cursor::move
Hoa\Console\Cursor::moveTo
Hoa\Console\Cursor::clear
Hoa\Console\Cursor::scroll
Hoa\Console\Cursor::hide
Hoa\Console\Cursor::show
Hoa\Console\Cursor::getPosition
Hoa\Console\Cursor::setStyle

so the only method working is bip() for Hoa\Console\Cursor !!

Hoa\Console\Window::setSize
Hoa\Console\Window::moveTo
Hoa\Console\Window::getPosition
Hoa\Console\Window::minimize
Hoa\Console\Window::setTitle
Hoa\Console\Window::getTitle
Hoa\Console\Window::getLabel
Hoa\Console\Window:resize (event)

so the only method working is getSize() for Hoa\Console\Window !!

hoaproject commented 11 years ago

Thank you for testing!

Please, see 1312a9d93369b0429e6d3d1144d0b5ebd4ac1663 and 23cbe7b7d45ef1a89d277d3dc19a4928344fc5e1.

hoaproject commented 11 years ago

Any idea how to extend these methods to Windows?

Example: for Hoa\Console\Window::getSize, we use Hoa\Console\Processus to run mode con and get informations (please, see lines 145 to 161). Is it possible to use this strategy for all methods in Hoa\Console\Cursor and Hoa\Console\Window?

hoaproject commented 11 years ago

It appears that it is not possible easily. We need an external program that uses Wincon.h. I close the issue :-).

Thank you!