Commit Graph

90 Commits

Author SHA1 Message Date
Alexandre Bury
fa4b52ee81 Simplified examples 2015-07-30 14:51:12 +02:00
Alexandre Bury
ac85a1f288 Fixed bug with dialog without buttons 2015-07-28 21:54:32 +02:00
Alexandre Bury
36fbc1ce5b Add some convenient ID methods 2015-07-28 15:57:52 +02:00
Alexandre Bury
25a298a2eb Fix dialog layout and input 2015-06-08 22:24:59 -07:00
Alexandre Bury
df11b4f1f0 Update documentation 2015-06-08 15:38:10 -07:00
Alexandre Bury
40af72a567 BugFix in LinearLayout
And add a simple linear example.
2015-06-08 12:23:36 -07:00
Alexandre Bury
e5cb687990 Refactor themes and colors
And adds a theme example.
TODO: Shadow & Borders support
2015-06-05 18:26:40 -07:00
Alexandre Bury
781d9c1a03 Can now change dialog button alignment 2015-06-02 19:36:22 -07:00
Alexandre Bury
0b159d6bf1 Add align support to SelectView
And moved some alignment offset computation to the align module.
2015-06-02 14:23:51 -07:00
Alexandre Bury
f81a9b2768 Update examples for focusless draw 2015-06-01 09:20:06 -07:00
Alexandre Bury
b64a6b8c34 Add on_select callback for SelectView
And updated the select example to use that instead of an OK button.
This also removes the need for an ID selector.
2015-05-31 20:51:12 -07:00
Alexandre Bury
c8b2bc943d Minor fixes
And some doc
2015-05-31 16:58:55 -07:00
Alexandre Bury
323805b52f Add scrolling to SelectView
Scrolling functionalities are stored in ScrollBase. Both TextView and
SelectView use it.
Also add letter search to SelectView (currently case sensitive).
And made the cities example bigger with a long list of capitals.
2015-05-31 16:38:53 -07:00
Alexandre Bury
db39069260 Fix focus for stack and text views.
And updated Lorem example with a Quit button under the scrollable text.
2015-05-30 21:54:06 -07:00
Alexandre Bury
6b781684ef Rename ListView -> SelectView
And added documentation.
2015-05-30 21:32:24 -07:00
Alexandre Bury
969650ab1a Add basic ListView
Show a selection among a list of items.
Maybe should be called SelectView?
TODO:
* Scrolling
* Error handling with empty list
* Action on Enter on an item
2015-05-30 21:05:34 -07:00
Alexandre Bury
3d1507c3cf Add UTF-8 input support
Didn't the proper methods in the standard lib, so I implemented a simple
utf-8 char reader.
2015-05-27 22:17:52 -07:00
Alexandre Bury
f9c9e56518 Transform ncurses i32 key into Event enum
Prepares support for unicode char input spanning multiple ncurses
characters.
2015-05-27 18:04:33 -07:00
Alexandre Bury
ca09885978 Add key_codes example
Prints the code on key press. Useful tool.
2015-05-27 16:55:49 -07:00
Alexandre Bury
c3496c9870 Update edit example
Added top padding to dialog and a `!` to message.
2015-05-26 23:49:07 -07:00
Alexandre Bury
44899bdcd6 Add/fix some doc 2015-05-26 16:48:27 -07:00
Alexandre Bury
3460f8123d EditView can now have a minimum size 2015-05-26 16:11:22 -07:00
Alexandre Bury
e8fcaabd6c Add EditView
TODO: proper visualization:
* Display cursor when focused (instead of color change)
* Do not use HIGHLIGHT, but something like INVERTED
2015-05-26 15:48:35 -07:00
Alexandre Bury
25e1ca6074 Rename Margins -> Vec4
And move it to the vec module
2015-05-25 14:56:51 -07:00
Alexandre Bury
cb03f79e24 Update lorem example
Load text before initializing ncurses.
2015-05-25 11:37:28 -07:00
Alexandre Bury
222c4465d9 Fix bad TextView layout 2015-05-25 01:32:55 -07:00
Alexandre Bury
eb6af9b981 Update mutation example
Don't show the popup at start, let the user read the text.
2015-05-23 20:28:03 -07:00
Alexandre Bury
081b7545b9 Remove viewpath in callbacks 2015-05-23 17:07:22 -07:00
Alexandre Bury
5a4c34361c Update mutation example 2015-05-23 16:46:38 -07:00
Alexandre Bury
7e823435cd Stop using ncurses::WINDOW
Overlap is a mess. Let's do it ourselve.
2015-05-23 15:58:06 -07:00
Alexandre Bury
d9b56574d2 Add selector by ID 2015-05-23 10:33:29 -07:00
Alexandre Bury
7e4873f5b7 Fix logs demo 2015-05-22 17:24:02 -07:00
Alexandre Bury
e59a2d4dd7 Don't panic in log generator 2015-05-22 17:12:39 -07:00
Alexandre Bury
94e723d3f0 Add some doc 2015-05-22 16:57:29 -07:00
Alexandre Bury
d9652ac728 Add animated example. 2015-05-22 16:28:05 -07:00
Alexandre Bury
3df17cc64b Improved lorem example
TODO: add margins around the textview?
2015-05-22 00:06:33 -07:00
Alexandre Bury
25726140d8 Add colors and styles to printer 2015-05-21 23:29:49 -07:00
Alexandre Bury
b8b7638667 Add lorem example with long text and line wrapping 2015-05-18 11:36:15 -07:00
Alexandre Bury
74f0fee9b6 Add Dialog skeleton 2015-05-16 14:02:15 -07:00
Alexandre Bury
a8c8855831 Moved example to separate directory
And add it to Cargo.toml
2015-05-16 13:09:38 -07:00