Data Fields | |
| wchar_t * | buff |
| Buffer containing the whole current commandline. | |
| screen_t | screen |
| The representation of the current screen contents. | |
| string_buffer_t | search_buff |
| Buffer containing the current search item. | |
| int | token_history_pos |
| Saved position used by token history search. | |
| const wchar_t * | token_history_buff |
| Saved search string for token history search. | |
| array_list_t | search_prev |
| List for storing previous search results. | |
| int | search_pos |
| The current position in search_prev. | |
| size_t | buff_sz |
| Current size of the buffers. | |
| size_t | buff_len |
| Length of the command in buff. | |
| size_t | buff_pos |
| The current position of the cursor in buff. | |
| wchar_t * | name |
| Name of the current application. | |
| wchar_t * | prompt |
| The prompt command. | |
| string_buffer_t | prompt_buff |
| The output of the last evaluation of the prompt command. | |
| int * | color |
| Color is the syntax highlighting for buff. | |
| int * | indent |
| An array defining the block level at each character. | |
| void(* | complete_func )(const wchar_t *, array_list_t *) |
| Function for tab completion. | |
| void(* | highlight_func )(wchar_t *, int *, int, array_list_t *) |
| Function for syntax highlighting. | |
| int(* | test_func )(wchar_t *) |
| Function for testing if the string can be returned. | |
| int | end_loop |
| When this is true, the reader will exit. | |
| int | prev_end_loop |
| If this is true, exit reader even if there are running jobs. | |
| string_buffer_t | kill_item |
| The current contents of the top item in the kill ring. | |
| struct reader_data * | next |
| Pointer to previous reader_data. | |
| int | search_mode |
| This variable keeps state on if we are in search mode, and if yes, what mode. | |
| int | repaint_needed |
| Keep track of whether any internal code has done something which is known to require a repaint. | |
These states can be stacked, in case reader_readline() calls are nested. This happens when the 'read' builtin is used.
| const wchar_t* reader_data::token_history_buff |
Saved search string for token history search.
Not handled by check_size.
Referenced by handle_token_history(), reader_pop(), and reader_push().
List for storing previous search results.
Used to avoid duplicates.
Referenced by handle_token_history(), reader_pop(), reader_push(), and reset_token_history().
| size_t reader_data::buff_len |
Length of the command in buff.
(Not the length of buff itself)
Referenced by check_size(), handle_history(), insert_str(), move_word(), read_i(), reader_kill(), reader_readline(), reader_sanity_check(), reader_set_buffer(), and remove_backward().
| int* reader_data::color |
Color is the syntax highlighting for buff.
The format is that color[i] is the classification (according to the enum in highlight.h) of buff[i].
Referenced by check_size(), reader_flash(), reader_pop(), reader_repaint(), and reader_super_highlight_me_plenty().
If this is true, exit reader even if there are running jobs.
This happens if we press e.g. ^D twice.
Referenced by handle_end_loop(), and read_i().
1.5.6