From d639b8b4ed0d43c889f65c9972d1c4ff925bb97d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Enrico=20Tr=C3=B6ger?= Date: Fri, 24 Jul 2009 09:59:23 +0000 Subject: [PATCH 01/63] Attempt to fix reshowing calltips after the autocompletion list has been shown. git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@4021 ea778897-0a13-0410-b9d1-a72fbfd435f5 --- ChangeLog | 7 +++++++ src/editor.c | 28 +++++++++++++++++++++------- 2 files changed, 28 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index 039f31b6..0f396008 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2009-07-24 Enrico Tröger + + * src/editor.c: + Attempt to fix reshowing calltips after the autocompletion list + has been shown. + + 2009-07-23 Nick Treleaven * src/utils.c, src/utils.h, src/toolbar.c, src/plugindata.h, diff --git a/src/editor.c b/src/editor.c index c5904253..60b8ece2 100644 --- a/src/editor.c +++ b/src/editor.c @@ -714,9 +714,17 @@ static void ensure_range_visible(ScintillaObject *sci, gint posStart, gint posEn } +typedef struct +{ + gint message; + gint pos; + gchar *text; +} CalltipReshowInfo; + + static gboolean reshow_calltip(gpointer data) { - SCNotification *nt = data; + CalltipReshowInfo *cri = data; g_return_val_if_fail(calltip.sci != NULL, FALSE); @@ -726,16 +734,19 @@ static gboolean reshow_calltip(gpointer data) SSM(calltip.sci, SCI_CALLTIPSHOW, calltip.pos, (sptr_t) calltip.text); /* now autocompletion has been cancelled by SCI_CALLTIPSHOW, so do it manually */ - if (nt->nmhdr.code == SCN_AUTOCSELECTION) + if (cri->message == SCN_AUTOCSELECTION) { gint pos = SSM(calltip.sci, SCI_GETCURRENTPOS, 0, 0); - sci_set_selection_start(calltip.sci, nt->lParam); + sci_set_selection_start(calltip.sci, cri->pos); sci_set_selection_end(calltip.sci, pos); sci_replace_sel(calltip.sci, ""); /* clear root of word */ - SSM(calltip.sci, SCI_INSERTTEXT, nt->lParam, (sptr_t) nt->text); - sci_goto_pos(calltip.sci, nt->lParam + strlen(nt->text), FALSE); + SSM(calltip.sci, SCI_INSERTTEXT, cri->pos, (sptr_t) cri->text); + sci_goto_pos(calltip.sci, cri->pos + strlen(cri->text), FALSE); } + g_free(cri->text); + g_free(cri); + return FALSE; } @@ -848,10 +859,13 @@ static gboolean on_editor_notify(G_GNUC_UNUSED GObject *object, GeanyEditor *edi * if they were showing */ if (calltip.set) { + CalltipReshowInfo *cri = g_new0(CalltipReshowInfo, 1); + cri->message = nt->nmhdr.code; + cri->message = nt->lParam; + cri->text = g_strdup(nt->text); /* delay the reshow of the calltip window to make sure it is actually displayed, * without it might be not visible on SCN_AUTOCCANCEL */ - /* TODO g_idle_add() seems to be not enough, only with a timeout it works stable */ - g_timeout_add(50, reshow_calltip, nt); + g_idle_add(reshow_calltip, cri); } break; } From 8295be5367904310a8ff3ce9e36d116844d90be7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Enrico=20Tr=C3=B6ger?= Date: Fri, 24 Jul 2009 10:40:48 +0000 Subject: [PATCH 02/63] Reshow calltips also when the autocompletion list was closed implicitly by not choosing an item. git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@4022 ea778897-0a13-0410-b9d1-a72fbfd435f5 --- ChangeLog | 2 + src/editor.c | 102 +++++++++++++++++++++++++++------------------------ 2 files changed, 56 insertions(+), 48 deletions(-) diff --git a/ChangeLog b/ChangeLog index 0f396008..534e40d9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,6 +3,8 @@ * src/editor.c: Attempt to fix reshowing calltips after the autocompletion list has been shown. + Reshow calltips also when the autocompletion list was closed + implicitly by not choosing an item. 2009-07-23 Nick Treleaven diff --git a/src/editor.c b/src/editor.c index 60b8ece2..65f0ff2c 100644 --- a/src/editor.c +++ b/src/editor.c @@ -490,6 +490,57 @@ static gboolean match_last_chars(ScintillaObject *sci, gint pos, const gchar *st } +typedef struct +{ + gint message; + gint pos; + gchar *text; +} CalltipReshowInfo; + + +static gboolean reshow_calltip(gpointer data) +{ + CalltipReshowInfo *cri = data; + + g_return_val_if_fail(calltip.sci != NULL, FALSE); + + SSM(calltip.sci, SCI_CALLTIPCANCEL, 0, 0); + /* we use the position where the calltip was previously started as SCI_GETCURRENTPOS + * may be completely wrong in case the user cancelled the auto completion with the mouse */ + SSM(calltip.sci, SCI_CALLTIPSHOW, calltip.pos, (sptr_t) calltip.text); + + /* now autocompletion has been cancelled by SCI_CALLTIPSHOW, so do it manually */ + if (cri->message == SCN_AUTOCSELECTION) + { + gint pos = SSM(calltip.sci, SCI_GETCURRENTPOS, 0, 0); + + sci_set_selection_start(calltip.sci, cri->pos); + sci_set_selection_end(calltip.sci, pos); + sci_replace_sel(calltip.sci, ""); /* clear root of word */ + SSM(calltip.sci, SCI_INSERTTEXT, cri->pos, (sptr_t) cri->text); + sci_goto_pos(calltip.sci, cri->pos + strlen(cri->text), FALSE); + } + g_free(cri->text); + g_free(cri); + + return FALSE; +} + + +static void request_reshowing_calltip(SCNotification *nt) +{ + if (calltip.set) + { + CalltipReshowInfo *cri = g_new0(CalltipReshowInfo, 1); + cri->message = nt->nmhdr.code; + cri->message = nt->lParam; + cri->text = g_strdup(nt->text); + /* delay the reshow of the calltip window to make sure it is actually displayed, + * without it might be not visible on SCN_AUTOCCANCEL */ + g_idle_add(reshow_calltip, cri); + } +} + static void autocomplete_scope(GeanyEditor *editor) { ScintillaObject *sci = editor->sci; @@ -601,7 +652,8 @@ static void on_char_added(GeanyEditor *editor, SCNotification *nt) case ':': /* C/C++ class:: syntax */ /* tag autocompletion */ default: - editor_start_auto_complete(editor, pos, FALSE); + if (! editor_start_auto_complete(editor, pos, FALSE)) + request_reshowing_calltip(nt); } check_line_breaking(editor, pos, nt->ch); } @@ -714,43 +766,6 @@ static void ensure_range_visible(ScintillaObject *sci, gint posStart, gint posEn } -typedef struct -{ - gint message; - gint pos; - gchar *text; -} CalltipReshowInfo; - - -static gboolean reshow_calltip(gpointer data) -{ - CalltipReshowInfo *cri = data; - - g_return_val_if_fail(calltip.sci != NULL, FALSE); - - SSM(calltip.sci, SCI_CALLTIPCANCEL, 0, 0); - /* we use the position where the calltip was previously started as SCI_GETCURRENTPOS - * may be completely wrong in case the user cancelled the auto completion with the mouse */ - SSM(calltip.sci, SCI_CALLTIPSHOW, calltip.pos, (sptr_t) calltip.text); - - /* now autocompletion has been cancelled by SCI_CALLTIPSHOW, so do it manually */ - if (cri->message == SCN_AUTOCSELECTION) - { - gint pos = SSM(calltip.sci, SCI_GETCURRENTPOS, 0, 0); - - sci_set_selection_start(calltip.sci, cri->pos); - sci_set_selection_end(calltip.sci, pos); - sci_replace_sel(calltip.sci, ""); /* clear root of word */ - SSM(calltip.sci, SCI_INSERTTEXT, cri->pos, (sptr_t) cri->text); - sci_goto_pos(calltip.sci, cri->pos + strlen(cri->text), FALSE); - } - g_free(cri->text); - g_free(cri); - - return FALSE; -} - - static void auto_update_margin_width(GeanyEditor *editor) { gint next_linecount = 1; @@ -857,16 +872,7 @@ static gboolean on_editor_notify(G_GNUC_UNUSED GObject *object, GeanyEditor *edi { /* now that autocomplete is finishing or was cancelled, reshow calltips * if they were showing */ - if (calltip.set) - { - CalltipReshowInfo *cri = g_new0(CalltipReshowInfo, 1); - cri->message = nt->nmhdr.code; - cri->message = nt->lParam; - cri->text = g_strdup(nt->text); - /* delay the reshow of the calltip window to make sure it is actually displayed, - * without it might be not visible on SCN_AUTOCCANCEL */ - g_idle_add(reshow_calltip, cri); - } + request_reshowing_calltip(nt); break; } #ifdef GEANY_DEBUG From 88ae507fafb87e6f5d0af5c47a8d788bebe820c2 Mon Sep 17 00:00:00 2001 From: Nick Treleaven Date: Fri, 24 Jul 2009 14:31:43 +0000 Subject: [PATCH 03/63] Use full styleset_foo[_init] function name as argument to init_styleset_case() and styleset_case() macros so it's easier to understand the code. git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@4024 ea778897-0a13-0410-b9d1-a72fbfd435f5 --- ChangeLog | 8 ++ src/highlighting.c | 184 ++++++++++++++++++++++----------------------- 2 files changed, 100 insertions(+), 92 deletions(-) diff --git a/ChangeLog b/ChangeLog index 534e40d9..ff57c39d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2009-07-24 Nick Treleaven + + * src/highlighting.c: + Use full styleset_foo[_init] function name as argument to + init_styleset_case() and styleset_case() macros so it's easier to + understand the code. + + 2009-07-24 Enrico Tröger * src/editor.c: diff --git a/src/highlighting.c b/src/highlighting.c index 92d9e3e1..595c46e0 100644 --- a/src/highlighting.c +++ b/src/highlighting.c @@ -3554,10 +3554,10 @@ static void styleset_ada(ScintillaObject *sci) /* lang_name is the name used for the styleset_foo_init function, e.g. foo. */ -#define init_styleset_case(ft_id, lang_name) \ +#define init_styleset_case(ft_id, init_styleset_func) \ case (ft_id): \ - styleset_ ## lang_name ## _init(filetype_idx, config, configh); \ - break; + init_styleset_func(filetype_idx, config, configh); \ + break /* Called by filetypes_load_config(). */ void highlighting_init_styles(gint filetype_idx, GKeyFile *config, GKeyFile *configh) @@ -3571,58 +3571,58 @@ void highlighting_init_styles(gint filetype_idx, GKeyFile *config, GKeyFile *con switch (filetype_idx) { - init_styleset_case(GEANY_FILETYPES_NONE, common); - init_styleset_case(GEANY_FILETYPES_ADA, ada); - init_styleset_case(GEANY_FILETYPES_ASM, asm); - init_styleset_case(GEANY_FILETYPES_BASIC, basic); - init_styleset_case(GEANY_FILETYPES_C, c); - init_styleset_case(GEANY_FILETYPES_CAML, caml); - init_styleset_case(GEANY_FILETYPES_CMAKE, cmake); - init_styleset_case(GEANY_FILETYPES_CONF, conf); - init_styleset_case(GEANY_FILETYPES_CPP, cpp); - init_styleset_case(GEANY_FILETYPES_CS, cs); - init_styleset_case(GEANY_FILETYPES_CSS, css); - init_styleset_case(GEANY_FILETYPES_D, d); - init_styleset_case(GEANY_FILETYPES_DIFF, diff); - init_styleset_case(GEANY_FILETYPES_DOCBOOK, docbook); - init_styleset_case(GEANY_FILETYPES_FERITE, ferite); - init_styleset_case(GEANY_FILETYPES_F77, f77); - init_styleset_case(GEANY_FILETYPES_FORTRAN, fortran); - init_styleset_case(GEANY_FILETYPES_GLSL, glsl); - init_styleset_case(GEANY_FILETYPES_HASKELL, haskell); - init_styleset_case(GEANY_FILETYPES_HAXE, haxe); - init_styleset_case(GEANY_FILETYPES_AS, actionscript); - init_styleset_case(GEANY_FILETYPES_HTML, html); - init_styleset_case(GEANY_FILETYPES_JAVA, java); - init_styleset_case(GEANY_FILETYPES_JS, js); - init_styleset_case(GEANY_FILETYPES_LATEX, latex); - init_styleset_case(GEANY_FILETYPES_LUA, lua); - init_styleset_case(GEANY_FILETYPES_MAKE, makefile); - init_styleset_case(GEANY_FILETYPES_MATLAB, matlab); - init_styleset_case(GEANY_FILETYPES_NSIS, nsis); - init_styleset_case(GEANY_FILETYPES_PASCAL, pascal); - init_styleset_case(GEANY_FILETYPES_PERL, perl); - init_styleset_case(GEANY_FILETYPES_PHP, php); - init_styleset_case(GEANY_FILETYPES_PO, po); - init_styleset_case(GEANY_FILETYPES_PYTHON, python); - init_styleset_case(GEANY_FILETYPES_R, r); - init_styleset_case(GEANY_FILETYPES_RUBY, ruby); - init_styleset_case(GEANY_FILETYPES_SH, sh); - init_styleset_case(GEANY_FILETYPES_SQL, sql); - init_styleset_case(GEANY_FILETYPES_TCL, tcl); - init_styleset_case(GEANY_FILETYPES_VALA, vala); - init_styleset_case(GEANY_FILETYPES_VHDL, vhdl); - init_styleset_case(GEANY_FILETYPES_XML, markup); - init_styleset_case(GEANY_FILETYPES_YAML, yaml); + init_styleset_case(GEANY_FILETYPES_NONE, styleset_common_init); + init_styleset_case(GEANY_FILETYPES_ADA, styleset_ada_init); + init_styleset_case(GEANY_FILETYPES_ASM, styleset_asm_init); + init_styleset_case(GEANY_FILETYPES_BASIC, styleset_basic_init); + init_styleset_case(GEANY_FILETYPES_C, styleset_c_init); + init_styleset_case(GEANY_FILETYPES_CAML, styleset_caml_init); + init_styleset_case(GEANY_FILETYPES_CMAKE, styleset_cmake_init); + init_styleset_case(GEANY_FILETYPES_CONF, styleset_conf_init); + init_styleset_case(GEANY_FILETYPES_CPP, styleset_cpp_init); + init_styleset_case(GEANY_FILETYPES_CS, styleset_cs_init); + init_styleset_case(GEANY_FILETYPES_CSS, styleset_css_init); + init_styleset_case(GEANY_FILETYPES_D, styleset_d_init); + init_styleset_case(GEANY_FILETYPES_DIFF, styleset_diff_init); + init_styleset_case(GEANY_FILETYPES_DOCBOOK, styleset_docbook_init); + init_styleset_case(GEANY_FILETYPES_FERITE, styleset_ferite_init); + init_styleset_case(GEANY_FILETYPES_F77, styleset_f77_init); + init_styleset_case(GEANY_FILETYPES_FORTRAN, styleset_fortran_init); + init_styleset_case(GEANY_FILETYPES_GLSL, styleset_glsl_init); + init_styleset_case(GEANY_FILETYPES_HASKELL, styleset_haskell_init); + init_styleset_case(GEANY_FILETYPES_HAXE, styleset_haxe_init); + init_styleset_case(GEANY_FILETYPES_AS, styleset_actionscript_init); + init_styleset_case(GEANY_FILETYPES_HTML, styleset_html_init); + init_styleset_case(GEANY_FILETYPES_JAVA, styleset_java_init); + init_styleset_case(GEANY_FILETYPES_JS, styleset_js_init); + init_styleset_case(GEANY_FILETYPES_LATEX, styleset_latex_init); + init_styleset_case(GEANY_FILETYPES_LUA, styleset_lua_init); + init_styleset_case(GEANY_FILETYPES_MAKE, styleset_makefile_init); + init_styleset_case(GEANY_FILETYPES_MATLAB, styleset_matlab_init); + init_styleset_case(GEANY_FILETYPES_NSIS, styleset_nsis_init); + init_styleset_case(GEANY_FILETYPES_PASCAL, styleset_pascal_init); + init_styleset_case(GEANY_FILETYPES_PERL, styleset_perl_init); + init_styleset_case(GEANY_FILETYPES_PHP, styleset_php_init); + init_styleset_case(GEANY_FILETYPES_PO, styleset_po_init); + init_styleset_case(GEANY_FILETYPES_PYTHON, styleset_python_init); + init_styleset_case(GEANY_FILETYPES_R, styleset_r_init); + init_styleset_case(GEANY_FILETYPES_RUBY, styleset_ruby_init); + init_styleset_case(GEANY_FILETYPES_SH, styleset_sh_init); + init_styleset_case(GEANY_FILETYPES_SQL, styleset_sql_init); + init_styleset_case(GEANY_FILETYPES_TCL, styleset_tcl_init); + init_styleset_case(GEANY_FILETYPES_VALA, styleset_vala_init); + init_styleset_case(GEANY_FILETYPES_VHDL, styleset_vhdl_init); + init_styleset_case(GEANY_FILETYPES_XML, styleset_markup_init); + init_styleset_case(GEANY_FILETYPES_YAML, styleset_yaml_init); } } /* lang_name is the name used for the styleset_foo function, e.g. foo. */ -#define styleset_case(ft_id, lang_name) \ +#define styleset_case(ft_id, styleset_func) \ case (ft_id): \ - styleset_ ## lang_name (sci); \ - break; + styleset_func (sci); \ + break void highlighting_set_styles(ScintillaObject *sci, gint filetype_idx) { @@ -3634,50 +3634,50 @@ void highlighting_set_styles(ScintillaObject *sci, gint filetype_idx) switch (filetype_idx) { - styleset_case(GEANY_FILETYPES_ADA, ada); - styleset_case(GEANY_FILETYPES_ASM, asm); - styleset_case(GEANY_FILETYPES_BASIC, basic); - styleset_case(GEANY_FILETYPES_C, c); - styleset_case(GEANY_FILETYPES_CAML, caml); - styleset_case(GEANY_FILETYPES_CMAKE, cmake); - styleset_case(GEANY_FILETYPES_CONF, conf); - styleset_case(GEANY_FILETYPES_CPP, cpp); - styleset_case(GEANY_FILETYPES_CS, cs); - styleset_case(GEANY_FILETYPES_CSS, css); - styleset_case(GEANY_FILETYPES_D, d); - styleset_case(GEANY_FILETYPES_DIFF, diff); - styleset_case(GEANY_FILETYPES_DOCBOOK, docbook); - styleset_case(GEANY_FILETYPES_FERITE, ferite); - styleset_case(GEANY_FILETYPES_F77, f77); - styleset_case(GEANY_FILETYPES_FORTRAN, fortran); - styleset_case(GEANY_FILETYPES_GLSL, glsl); - styleset_case(GEANY_FILETYPES_HASKELL, haskell); - styleset_case(GEANY_FILETYPES_HAXE, haxe); - styleset_case(GEANY_FILETYPES_AS, actionscript); - styleset_case(GEANY_FILETYPES_HTML, html); - styleset_case(GEANY_FILETYPES_JAVA, java); - styleset_case(GEANY_FILETYPES_JS, js); - styleset_case(GEANY_FILETYPES_LATEX, latex); - styleset_case(GEANY_FILETYPES_LUA, lua); - styleset_case(GEANY_FILETYPES_MAKE, makefile); - styleset_case(GEANY_FILETYPES_MATLAB, matlab); - styleset_case(GEANY_FILETYPES_NSIS, nsis); - styleset_case(GEANY_FILETYPES_PASCAL, pascal); - styleset_case(GEANY_FILETYPES_PERL, perl); - styleset_case(GEANY_FILETYPES_PHP, php); - styleset_case(GEANY_FILETYPES_PO, po); - styleset_case(GEANY_FILETYPES_PYTHON, python); - styleset_case(GEANY_FILETYPES_R, r); - styleset_case(GEANY_FILETYPES_RUBY, ruby); - styleset_case(GEANY_FILETYPES_SH, sh); - styleset_case(GEANY_FILETYPES_SQL, sql); - styleset_case(GEANY_FILETYPES_TCL, tcl); - styleset_case(GEANY_FILETYPES_VALA, vala); - styleset_case(GEANY_FILETYPES_VHDL, vhdl); - styleset_case(GEANY_FILETYPES_XML, xml); - styleset_case(GEANY_FILETYPES_YAML, yaml); + styleset_case(GEANY_FILETYPES_ADA, styleset_ada); + styleset_case(GEANY_FILETYPES_ASM, styleset_asm); + styleset_case(GEANY_FILETYPES_BASIC, styleset_basic); + styleset_case(GEANY_FILETYPES_C, styleset_c); + styleset_case(GEANY_FILETYPES_CAML, styleset_caml); + styleset_case(GEANY_FILETYPES_CMAKE, styleset_cmake); + styleset_case(GEANY_FILETYPES_CONF, styleset_conf); + styleset_case(GEANY_FILETYPES_CPP, styleset_cpp); + styleset_case(GEANY_FILETYPES_CS, styleset_cs); + styleset_case(GEANY_FILETYPES_CSS, styleset_css); + styleset_case(GEANY_FILETYPES_D, styleset_d); + styleset_case(GEANY_FILETYPES_DIFF, styleset_diff); + styleset_case(GEANY_FILETYPES_DOCBOOK, styleset_docbook); + styleset_case(GEANY_FILETYPES_FERITE, styleset_ferite); + styleset_case(GEANY_FILETYPES_F77, styleset_f77); + styleset_case(GEANY_FILETYPES_FORTRAN, styleset_fortran); + styleset_case(GEANY_FILETYPES_GLSL, styleset_glsl); + styleset_case(GEANY_FILETYPES_HASKELL, styleset_haskell); + styleset_case(GEANY_FILETYPES_HAXE, styleset_haxe); + styleset_case(GEANY_FILETYPES_AS, styleset_actionscript); + styleset_case(GEANY_FILETYPES_HTML, styleset_html); + styleset_case(GEANY_FILETYPES_JAVA, styleset_java); + styleset_case(GEANY_FILETYPES_JS, styleset_js); + styleset_case(GEANY_FILETYPES_LATEX, styleset_latex); + styleset_case(GEANY_FILETYPES_LUA, styleset_lua); + styleset_case(GEANY_FILETYPES_MAKE, styleset_makefile); + styleset_case(GEANY_FILETYPES_MATLAB, styleset_matlab); + styleset_case(GEANY_FILETYPES_NSIS, styleset_nsis); + styleset_case(GEANY_FILETYPES_PASCAL, styleset_pascal); + styleset_case(GEANY_FILETYPES_PERL, styleset_perl); + styleset_case(GEANY_FILETYPES_PHP, styleset_php); + styleset_case(GEANY_FILETYPES_PO, styleset_po); + styleset_case(GEANY_FILETYPES_PYTHON, styleset_python); + styleset_case(GEANY_FILETYPES_R, styleset_r); + styleset_case(GEANY_FILETYPES_RUBY, styleset_ruby); + styleset_case(GEANY_FILETYPES_SH, styleset_sh); + styleset_case(GEANY_FILETYPES_SQL, styleset_sql); + styleset_case(GEANY_FILETYPES_TCL, styleset_tcl); + styleset_case(GEANY_FILETYPES_VALA, styleset_vala); + styleset_case(GEANY_FILETYPES_VHDL, styleset_vhdl); + styleset_case(GEANY_FILETYPES_XML, styleset_xml); + styleset_case(GEANY_FILETYPES_YAML, styleset_yaml); default: - styleset_case(GEANY_FILETYPES_NONE, none); + styleset_case(GEANY_FILETYPES_NONE, styleset_none); } } From aa89783b748ae2f8eb3bb249bac27ed06d1ab9bd Mon Sep 17 00:00:00 2001 From: Nick Treleaven Date: Fri, 24 Jul 2009 15:44:14 +0000 Subject: [PATCH 04/63] Add 'Reflow lines/paragraph' keybinding, defaults to Ctrl-J. Heavily based on a patch by Eugene Arshinov (thanks). Add sci_lines_split(), sci_lines_join(), sci_text_width(), editor_strip_line_trailing_spaces(). git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@4025 ea778897-0a13-0410-b9d1-a72fbfd435f5 --- ChangeLog | 7 +++ THANKS | 2 +- doc/geany.html | 11 +++- doc/geany.txt | 3 + src/editor.c | 3 +- src/editor.h | 4 +- src/keybindings.c | 144 ++++++++++++++++++++++++++++++++++++++++++++++ src/keybindings.h | 1 + src/sciwrappers.c | 22 ++++++- src/sciwrappers.h | 6 +- 10 files changed, 193 insertions(+), 10 deletions(-) diff --git a/ChangeLog b/ChangeLog index ff57c39d..0d3e3357 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,13 @@ Use full styleset_foo[_init] function name as argument to init_styleset_case() and styleset_case() macros so it's easier to understand the code. + * src/keybindings.c, src/keybindings.h, src/sciwrappers.c, + src/sciwrappers.h, src/editor.c, src/editor.h, THANKS, + doc/geany.txt, doc/geany.html: + Add 'Reflow lines/paragraph' keybinding, defaults to Ctrl-J. + Heavily based on a patch by Eugene Arshinov (thanks). + Add sci_lines_split(), sci_lines_join(), sci_text_width(), + editor_strip_line_trailing_spaces(). 2009-07-24 Enrico Tröger diff --git a/THANKS b/THANKS index a86571c4..5c71a103 100644 --- a/THANKS +++ b/THANKS @@ -65,7 +65,7 @@ Chris Macksey - ActionScript filetyp Simon Treny - Documents sidebar stock icons patch Elias Pschernig - Recent Projects menu patch Jesse Mayes - Tango'ish Save All icon -Eugene Arshinov - Reload color schemes via menu patch +Eugene Arshinov - Reload color schemes, split lines KB patches Translators: ------------ diff --git a/doc/geany.html b/doc/geany.html index 062d08a4..bf2dd0a4 100644 --- a/doc/geany.html +++ b/doc/geany.html @@ -6,7 +6,7 @@ Geany - +