Commit Graph

  • 6d8c8e76a9 add colrow_to_xy() and refactor to use it josh 2016-09-13 21:46:31 -04:00
  • 980ec3a295 draw cursor crosshairs josh 2016-09-13 21:25:10 -04:00
  • cde71ac70a keep a target cursor column to move to when moving cursor up or down josh 2016-09-12 21:38:13 -04:00
  • 7d3b66fe84 do not attempt to draw tab characters josh 2016-09-11 20:48:21 -04:00
  • f876b68bd0 Add cursor movements to move to SOL and EOL. josh 2016-09-07 22:31:24 -04:00
  • c2166b4bd1 warp cursor within scroll range on window resize josh 2016-09-07 22:06:53 -04:00
  • 7df23e971e Unlock cursor from first screen row josh 2016-09-06 22:58:33 -04:00
  • 7784024af1 remove Window::scroll_{up,down}() josh 2016-09-06 21:42:38 -04:00
  • a68ccb52e4 Do not redraw screen on cursor move if the cursor didn't actually move josh 2016-09-06 21:18:14 -04:00
  • 86246385d4 Draw text based on new cursor movement system josh 2016-09-06 21:05:24 -04:00
  • 01bf455e68 Use an OpenGL array object to draw the cursor josh 2016-08-27 17:36:31 -04:00
  • 33a190c495 complete cursor movement routines taking Encoding and tabs into account josh 2016-08-27 16:53:55 -04:00
  • b478d17e16 add Interator and Cursor constructors josh 2016-08-27 15:43:35 -04:00
  • d6b3810a3c Split some PieceTable::Cursor functionality into PieceTable::Iterator josh 2016-08-27 15:20:08 -04:00
  • f659c14242 add Encoding::decode() josh 2016-08-15 22:14:47 -04:00
  • b2bed71ee4 add Encoding::beginning_of_code_point() josh 2016-08-11 23:13:32 -04:00
  • 1aa9fb0c41 add Encoding::num_bytes_in_code_point() josh 2016-08-11 23:08:21 -04:00
  • 490505faa1 detect file encoding when loading it josh 2016-08-11 20:11:13 -04:00
  • c4253078a9 add Encoding class josh 2016-08-11 20:03:53 -04:00
  • 3c5a7b7341 add initial cursor movement support josh 2016-08-07 22:09:54 -04:00
  • 81e6a53c08 add PieceTable.tabstop attribute josh 2016-08-04 22:42:27 -04:00
  • f6338da8d0 add PieceTable::Cursor::operator*(), add unit test josh 2016-08-04 22:38:18 -04:00
  • abf853e1ba link from a piece table cursor object back to the containing piece table josh 2016-08-04 22:19:13 -04:00
  • 728e389c1e add column to a PieceTable::Cursor josh 2016-08-01 21:47:40 -04:00
  • 11cac3c8b5 add a PieceTable::Cursor to Window josh 2016-08-01 21:34:52 -04:00
  • e913c15212 remove number of characters from a Piece josh 2016-08-01 21:17:43 -04:00
  • b0553fdbd2 adjust font vertical position by baseline offset josh 2016-07-31 23:11:26 -04:00
  • 5a942a61a9 add FlatShader; draw a cursor josh 2016-07-31 23:08:26 -04:00
  • 8beea3461c Rework PieceTable cursor management josh 2016-07-31 22:11:12 -04:00
  • a5bfcdd3c4 remove PieceTable::ChangeDescriptor josh 2016-07-31 20:51:06 -04:00
  • 887fb4b980 use scoped enum instead of #define josh 2016-07-30 09:54:30 -04:00
  • 7064afc1f1 rename PieceDescriptor to just Piece josh 2016-07-30 09:52:46 -04:00
  • cef49e9e6e rename OpenGL "programs" to "shaders" josh 2016-07-29 21:27:32 -04:00
  • b61513b97e add PieceTable::get_start_of_line() josh 2016-07-29 21:19:01 -04:00
  • d043137099 Window: calculate m_rows josh 2016-07-29 21:07:10 -04:00
  • 862b414c1d Window: rename m_chars_per_line -> m_columns josh 2016-07-29 21:06:28 -04:00
  • dc71520a88 PieceTable: rename m_cursor_position -> cursor_position josh 2016-07-29 21:04:48 -04:00
  • 89c0ca0bfa add a cursor position attribute to PieceTable josh 2016-07-28 21:48:18 -04:00
  • 26f8fb355e allow File::write() to take a Span josh 2016-07-26 22:40:04 -04:00
  • 382d155e40 add LineEndings module josh 2016-07-26 22:36:22 -04:00
  • cdae9e51ae add Span class and use it from TextLoader josh 2016-07-26 21:09:33 -04:00
  • b64b9bed23 begin restructuring keyboard event handling more permanently josh 2016-07-24 22:45:28 -04:00
  • 31422709e8 Wrap lines josh 2016-07-24 20:35:01 -04:00
  • 10a0b33dbe Add Buffer unit tests josh 2016-07-24 17:25:21 -04:00
  • 63b3848424 Preserve whether there is a EOL at EOF when writing the file josh 2016-07-24 17:24:00 -04:00
  • e66130b603 fix File::open() when opening for writing josh 2016-07-24 17:06:56 -04:00
  • a416a47b29 add Buffer::write_to_file() josh 2016-07-24 12:50:27 -04:00
  • 1730838921 add File::write() josh 2016-07-24 12:37:34 -04:00
  • 0aad4fd779 GUI: avoid segfault when trying to scroll an empty buffer josh 2016-07-24 12:28:58 -04:00
  • 0780659c8c Buffer: keep track of eol_at_eof flag from TextLoader josh 2016-07-24 12:27:15 -04:00
  • 7093560a94 Support loading files that do not end with a EOL sequence josh 2016-07-24 12:22:03 -04:00
  • 89e8dc5de3 add TextLoader::get_eol_at_eof() josh 2016-07-24 12:06:50 -04:00
  • 500a6891d4 remove Text module josh 2016-07-19 22:35:51 -04:00
  • 20a2786755 Render from the piece table! josh 2016-07-19 22:34:11 -04:00
  • e52710b47c add PieceTable::append_initial_line_piece() josh 2016-07-19 21:31:06 -04:00
  • 8fcbad02f8 Update PieceDescriptor structure - use direct pointers for list links josh 2016-07-18 22:32:45 -04:00
  • ebf92f07ac drop const in TextLoader line pointer josh 2016-07-18 22:07:29 -04:00
  • aa45f6d6dc Add a PieceTable to Buffer josh 2016-07-18 22:04:57 -04:00
  • 2805ac36d3 add PieceTable::start_descriptor and PieceTable::end_descriptor josh 2016-07-18 22:02:56 -04:00
  • 793bc46293 add PieceTable::add_piece_descriptor() and set up start/end descriptors josh 2016-07-18 22:01:33 -04:00
  • b30b6eb202 Start on PieceTable josh 2016-07-17 23:05:02 -04:00
  • 7e8b5c0b64 Allow PagedBuffer to hold non-power-of-2-sized objects josh 2016-07-17 21:55:29 -04:00
  • cab874305f add PagedBuffer; use own main() for tests josh 2016-07-17 20:43:18 -04:00
  • 3be19dbf81 implement TextLoader tests, add TestSupport module josh 2016-07-16 21:26:42 -04:00
  • 181d3ad64a Avoid signed and unsigned comparison josh 2016-07-15 19:58:01 -04:00
  • f9b42b4079 add "test" Makefile target josh 2016-07-15 19:42:48 -04:00
  • a2bd7504b5 replace FileLoader with TextLoader josh 2016-07-14 21:28:38 -04:00
  • cae0b581a2 Buffer owns the file buffer josh 2016-07-14 20:06:22 -04:00
  • 5f8bbcfca4 start a Timer when it is created josh 2016-07-14 19:27:39 -04:00
  • e562f77dab replace FileReader with File class; prepare for removing FileLoader josh 2016-07-14 18:44:18 -04:00
  • 5a8894498b add System::free_pages() josh 2016-07-14 18:42:26 -04:00
  • ef6abd8ed7 Add other useful page-size-related fields to System module josh 2016-07-14 17:51:53 -04:00
  • 48e82a11a3 add initial System module josh 2016-07-13 21:41:30 -04:00
  • 5bcd55ba97 add custom key repeat handler to allow for user-configurable, mode-dependent key repeats josh 2016-07-10 21:23:49 -04:00
  • dd7a5de619 add Timer josh 2016-07-10 20:42:38 -04:00
  • b1684f1341 scroll through file with J/K keys josh 2016-07-10 20:13:40 -04:00
  • d8fcbcd428 render a file's contents josh 2016-07-10 17:24:00 -04:00
  • 5da9cde758 Buffer: hold on to the FileLoader for now so the memory is not released josh 2016-07-10 17:23:30 -04:00
  • f31fac64ba disable scissor test josh 2016-07-10 17:02:21 -04:00
  • 3fdc113b5f add Font::get_line_height() josh 2016-07-10 16:31:32 -04:00
  • eacfe407b4 just use plain white for now josh 2016-07-10 16:31:23 -04:00
  • 4c7934e133 build with -O2 josh 2016-07-10 16:27:31 -04:00
  • 6cf59fa7d7 draw some test text in Window for now josh 2016-07-10 16:26:37 -04:00
  • d2f39cbddc add TextProgram josh 2016-07-10 16:21:58 -04:00
  • 54b7e302d0 bind the Glyph texture when rendering the Glyph josh 2016-07-08 21:04:49 -04:00
  • c147cbad3f add Font::get_advance() josh 2016-07-08 21:01:20 -04:00
  • f31c1c2532 tweak wscript: avoid define for having header; rename freetype2 uselib_store josh 2016-07-08 20:45:31 -04:00
  • 207178abba update waf to v1.9.1 josh 2016-07-08 20:42:47 -04:00
  • 5b36a220f7 fix Window::handle_event() comment josh 2016-07-08 19:44:33 -04:00
  • bd1f1bd655 add APPNAME and VERSION defines josh 2016-07-08 19:12:52 -04:00
  • 40b6518ea4 remove GL module josh 2016-07-08 18:44:27 -04:00
  • ea6613a891 change shaders to #version 130 josh 2016-07-07 21:23:47 -04:00
  • a08bc144e2 Add initial Runtime module josh 2016-07-06 23:09:53 -04:00
  • ff51d17344 add Path::listdir() josh 2016-07-06 22:14:27 -04:00
  • 5df998661b rename runtime -> share/jes josh 2016-07-06 21:34:36 -04:00
  • 725a0f22a1 allow Path::join() to take an arbitrary number of arguments josh 2016-07-06 21:32:47 -04:00
  • 2012591b27 add Path::is_file() and Path::is_dir() josh 2016-07-06 19:40:35 -04:00
  • 1f9a981e6a add initial Path class josh 2016-07-06 19:21:35 -04:00
  • b58c344604 rename FileReader::load() -> FileReader::read() josh 2016-07-05 19:10:32 -04:00
  • 1e140f9229 add "text" shader josh 2016-07-05 19:06:06 -04:00