Commit Graph

463 Commits

Author SHA1 Message Date
ArthurSonzogni
20d4ee458a Fix layout bug detected thanks to dom_tests. 2020-03-25 19:10:46 +01:00
ArthurSonzogni
13d1cc1684 Fix missing include. 2020-03-25 18:31:27 +01:00
Arthur Sonzogni
86007c8d00
Merge pull request #12 from mauve/master
Assorted win32 cleanups
2020-03-25 18:29:52 +01:00
Mikael Olenfalk
2c82a4bf31 Remove unused file 2020-03-25 08:54:16 +01:00
Mikael Olenfalk
a55baa1e9c Use the correct macro check if we are compiling for windows 2020-03-25 08:54:03 +01:00
Mikael Olenfalk
a4461f4196 Ignore warning 4267 2020-03-25 08:52:57 +01:00
ArthurSonzogni
5fc5766f1e Add Windows input.
Co-authored-by: Mikael Olenfalk <mikael@olenfalk.se>
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
2020-03-25 02:24:43 +01:00
ArthurSonzogni
ff59c7bafa Fix compile on Windows. 2020-03-25 02:18:48 +01:00
ArthurSonzogni
d20d2ab19e MSVC => DIsable warning 4244 2020-03-25 02:15:38 +01:00
ArthurSonzogni
6e22a10eb7 Fix compile error on OS where char is signed. 2020-03-25 02:01:31 +01:00
ArthurSonzogni
508b2ef048 Improve thread usages. 2020-03-25 01:15:46 +01:00
ArthurSonzogni
0a7b556a12 Switch name Producer/Consumer -> Sender/Receiver
The producer/consumer was created for:
https://github.com/ArthurSonzogni/FTXUI/pull/11

This patch makes rename everything from Producer/Consumer toward
Sender/Receiver.
2020-03-25 00:07:41 +01:00
ArthurSonzogni
09a1b16613 Add a Producer/Consumer system.
It allow you to create the two end of a pipe: A producer and consumer.
The producer can be moved into another thread.
Several producer can be created if necessary.

