Commit Graph

74 Commits

Author SHA1 Message Date
gulyasm c055c87ae8 adds ViewBufferLines to View 2018-04-11 17:57:51 +02:00
gulyasm 2cda4f9f05 adds BufferLines func to View 2018-04-11 17:57:51 +02:00
Roi Martin 2677ad0445 Fix trailing \x00 bug in edition mode 2017-08-18 01:00:47 +02:00
Roi Martin 78f1aee25c Set viewLines to nil on *View.Clear() 2016-11-14 21:56:17 +01:00
Roi Martin aacdc2698f Rewind on *View.Clear() 2016-11-14 01:12:37 +01:00
Dustin Willis Webber ff841413b6
256 OutputMode support 2016-11-13 14:06:04 -05:00
Roi Martin aa4ac778d3 Move Editor into View. Update docs 2016-10-27 00:43:28 +02:00
Roi Martin c0ae071931 Use *Gui.{SelFgColor,SelBgColor} to set current view's color
- Use *Gui.{FgColor,BgColor} to set GUI's color.
- Use *Gui.{SelFgColor,SelBgColor} to set current view's color.
- Drop *Gui.ActiveColor and *View.ActiveColor.
2016-10-18 22:49:31 +02:00
Roi Martin 463428abda Minor refactoring. Update examples 2016-10-18 00:24:16 +02:00
Henri Koski 7779534f95 Add attribute ActiveColor to configure the color of the current view 2016-10-17 23:25:56 +02:00
Roi Martin d822523f8c Make golint happy. Fix typo. 2016-10-11 08:52:03 +02:00
Roi Martin 8d16527c1d Fix edition mode when Editable = true
Fix issue #53
2016-10-11 07:37:42 +02:00
Roi Martin 2e62b6ba19 Respect view's default background and foreground colors
Fix issue #58
2016-10-03 19:38:40 +02:00
Roi Martin a67a34cd60 Use View's default colors in View.writeRune 2016-05-23 00:16:59 +02:00
Roi Martin 40dec91023 Initial support for colored text
- View contents are stored as cells (rune + colors) instead of runes.
- Uses the escape interpreter coded by @deweerdt in #39.
2016-05-23 00:16:59 +02:00
Roi Martin 0707386452 Fix #50: highlight for wrapped lines 2016-05-17 22:40:24 +02:00
Roi Martin 7ffb37ef13 Add example for mask 2016-04-20 14:34:09 +02:00
Danny Tylman 65dfdbf77a Add support for masked views 2016-04-20 14:33:14 +02:00
Roi Martin bb01d13a95 Add view title (based on the implementation of @conejoninja) 2016-02-06 14:50:30 +01:00
Roi Martin 4aed924ceb Editor refactoring. Add doc. Simplify _examples. 2016-01-30 02:36:10 +01:00
Roi Martin e5bf60e36b Add method View.ViewBuffer 2015-08-16 18:08:34 +02:00
Roi Martin 4dfc4973e0 Decouple edition mode 2015-02-24 00:26:26 +01:00
Roi Martin 622e7cbdf9 Initial implementation of the full edition mode 2015-02-23 00:34:41 +01:00
Roi Martin b1ad4a9fa7 Remove internal call to View.SetCursor() and fix comment 2015-02-16 23:39:37 +01:00
Roi Martin 03998dd72c Refactor View.breakLine() 2015-02-15 02:17:13 +01:00
Roi Martin f53d985c4e Break lines on enter when needed 2015-02-14 20:17:44 +01:00
Roi Martin 0e85b51ed2 Remove View.WrapPrefix 2015-02-04 10:37:15 +01:00
Roi Martin 0992dc1df0 Fix bug in realPosition() when len(v.viewLines) == 0 2015-02-04 09:25:25 +01:00
Roi Martin 708261503b Fix edit mode when View.Wrap is enabled 2015-02-04 01:59:03 +01:00
Roi Martin b1d190d0d7 Convert View.viewLines to []viewLine 2015-02-03 18:29:38 +01:00
Roi Martin 0814e8024f More refactoring of View.draw() 2015-02-03 17:49:15 +01:00
Roi Martin 6279571a82 Fix build 2015-02-03 17:15:41 +01:00
Roi Martin 9b25959056 Optimizations on view redrawing when View.Wrap is enabled.
Refresh internal view buffer only when needed. Do not uses copy's.
2015-02-03 17:09:21 +01:00
Roi Martin 3607eb8e1c Implement autoscroll. Fix scroll when View.Wrap is enabled 2015-02-01 22:49:07 +01:00
Roi Martin 98a2fe7a6a Add missing LICENSE header. Fix typo in LICENSE headers 2015-01-31 20:39:43 +01:00
Roi Martin 17f7615184 Handle '\n' and '\r' in View.Write()
Handle '\n' and '\r' in View.Write() so fmt.Print, fmt.Println, etc. work as
expected. This commit closes issue #25.
2015-01-29 16:19:25 +01:00
Roi Martin a67c870eef Fix typos. 2014-11-15 13:50:56 +01:00
Roi Martin f78a0704f1 Minor fixes in Wrap
Print first character of the new line.
Control maxX and maxY to avoid invalid calls to View.SetRune.
Add error handling when calling View.SetRune.
2014-11-15 13:13:19 +01:00
Matthieu Rakotojaona 382efdcc54 Wrap content if too long 2014-11-14 20:52:05 +01:00
Roi Martin 0aed73291b Merge branch 'master' of https://github.com/KayoticSully/gocui into Frame 2014-10-18 15:35:01 +02:00
Ryan Sullivan 8d584203d4 Added Support to toggle View Frames 2014-10-17 17:22:28 -04:00
Roi Martin (@nibble_ds) cbacee3e65 Allow different colors per view 2014-05-03 15:20:46 +02:00
Roi Martin (@nibble_ds) 6b5681b670 Implement View.Read and View.Rewind. Update demo2 2014-05-01 14:32:30 +02:00
Roi Martin (@nibble_ds) 9f2bfa7213 Add View.Buffer() 2014-02-03 02:04:30 +01:00
Roi Martin (@nibble_ds) 7cc82f809e Fix View.Word() 2014-01-23 23:42:52 +01:00
Roi Martin (@nibble_ds) f51a568142 Fix typo in view.go 2014-01-23 23:14:11 +01:00
Roi Martin (@nibble_ds) a5dd7e25de Add functions View.Line() and View.Word() 2014-01-23 23:10:13 +01:00
Roi Martin (@nibble_ds) f9055c514a Fix deleteRune() 2014-01-23 00:46:15 +01:00
Roi Martin (@nibble_ds) 55e61228f1 Return errors in writeRune, deleteRune, addLine 2014-01-22 23:06:29 +01:00
Roi Martin (@nibble_ds) 19e6c59da4 Implement basic edition 2014-01-22 22:37:53 +01:00