diff options
Diffstat (limited to 'src/calcurse.h')
-rw-r--r-- | src/calcurse.h | 33 |
1 files changed, 30 insertions, 3 deletions
diff --git a/src/calcurse.h b/src/calcurse.h index e3822ef..b94da61 100644 --- a/src/calcurse.h +++ b/src/calcurse.h @@ -200,6 +200,15 @@ #define TOSTRING(x) STRINGIFY(x) #define __FILE_POS__ __FILE__ ":" TOSTRING(__LINE__) +#define UTF8_MAXLEN 6 +#define UTF8_LENGTH(ch) ((unsigned char)ch >= 0xFC ? 6 : \ + ((unsigned char)ch >= 0xF8 ? 5 : \ + ((unsigned char)ch >= 0xF0 ? 4 : \ + ((unsigned char)ch >= 0xE0 ? 3 : \ + ((unsigned char)ch >= 0xC0 ? 2 : 1))))) +#define UTF8_ISCONT(ch) ((unsigned char)ch >= 0x80 && \ + (unsigned char)ch <= 0xBF) + #define MAX(x,y) ((x)>(y)?(x):(y)) #define MIN(x,y) ((x)<(y)?(x):(y)) @@ -392,6 +401,7 @@ enum key { KEY_DEL_ITEM, KEY_EDIT_ITEM, KEY_VIEW_ITEM, + KEY_PIPE_ITEM, KEY_FLAG_ITEM, KEY_REPEAT_ITEM, KEY_EDIT_NOTE, @@ -628,6 +638,7 @@ struct day_item *day_get_item (int); int day_item_nb (long, int, int); void day_edit_note (char *); void day_view_note (char *); +void day_pipe_item (struct conf *); /* dmon.c */ void dmon_start (int); @@ -650,6 +661,10 @@ void event_paste_item (void); void help_wins_init (struct scrollwin *, int, int, int, int); void help_screen (void); +/* getstring.c */ +enum getstr getstring (WINDOW *, char *, int, int, int); +int updatestring (WINDOW *, char **, int, int); + /* io.c */ unsigned io_fprintln (const char *, const char *, ...); void io_init (char *, char *); @@ -778,6 +793,8 @@ struct recur_apoint *recur_apoint_scan (FILE *, struct tm, struct tm, struct recur_event *recur_event_scan (FILE *, struct tm, int, char, int, struct tm, char *, llist_t *); +void recur_apoint_write (struct recur_apoint *, FILE *); +void recur_event_write (struct recur_event *, FILE *); void recur_save_data (FILE *); unsigned recur_item_inday (long, llist_t *, int, int, long, long); unsigned recur_apoint_inday(struct recur_apoint *, long); @@ -814,6 +831,7 @@ int todo_hilt_pos (void); char *todo_saved_mesg (void); void todo_new_item (void); struct todo *todo_add (char *, int, char *); +void todo_write (struct todo *, FILE *); void todo_flag (void); void todo_delete (struct conf *); void todo_chg_priority (int); @@ -821,9 +839,14 @@ void todo_edit_item (void); void todo_update_panel (int); void todo_edit_note (char *); void todo_view_note (char *); +void todo_pipe_item (void); void todo_init_list (void); void todo_free_list (void); +/* utf8.c */ +int utf8_width (char *); +int utf8_strwidth (char *); + /* utils.c */ void exit_calcurse (int) __attribute__((__noreturn__)); void free_user_data (void); @@ -833,8 +856,6 @@ void status_mesg (char *, char *); void erase_window_part (WINDOW *, int, int, int, int); WINDOW *popup (int, int, int, int, char *, char *, int); void print_in_middle (WINDOW *, int, int, int, char *); -enum getstr getstring (WINDOW *, char *, int, int, int); -int updatestring (WINDOW *, char **, int, int); int is_all_digit (char *); long get_item_time (long); int get_item_hour (long); @@ -862,6 +883,10 @@ int parse_date (char *, enum datefmt, int *, int *, int *, void str_toupper (char *); void file_close (FILE *, const char *); void psleep (unsigned); +int fork_exec (int *, int *, const char *, char *const *); +int shell_exec (int *, int *, char *); +int child_wait (int *, int *, int); +void press_any_key (void); /* vars.c */ extern int col, row; @@ -915,7 +940,9 @@ void wins_update_border (void); void wins_update_panels (void); void wins_update (void); void wins_reset (void); -void wins_launch_external (const char *, const char *); +void wins_prepare_external (void); +void wins_unprepare_external (void); +void wins_launch_external (char *, char *); void wins_status_bar (void); void wins_erase_status_bar (void); void wins_other_status_page (int); |