Commit Graph

198 Commits

Author SHA1 Message Date
Jonathan Daugherty
32b2740409 Edit: use multilineStr to render editors (fixes #8) 2015-08-19 09:21:35 -07:00
Jonathan Daugherty
693abbb345 List: refactor rendering routine to only render the items in view (fixes #7)
- Changes renderList to expect an item height and all rendered items
  must match this height
- Uses vector slicing to efficiently get the sub-list of items to be
  rendered
- Renders 2 * H items at time instead of all N, where H is the height of
  the list's viewport
2015-08-18 13:06:36 -07:00
Jonathan Daugherty
74aa344564 ListDemo: missing uses of Vector API 2015-08-18 09:39:58 -07:00
Jonathan Daugherty
14d2147c85 List: use Vector instead of [] to manage elements to improve performance 2015-08-17 23:33:47 -07:00
Jonathan Daugherty
d7bf9e1c97 List: instead of passing the draw function to the constructor, we pass it at rendering time 2015-08-17 22:19:08 -07:00
Jonathan Daugherty
d33181ed0b Make str and txt single-line only and add slower multiline variants 2015-08-17 21:13:00 -07:00
Jonathan Daugherty
47ef979221 Increase vty bound to 5.3 and remove comment about now-fixed bug 2015-08-11 15:32:12 -07:00
Jonathan Daugherty
5f6df6dbc4 Remove stale demo 2015-08-06 19:26:22 -07:00
Jonathan Daugherty
2d48b9bbac Minor editor demo cleanup 2015-07-20 18:39:10 -07:00
Jonathan Daugherty
60a67fd7fe Add Brick.Main.showCursorNamed for making name-based cursor-matching easier 2015-07-20 18:36:24 -07:00
Jonathan Daugherty
935f05973a Update editor demo to show both limited and unlimited editors 2015-07-20 18:31:33 -07:00
Jonathan Daugherty
c35e20196b Add support for multi-line editors
- Changes the editor constructor to take a line limit
- Changes the editor drawing function to take [String] instead of String
- Changes the editor to use a viewport that scrolls both horizontally
  and vertically
- Uses the latest text-zipper release (so cabal update)
2015-07-20 18:10:50 -07:00
Jonathan Daugherty
f930210777 Move toward suffixing all lenses with L 2015-07-19 12:08:00 -07:00
Jonathan Daugherty
c8ed8df9e1 Dialog demo: remove stale import 2015-07-17 21:12:39 -07:00
Jonathan Daugherty
648abfcacc padAll, padTopBottom, and padLeftRight all now only take integer padding arguments 2015-07-17 21:09:56 -07:00
Jonathan Daugherty
4fde0b4f7d Add support for viewports that scroll both vertically and horizontally, add visibility demo 2015-07-17 19:30:42 -07:00
Jonathan Daugherty
a2bf4e241a Border demo: update intersection field names 2015-07-17 18:37:11 -07:00
Jonathan Daugherty
e2b71a51be ListDemo: stale import 2015-07-11 16:53:06 -07:00
Jonathan Daugherty
f79da4ea2b Remove benchmark suite and dependencies 2015-07-11 16:17:42 -07:00
Jonathan Daugherty
962e7c83df Rename appMakeVtyEvent to appLiftVtyEvent 2015-07-10 13:53:21 -07:00
Jonathan Daugherty
a460d2fd15 ViewportScrollDemo: use explicit imports 2015-07-10 13:38:05 -07:00
Jonathan Daugherty
d6f34261bc SuspendAndResumeDemo: use explicit imports 2015-07-10 13:34:21 -07:00
Jonathan Daugherty
d1f8cd9a67 PaddingDemo: use explicit imports 2015-07-10 13:30:34 -07:00
Jonathan Daugherty
9fce0120b0 MarkupDemo: use explicit imports 2015-07-10 13:28:23 -07:00
Jonathan Daugherty
ad9cffc2b7 Remove Vty rogue demo 2015-07-10 13:26:06 -07:00
Jonathan Daugherty
75cab4340c ListDemo: use explicit imports 2015-07-10 13:25:44 -07:00
Jonathan Daugherty
191b37f417 LayerDemo: use explicit imports 2015-07-10 13:20:05 -07:00
Jonathan Daugherty
69472322c2 HelloWorldDemo: use explicit imports (and improve others) 2015-07-10 13:15:30 -07:00
Jonathan Daugherty
0be4379b6c EditDemo: use explicit imports 2015-07-10 13:12:12 -07:00
Jonathan Daugherty
ceda506b57 DialogDemo: use explicit imports 2015-07-10 13:09:10 -07:00
Jonathan Daugherty
7833b2cf44 CustomEventDemo: use explicit imports 2015-07-10 13:03:49 -07:00
Jonathan Daugherty
2c26557149 BorderDemo: use explicit imports 2015-07-10 12:57:19 -07:00
Jonathan Daugherty
137e59f5bf AttrDemo: use explicit imports 2015-07-10 12:49:17 -07:00
Jonathan Daugherty
b718a68986 Edit: use text-zipper to generalize editing functionality and simplify API 2015-07-09 14:32:20 -07:00
Jonathan Daugherty
2e13a1cde5 Add viewport scrolling demo 2015-07-09 11:03:48 -07:00
Jonathan Daugherty
d2bcb98fb3 Dialog demo: improve dialog appearance 2015-07-09 10:22:22 -07:00
Jonathan Daugherty
12d4cf705a Improve padding interface by letting the user specify how much padding to add; also add left/right, top/bottom, and "all" padding variants 2015-07-09 10:19:27 -07:00
Jonathan Daugherty
dfb999132b Add a dialog type and demo 2015-07-08 14:47:48 -07:00
Jonathan Daugherty
226d59bf5d Stop exporting and using "for" 2015-07-07 17:05:24 -07:00
Jonathan Daugherty
201dfdc4a3 Rename Brick.Core to Brick.Types 2015-07-07 17:00:42 -07:00
Jonathan Daugherty
e9c587189d Layer demo: improve layout of event handler to make layer handling distinction clearer 2015-07-03 16:04:23 -07:00
Jonathan Daugherty
32c82d0754 Update rogue demo to translate the player rather than using spaces to center it to avoid layer opacity issues 2015-07-03 16:02:35 -07:00
Jonathan Daugherty
149ab2d58b Add a layer demo program 2015-07-03 15:49:33 -07:00
Jonathan Daugherty
2ba4f822e6 List demo: make items smaller to avoid pointless performance meltdown 2015-07-03 14:23:35 -07:00
Jonathan Daugherty
e3c46bbf41 Add a benchmark for hCenter 2015-07-03 14:05:07 -07:00
Jonathan Daugherty
afc0c95be8 Flip the arguments to application event handlers to make event pattern-matching more natural 2015-07-01 13:05:28 -07:00
Jonathan Daugherty
2942514198 SuspendAndResumeDemo: remove stale/testing getLine at end of main 2015-07-01 09:12:22 -07:00
Jonathan Daugherty
f9ae799f9b Merge branch 'master' of github.com:jtdaugherty/brick 2015-06-30 19:18:54 -07:00
Jonathan Daugherty
9601098d46 Add appStartEvent to support getting scroll requests on the first rendering of the app state before other events have arrived 2015-06-30 19:15:29 -07:00
Jonathan Daugherty
0bb91a73bf EditDemo: syntax nit 2015-06-30 10:07:53 -07:00