This will ease merging:
https://github.com/ArthurSonzogni/FTXUI/pull/11
2020-03-24 23:42:17 +01:00
ArthurSonzogni
6de8c63907 Readd 'resize' handling. It was mistakenly removed. 2020-03-24 01:26:06 +01:00
Mikael Olenfalk
f927d3d712 Win32: Switch codepage to UTF8 in Screen constructor
Co-authored-by: Mikael Olenfalk <mikael@olenfalk.se>
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
2020-03-24 00:37:06 +01:00
ArthurSonzogni
b6d1f8ebdb Fix MSVC flag for UTF-8 2020-03-23 22:48:27 +01:00
Mikael Olenfalk
b2b42a8a04 Disable C++17 deprecation warnings 2020-03-23 22:44:13 +01:00
Mikael Olenfalk
71598cb18d Fix warning: Namespace uses itself 2020-03-23 21:46:44 +01:00
Mikael Olenfalk
40800ac019 Use Console API to set and restore terminal mode on Windows 2020-03-23 21:42:33 +01:00
Mikael Olenfalk
f3cef48328 Fix more narrow conversion warnings 2020-03-23 21:32:12 +01:00
Mikael Olenfalk
c4f87a40b7 Fix narrow cast warnings 2020-03-23 21:27:16 +01:00
ArthurSonzogni
493e734680 Set clang-format macro indent.
1) Set clang-format macro indent.
2) Run clang-format on every files.
2020-03-23 21:26:00 +01:00
Mikael Olenfalk
9e71c467f6 Use Console API to get terminal size on Windows
Co-authored-by: Mikael Olenfalk <mikael@olenfalk.se>
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
2020-03-23 21:11:34 +01:00
Mikael Olenfalk
539ec45036 Add missing <algorithm> include 2020-03-23 21:03:25 +01:00
Mikael Olenfalk
a1c390ea31 Require C++17 and force MSVC to treat source as UTF-8
Co-authored-by: Mikael Olenfalk <mikael@olenfalk.se>
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
2020-03-23 20:51:25 +01:00
ArthurSonzogni
9ca8d41afc Improve ScreenInteractive. 2020-03-23 09:23:57 +01:00
ArthurSonzogni
a402cb4fbb Fix format. Try compile on Windows. 2020-03-22 22:32:44 +01:00
ArthurSonzogni
4ff45ee540 Add travis configuration. 2020-03-22 21:33:41 +01:00
ArthurSonzogni
1e35687d64 Make FTXUI compatible with clang warnings. 2020-02-15 20:41:44 +01:00
ArthurSonzogni
6ef9f56da7 Update README.md 2020-02-12 13:54:13 +01:00
ArthurSonzogni
8cdfd9f854 Disable signe-compare. 2020-02-12 00:16:55 +01:00
ArthurSonzogni
65705d5bc7 Fix werror=type-limit on systems with char=unsigned char. 2020-02-11 23:43:26 +01:00
ArthurSonzogni
ebf857e73b Add starter project. 2020-02-11 23:29:17 +01:00
ArthurSonzogni
1f1229564a Fix (maybe uninitialized) on weak compilers. 2020-02-11 22:34:01 +01:00
ArthurSonzogni
a8fdfafe6a Support the -pedantic flag. 2020-02-11 21:44:55 +01:00
Arthur Sonzogni
5637fa3a93
Merge pull request #10 from GiuseppeCesarano/master
CMakeLists.txt rewrite
2020-02-11 14:51:03 +01:00
Giuseppe
db888b3e09 CMakeLists.txt rewrite 2020-02-11 14:23:12 +01:00
Arthur Sonzogni
104d06f04e
Merge pull request #9 from alfishe/master
Fix compilation issue on macOS(CLang compiler)
2020-02-05 14:03:06 +01:00
Arthur Sonzogni
7a45585626
Update README.md 2020-02-04 11:48:01 +01:00
Arthur Sonzogni
f17acfba4c
Update README.md 2020-02-03 16:05:41 +01:00
Ilia Sharin
469d2cd736 Fix compilation issue on macOS(CLang compiler) where stdlib doesn't define quick_exit() 2020-02-02 15:27:46 -05:00
ArthurSonzogni
283f0fed08
Merge pull request #8 from bresilla/master
using TAB key event
2019-11-01 20:03:35 +01:00
ArthurSonzogni
22f8f0d3b7 Using TAB key event.
A key event that makes use of TAB key to cycle the elements.

Co-authored-by: Trim Bresilla <trim.bresilla@gmail.com>"
Co-authored-by: ArthurSonzogni <sonzogniarthur@gmail.com>
2019-11-01 19:54:16 +01:00
ArthurSonzogni
7f0381e30a Emit a new line when a component is interrupted.
While running a component, make sure to reset the cursor at the end of
the component and insert a new line.

This fixes:
https://github.com/ArthurSonzogni/FTXUI/issues/6
2019-09-18 22:02:51 +02:00
ArthurSonzogni
e1efcf2d97 Make DEL to be a special character. 2019-07-02 23:09:20 +02:00
ArthurSonzogni
65e7fae7df Fix parsing of CSI escape sequence.
There was a bug, preventing the user from typing the DEL key.

This is related to bug:
https://github.com/ArthurSonzogni/FTXUI/issues/4
2019-07-01 00:44:50 +02:00
ArthurSonzogni
16ae64dfb4 Fix using undefined value bug. 2019-07-01 00:43:00 +02:00
ArthurSonzogni
01ab335919 Implement key Delete in component > Input.
The BS  key is used to delete the character on the left of the cursor.
The DEL key is used to delete the character on the right of the cursor.

BackSpace was already implemented. This CL implements DEL.

This is related to bug:
https://github.com/ArthurSonzogni/FTXUI/issues/4
2019-07-01 00:40:55 +02:00
ArthurSonzogni
32871fcc6b Add -Wextra 2019-06-30 23:59:27 +02:00
ArthurSonzogni
a87e70c96e Handle terminal resize.
This is related to bug:
https://github.com/ArthurSonzogni/FTXUI/issues/3
2019-06-30 23:53:56 +02:00