diff --git a/ChangeLog b/ChangeLog index 0cf12f15..687e6188 100644 --- a/ChangeLog +++ b/ChangeLog @@ -9,6 +9,9 @@ Remove unnecessary enums. * scintilla/*, scintilla/include/*, src/plugindata.h: Update Scintilla to version 1.79. + * src/document.c, src/editor.c, src/sciwrappers.c, src/sciwrappers.h, + src/search.c: + Use the new Scintilla struct names prefixed with 'Sci_'. 2009-06-30 Enrico Tröger diff --git a/src/document.c b/src/document.c index 4b9b3a7e..408ca536 100644 --- a/src/document.c +++ b/src/document.c @@ -1076,7 +1076,7 @@ static gboolean detect_tabs_and_spaces(GeanyEditor *editor) const GeanyIndentPrefs *iprefs = editor_get_indent_prefs(editor); ScintillaObject *sci = editor->sci; gsize count = 0; - struct TextToFind ttf; + struct Sci_TextToFind ttf; gchar *soft_tab = g_strnfill(iprefs->width, ' '); gchar *regex = g_strconcat("^\t+", soft_tab, "[^ ]", NULL); @@ -1511,7 +1511,7 @@ static void replace_header_filename(GeanyDocument *doc) { gchar *filebase; gchar *filename; - struct TextToFind ttf; + struct Sci_TextToFind ttf; g_return_if_fail(doc != NULL); g_return_if_fail(doc->file_type != NULL); @@ -1867,7 +1867,7 @@ gboolean document_save_file(GeanyDocument *doc, gboolean force) gboolean document_search_bar_find(GeanyDocument *doc, const gchar *text, gint flags, gboolean inc) { gint start_pos, search_pos; - struct TextToFind ttf; + struct Sci_TextToFind ttf; g_return_val_if_fail(text != NULL, FALSE); g_return_val_if_fail(doc != NULL, FALSE); @@ -2096,7 +2096,7 @@ document_replace_range(GeanyDocument *doc, const gchar *find_text, const gchar * gint flags, gint start, gint end, gboolean scroll_to_match, gint *new_range_end) { gint count = 0; - struct TextToFind ttf; + struct Sci_TextToFind ttf; ScintillaObject *sci; if (new_range_end != NULL) diff --git a/src/editor.c b/src/editor.c index 589e73f7..07ba7461 100644 --- a/src/editor.c +++ b/src/editor.c @@ -1727,7 +1727,7 @@ static gboolean complete_doc_word(GeanyEditor *editor, gchar *root, gsize rootle gsize nmatches = 0; gboolean ret = FALSE; GString *words; - struct TextToFind ttf; + struct Sci_TextToFind ttf; len = sci_get_length(sci); current = sci_get_current_position(sci) - rootlen; @@ -4132,7 +4132,7 @@ void editor_replace_tabs(GeanyEditor *editor) gint search_pos, pos_in_line, current_tab_true_length; gint tab_len; gchar *tab_str; - struct TextToFind ttf; + struct Sci_TextToFind ttf; g_return_if_fail(editor != NULL); @@ -4170,7 +4170,7 @@ void editor_replace_spaces(GeanyEditor *editor) gint search_pos; static gdouble tab_len_f = -1.0; /* keep the last used value */ gint tab_len; - struct TextToFind ttf; + struct Sci_TextToFind ttf; g_return_if_fail(editor != NULL); diff --git a/src/sciwrappers.c b/src/sciwrappers.c index 8e731cd6..6f916bf6 100644 --- a/src/sciwrappers.c +++ b/src/sciwrappers.c @@ -747,7 +747,7 @@ gint sci_search_prev(ScintillaObject *sci, gint flags, const gchar *text) } -gint sci_find_text(ScintillaObject *sci, gint flags, struct TextToFind *ttf) +gint sci_find_text(ScintillaObject *sci, gint flags, struct Sci_TextToFind *ttf) { return SSM(sci, SCI_FINDTEXT, flags, (long) ttf ); } @@ -811,7 +811,7 @@ void sci_clear_cmdkey(ScintillaObject *sci, gint key) * @param text Text will be zero terminated and must be allocated (end - start + 1) bytes. */ void sci_get_text_range(ScintillaObject *sci, gint start, gint end, gchar *text) { - struct TextRange tr; + struct Sci_TextRange tr; tr.chrg.cpMin = start; tr.chrg.cpMax = end; tr.lpstrText = text; diff --git a/src/sciwrappers.h b/src/sciwrappers.h index 02c35c75..624c77d3 100644 --- a/src/sciwrappers.h +++ b/src/sciwrappers.h @@ -121,7 +121,7 @@ void sci_scroll_lines (ScintillaObject * sci, gint lines); void sci_scroll_columns (ScintillaObject *sci, gint columns); gint sci_search_next (ScintillaObject * sci, gint flags, const gchar *text); gint sci_search_prev (ScintillaObject * sci, gint flags, const gchar *text); -gint sci_find_text (ScintillaObject * sci, gint flags, struct TextToFind *ttf); +gint sci_find_text (ScintillaObject * sci, gint flags, struct Sci_TextToFind *ttf); void sci_set_font (ScintillaObject * sci, gint style, const gchar* font, gint size); void sci_goto_line (ScintillaObject * sci, gint line, gboolean unfold); void sci_marker_delete_all (ScintillaObject * sci, gint marker); diff --git a/src/search.c b/src/search.c index 8df04af2..a3247488 100644 --- a/src/search.c +++ b/src/search.c @@ -963,7 +963,7 @@ static gint search_mark(GeanyDocument *doc, const gchar *search_text, gint flags { gint pos, count = 0; gsize len; - struct TextToFind ttf; + struct Sci_TextToFind ttf; g_return_val_if_fail(doc != NULL, 0); @@ -1605,7 +1605,7 @@ static void search_close_pid(GPid child_pid, gint status, gpointer user_data) static gint find_document_usage(GeanyDocument *doc, const gchar *search_text, gint flags) { gchar *buffer, *short_file_name; - struct TextToFind ttf; + struct Sci_TextToFind ttf; gint count = 0; gint prev_line = -1;