lists.geany.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
March
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
List overview
Commits
February 2025
----- 2025 -----
March 2025
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
commits@lists.geany.org
1 participants
48 discussions
Start a n
N
ew thread
[geany/geany] 6ac79a: Merge pull request #4204 from techee/win_scintilla_cursor
by Jiří Techet
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Jiří Techet <techet(a)gmail.com> Committer: GitHub <noreply(a)github.com> Date: Wed, 05 Feb 2025 22:51:42 UTC Commit: 6ac79a310c99d10c05967e57cd995e40f138f546
https://github.com/geany/geany/commit/6ac79a310c99d10c05967e57cd995e40f138f…
Log Message: ----------- Merge pull request #4204 from techee/win_scintilla_cursor Workaround incorrect scaling of "reverse arrow" cursor under Windows and HiDPI screens Modified Paths: -------------- scintilla/gtk/PlatGTK.cxx Modified: scintilla/gtk/PlatGTK.cxx 6 lines changed, 6 insertions(+), 0 deletions(-) =================================================================== @@ -1346,7 +1346,13 @@ void Window::SetCursor(Cursor curs) { gdkCurs = gdk_cursor_new_for_display(pdisplay, GDK_HAND2); break; case Cursor::reverseArrow: +#ifdef G_OS_WIN32 + // GDK_RIGHT_PTR is scaled incorrectly under Windows with HiDPI screens (GTK 3.24); + // GDK_HAND2 is mapped to a native Windows cursor by GTK + gdkCurs = gdk_cursor_new_for_display(pdisplay, GDK_HAND2); +#else gdkCurs = gdk_cursor_new_for_display(pdisplay, GDK_RIGHT_PTR); +#endif break; default: gdkCurs = gdk_cursor_new_for_display(pdisplay, GDK_LEFT_PTR); -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
[geany/geany] 018b83: Use themed title bar on Windows
by Jiří Techet
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Jiří Techet <techet(a)gmail.com> Committer: Jiří Techet <techet(a)gmail.com> Date: Wed, 05 Feb 2025 22:48:36 UTC Commit: 018b83e4fd4e286d873984a976acb587c5ef4aea
https://github.com/geany/geany/commit/018b83e4fd4e286d873984a976acb587c5ef4…
Log Message: ----------- Use themed title bar on Windows Based on a patch from @GabrielFrigo4. Thanks! Modified to connect to the realized signal using a patch from Colomban Wendling. Thanks! Modified Paths: -------------- src/search.c src/ui_utils.c src/win32.c src/win32.h Modified: src/search.c 13 lines changed, 13 insertions(+), 0 deletions(-) =================================================================== @@ -44,6 +44,7 @@ #include "toolbar.h" #include "ui_utils.h" #include "utils.h" +#include "win32.h" #include <unistd.h> #include <string.h> @@ -547,6 +548,10 @@ static void create_find_dialog(void) GTK_BUTTON_BOX(bbox)); gtk_container_add(GTK_CONTAINER(exp), bbox); gtk_container_add(GTK_CONTAINER(vbox), exp); + +#ifdef G_OS_WIN32 + win32_update_titlebar_theme(find_dlg.dialog); +#endif } @@ -731,6 +736,10 @@ static void create_replace_dialog(void) GTK_BUTTON_BOX(bbox)); gtk_container_add(GTK_CONTAINER(exp), bbox); gtk_container_add(GTK_CONTAINER(vbox), exp); + +#ifdef G_OS_WIN32 + win32_update_titlebar_theme(replace_dlg.dialog); +#endif } @@ -1029,6 +1038,10 @@ static void create_fif_dialog(void) G_CALLBACK(on_find_in_files_dialog_response), NULL); g_signal_connect(fif_dlg.dialog, "delete-event", G_CALLBACK(gtk_widget_hide_on_delete), NULL); + +#ifdef G_OS_WIN32 + win32_update_titlebar_theme(fif_dlg.dialog); +#endif } Modified: src/ui_utils.c 5 lines changed, 5 insertions(+), 0 deletions(-) =================================================================== @@ -2521,6 +2521,11 @@ void ui_init_builder(void) widget = GTK_WIDGET(iter->data); +#ifdef G_OS_WIN32 + if (GTK_IS_WINDOW(widget)) + win32_update_titlebar_theme(widget); +#endif + name = ui_guess_object_name(G_OBJECT(widget)); if (! name) { Modified: src/win32.c 38 lines changed, 38 insertions(+), 0 deletions(-) =================================================================== @@ -53,12 +53,17 @@ #include <windows.h> #include <commdlg.h> +#include <dwmapi.h> #include <shellapi.h> #include <shlobj.h> #include <glib/gstdio.h> #include <gdk/gdkwin32.h> +#ifndef DWMWA_USE_IMMERSIVE_DARK_MODE +#define DWMWA_USE_IMMERSIVE_DARK_MODE 20 +#endif + /* Little wrapper for _waccess(), returns errno or 0 if there was no error */ gint win32_check_write_permission(const gchar *dir) @@ -327,4 +332,37 @@ gchar *win32_get_user_config_dir(void) return g_build_filename(g_get_user_config_dir(), "geany", NULL); } + +static void on_update_titlebar_theme_realized(GtkWidget *widget, gpointer data) +{ + GdkWindow *gdk_window = gtk_widget_get_window(widget); + + g_return_if_fail(gdk_window != NULL); + + HWND hwnd = (HWND)gdk_win32_window_get_handle(gdk_window); + if (hwnd) + { + BOOL use_dark_mode = TRUE; + DwmSetWindowAttribute(hwnd, DWMWA_USE_IMMERSIVE_DARK_MODE, &use_dark_mode, sizeof(use_dark_mode)); + } +} + +/* Makes titlebar dark when using dark theme; call this before + * gtk_widget_show(window) to avoid titlebar color change */ +void win32_update_titlebar_theme(GtkWidget *window) +{ + const gchar *reg_path = "Software\\Microsoft\\Windows\\CurrentVersion\\Themes\\Personalize"; + gboolean is_light_theme = TRUE; + DWORD val; + DWORD data_size = sizeof(val); + + g_return_if_fail(GTK_IS_WINDOW(window)); + + if (RegGetValueA(HKEY_CURRENT_USER, reg_path, "AppsUseLightTheme", RRF_RT_DWORD, NULL, &val, &data_size) == ERROR_SUCCESS) + is_light_theme = val; + + if (!is_light_theme) + g_signal_connect(window, "realize", G_CALLBACK(on_update_titlebar_theme_realized), NULL); +} + #endif Modified: src/win32.h 2 lines changed, 2 insertions(+), 0 deletions(-) =================================================================== @@ -47,6 +47,8 @@ gchar *win32_expand_environment_variables(const gchar *str); gchar *win32_get_user_config_dir(void); +void win32_update_titlebar_theme(GtkWidget *window); + G_END_DECLS #endif /* G_OS_WIN32 */ -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
[geany/geany] aeb2c5: Allow shrinking the preferences dialog again
by Colomban Wendling
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Colomban Wendling <ban(a)herbesfolles.org> Committer: Colomban Wendling <ban(a)herbesfolles.org> Date: Sat, 01 Feb 2025 22:44:30 UTC Commit: aeb2c5ed7406db3616a820655837bb225c115f05
https://github.com/geany/geany/commit/aeb2c5ed7406db3616a820655837bb225c115…
Log Message: ----------- Allow shrinking the preferences dialog again Use a more flexible way of setting the default preference window size to allow shrinking the window if desired. Related to #4195. Modified Paths: -------------- data/geany.glade src/prefs.c Modified: data/geany.glade 1 lines changed, 1 insertions(+), 0 deletions(-) =================================================================== @@ -761,6 +761,7 @@ <property name="can-focus">False</property> <property name="title" translatable="yes">Preferences</property> <property name="modal">True</property> + <property name="default-width">600</property> <property name="icon-name">geany</property> <property name="type-hint">dialog</property> <property name="skip-pager-hint">True</property> Modified: src/prefs.c 1 lines changed, 0 insertions(+), 1 deletions(-) =================================================================== @@ -1751,7 +1751,6 @@ void prefs_show_dialog(void) ui_widgets.prefs_dialog = create_prefs_dialog(); gtk_widget_set_name(ui_widgets.prefs_dialog, "GeanyPrefsDialog"); gtk_window_set_transient_for(GTK_WINDOW(ui_widgets.prefs_dialog), GTK_WINDOW(main_widgets.window)); - gtk_widget_set_size_request(ui_widgets.prefs_dialog, 600, -1); /* init the file encoding combo boxes */ { -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
[geany/geany] bebd35: Merge pull request #4224 from b4n/pref_size
by Jiří Techet
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Jiří Techet <techet(a)gmail.com> Committer: GitHub <noreply(a)github.com> Date: Wed, 05 Feb 2025 21:52:47 UTC Commit: bebd354001729f05c0b7012d6350640f3acfa7d5
https://github.com/geany/geany/commit/bebd354001729f05c0b7012d6350640f3acfa…
Log Message: ----------- Merge pull request #4224 from b4n/pref_size Allow shrinking the preferences dialog again Modified Paths: -------------- data/geany.glade src/prefs.c Modified: data/geany.glade 1 lines changed, 1 insertions(+), 0 deletions(-) =================================================================== @@ -761,6 +761,7 @@ <property name="can-focus">False</property> <property name="title" translatable="yes">Preferences</property> <property name="modal">True</property> + <property name="default-width">600</property> <property name="icon-name">geany</property> <property name="type-hint">dialog</property> <property name="skip-pager-hint">True</property> Modified: src/prefs.c 1 lines changed, 0 insertions(+), 1 deletions(-) =================================================================== @@ -1751,7 +1751,6 @@ void prefs_show_dialog(void) ui_widgets.prefs_dialog = create_prefs_dialog(); gtk_widget_set_name(ui_widgets.prefs_dialog, "GeanyPrefsDialog"); gtk_window_set_transient_for(GTK_WINDOW(ui_widgets.prefs_dialog), GTK_WINDOW(main_widgets.window)); - gtk_widget_set_size_request(ui_widgets.prefs_dialog, 600, -1); /* init the file encoding combo boxes */ { -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
[geany/geany] a25355: Avoid clang string-plus-int warning
by Colomban Wendling
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Colomban Wendling <ban(a)herbesfolles.org> Committer: Colomban Wendling <ban(a)herbesfolles.org> Date: Wed, 05 Feb 2025 21:51:43 UTC Commit: a253555f4b89e459b2e9780d1b479d9657675006
https://github.com/geany/geany/commit/a253555f4b89e459b2e9780d1b479d9657675…
Log Message: ----------- Avoid clang string-plus-int warning Some versions of CLang warn when performing pointer arithmetic on strings, trying to avoid people thinking `+` is a string concatenation operator in C. It's kind of silly, but given we only seem to have one of those instances, just "fix" it using array syntax instead. Fixes #4229. Modified Paths: -------------- tests/test_encodings.c Modified: tests/test_encodings.c 2 lines changed, 1 insertions(+), 1 deletions(-) =================================================================== @@ -137,7 +137,7 @@ static void test_encodings_convert_utf8_to_utf8_auto(void) G_STMT_START { \ gboolean has_bom = strncmp(str, UTF8_BOM, 3) == 0; \ g_assert(success == assert_convert_to_utf8_auto(str, G_N_ELEMENTS(str) - 1, G_N_ELEMENTS(str) - 1, \ - forced_enc, str + (has_bom ? 3 : 0), G_N_ELEMENTS(str) - 1 - (has_bom ? 3 : 0), \ + forced_enc, &str[has_bom ? 3 : 0], G_N_ELEMENTS(str) - 1 - (has_bom ? 3 : 0), \ forced_enc, has_bom, strlen(str) != G_N_ELEMENTS(str) - 1)); \ } G_STMT_END -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
[geany/geany] bcba63: regex: Eliminate K&R function parameter syntax to avoid warnings
by Jiří Techet
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Jiří Techet <techet(a)gmail.com> Committer: Jiří Techet <techet(a)gmail.com> Date: Wed, 05 Feb 2025 18:44:07 UTC Commit: bcba6305d39e2db9ece500ceeb0a4a9860b677ff
https://github.com/geany/geany/commit/bcba6305d39e2db9ece500ceeb0a4a9860b67…
Log Message: ----------- regex: Eliminate K&R function parameter syntax to avoid warnings Modified Paths: -------------- ctags/gnu_regex/regcomp.c ctags/gnu_regex/regexec.c Modified: ctags/gnu_regex/regcomp.c 19 lines changed, 5 insertions(+), 14 deletions(-) =================================================================== @@ -212,10 +212,7 @@ const size_t __re_error_msgid_idx[] attribute_hidden = are set in BUFP on entry. */ const char * -re_compile_pattern (pattern, length, bufp) - const char *pattern; - size_t length; - struct re_pattern_buffer *bufp; +re_compile_pattern (const char *pattern, size_t length, struct re_pattern_buffer *bufp) { reg_errcode_t ret; @@ -253,8 +250,7 @@ reg_syntax_t re_syntax_options; defined in regex.h. We return the old syntax. */ reg_syntax_t -re_set_syntax (syntax) - reg_syntax_t syntax; +re_set_syntax (reg_syntax_t syntax) { reg_syntax_t ret = re_syntax_options; @@ -266,8 +262,7 @@ weak_alias (__re_set_syntax, re_set_syntax) #endif int -re_compile_fastmap (bufp) - struct re_pattern_buffer *bufp; +re_compile_fastmap (struct re_pattern_buffer *bufp) { re_dfa_t *dfa = (re_dfa_t *) bufp->buffer; char *fastmap = bufp->fastmap; @@ -465,10 +460,7 @@ re_compile_fastmap_iter (regex_t *bufp, const re_dfastate_t *init_state, the return codes and their meanings.) */ int -regcomp (preg, pattern, cflags) - regex_t *__restrict preg; - const char *__restrict pattern; - int cflags; +regcomp (regex_t *__restrict preg, const char *__restrict pattern, int cflags) { reg_errcode_t ret; reg_syntax_t syntax = ((cflags & REG_EXTENDED) ? RE_SYNTAX_POSIX_EXTENDED @@ -635,8 +627,7 @@ free_dfa_content (re_dfa_t *dfa) /* Free dynamically allocated space used by PREG. */ void -regfree (preg) - regex_t *preg; +regfree (regex_t *preg) { re_dfa_t *dfa = (re_dfa_t *) preg->buffer; if (BE (dfa != NULL, 1)) Modified: ctags/gnu_regex/regexec.c 80 lines changed, 25 insertions(+), 55 deletions(-) =================================================================== @@ -218,12 +218,8 @@ static reg_errcode_t extend_buffers (re_match_context_t *mctx) We return 0 if we find a match and REG_NOMATCH if not. */ int -regexec (preg, string, nmatch, pmatch, eflags) - const regex_t *__restrict preg; - const char *__restrict string; - size_t nmatch; - regmatch_t pmatch[]; - int eflags; +regexec (const regex_t *__restrict preg, const char *__restrict string, + size_t nmatch, regmatch_t pmatch[], int eflags) { reg_errcode_t err; int start, length; @@ -306,11 +302,8 @@ compat_symbol (libc, __compat_regexec, regexec, GLIBC_2_0); match was found and -2 indicates an internal error. */ int -re_match (bufp, string, length, start, regs) - struct re_pattern_buffer *bufp; - const char *string; - int length, start; - struct re_registers *regs; +re_match (struct re_pattern_buffer *bufp, const char *string, int length, + int start, struct re_registers *regs) { return re_search_stub (bufp, string, length, start, 0, length, regs, 1); } @@ -319,11 +312,7 @@ weak_alias (__re_match, re_match) #endif int -re_search (bufp, string, length, start, range, regs) - struct re_pattern_buffer *bufp; - const char *string; - int length, start, range; - struct re_registers *regs; +re_search (struct re_pattern_buffer *bufp, const char *string, int length, int start, int range, struct re_registers *regs) { return re_search_stub (bufp, string, length, start, range, length, regs, 0); } @@ -332,11 +321,9 @@ weak_alias (__re_search, re_search) #endif int -re_match_2 (bufp, string1, length1, string2, length2, start, regs, stop) - struct re_pattern_buffer *bufp; - const char *string1, *string2; - int length1, length2, start, stop; - struct re_registers *regs; +re_match_2 (struct re_pattern_buffer *bufp, const char *string1, + int length1, const char *string2, int length2, int start, + struct re_registers *regs, int stop) { return re_search_2_stub (bufp, string1, length1, string2, length2, start, 0, regs, stop, 1); @@ -346,11 +333,9 @@ weak_alias (__re_match_2, re_match_2) #endif int -re_search_2 (bufp, string1, length1, string2, length2, start, range, regs, stop) - struct re_pattern_buffer *bufp; - const char *string1, *string2; - int length1, length2, start, range, stop; - struct re_registers *regs; +re_search_2 (struct re_pattern_buffer *bufp, const char *string1, + int length1, const char *string2, int length2, int start, int range, + struct re_registers *regs, int stop) { return re_search_2_stub (bufp, string1, length1, string2, length2, start, range, regs, stop, 0); @@ -360,12 +345,10 @@ weak_alias (__re_search_2, re_search_2) #endif static int -re_search_2_stub (bufp, string1, length1, string2, length2, start, range, regs, - stop, ret_len) - struct re_pattern_buffer *bufp; - const char *string1, *string2; - int length1, length2, start, range, stop, ret_len; - struct re_registers *regs; +re_search_2_stub (struct re_pattern_buffer *bufp, const char *string1, + int length1, const char *string2, int length2, + int start, int range, struct re_registers *regs, + int stop, int ret_len) { const char *str; int rval; @@ -410,11 +393,9 @@ re_search_2_stub (bufp, string1, length1, string2, length2, start, range, regs, otherwise the position of the match is returned. */ static int -re_search_stub (bufp, string, length, start, range, stop, regs, ret_len) - struct re_pattern_buffer *bufp; - const char *string; - int length, start, range, stop, ret_len; - struct re_registers *regs; +re_search_stub (struct re_pattern_buffer *bufp, const char *string, + int length, int start, int range, int stop, struct re_registers *regs, + int ret_len) { reg_errcode_t result; regmatch_t *pmatch; @@ -501,10 +482,7 @@ re_search_stub (bufp, string, length, start, range, stop, regs, ret_len) } static unsigned -re_copy_regs (regs, pmatch, nregs, regs_allocated) - struct re_registers *regs; - regmatch_t *pmatch; - int nregs, regs_allocated; +re_copy_regs (struct re_registers *regs, regmatch_t *pmatch, int nregs, int regs_allocated) { int rval = REGS_REALLOCATE; int i; @@ -570,11 +548,8 @@ re_copy_regs (regs, pmatch, nregs, regs_allocated) freeing the old data. */ void -re_set_registers (bufp, regs, num_regs, starts, ends) - struct re_pattern_buffer *bufp; - struct re_registers *regs; - unsigned num_regs; - regoff_t *starts, *ends; +re_set_registers (struct re_pattern_buffer *bufp, struct re_registers *regs, + unsigned num_regs, regoff_t *starts, regoff_t *ends) { if (num_regs) { @@ -621,13 +596,9 @@ re_exec (s) (START + RANGE >= 0 && START + RANGE <= LENGTH) */ static reg_errcode_t -re_search_internal (preg, string, length, start, range, stop, nmatch, pmatch, - eflags) - const regex_t *preg; - const char *string; - int length, start, range, stop, eflags; - size_t nmatch; - regmatch_t pmatch[]; +re_search_internal (const regex_t *preg, const char *string, int length, + int start, int range, int stop, size_t nmatch, + regmatch_t pmatch[], int eflags) { reg_errcode_t err; const re_dfa_t *dfa = (const re_dfa_t *) preg->buffer; @@ -940,8 +911,7 @@ re_search_internal (preg, string, length, start, range, stop, nmatch, pmatch, } static reg_errcode_t -prune_impossible_nodes (mctx) - re_match_context_t *mctx; +prune_impossible_nodes (re_match_context_t *mctx) { const re_dfa_t *const dfa = mctx->dfa; int halt_node, match_last; -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
[geany/geany] be946d: Merge pull request #4181 from techee/macos_regex
by Jiří Techet
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Jiří Techet <techet(a)gmail.com> Committer: GitHub <noreply(a)github.com> Date: Wed, 05 Feb 2025 17:35:52 UTC Commit: be946d5d07b5c4582068580d06a3b940c4d378f0
https://github.com/geany/geany/commit/be946d5d07b5c4582068580d06a3b940c4d37…
Log Message: ----------- Merge pull request #4181 from techee/macos_regex Use builtin regex on macOS for performance reasons Modified Paths: -------------- configure.ac meson.build Modified: configure.ac 18 lines changed, 11 insertions(+), 7 deletions(-) =================================================================== @@ -50,13 +50,17 @@ AC_CHECK_HEADERS([fcntl.h stdlib.h sys/time.h errno.h limits.h]) # Checks for dependencies needed by ctags AC_CHECK_HEADERS([dirent.h fnmatch.h direct.h io.h sys/dir.h]) AC_DEFINE([HAVE_STDBOOL_H], [1], [whether or not to use <stdbool.h>.]) -AC_CHECK_FUNC([regcomp], - [have_regcomp=yes], - [have_regcomp=no - dnl various stuff for ctags/gnu_regex/ - AC_CHECK_HEADERS([langinfo.h locale.h libintl.h wctype.h wchar.h]) - AC_CHECK_FUNCS([memcpy isblank wcrtomb mbrtowc wcscoll]) - AC_FUNC_ALLOCA]) +AC_CANONICAL_HOST +AS_CASE([${host_os}], + [darwin*], [dnl Using builtin regex on macOS for performance reasons + have_regcomp=no], + [AC_CHECK_FUNC([regcomp], + [have_regcomp=yes], + [have_regcomp=no + dnl various stuff for ctags/gnu_regex/ + AC_CHECK_HEADERS([langinfo.h locale.h libintl.h wctype.h wchar.h]) + AC_CHECK_FUNCS([memcpy isblank wcrtomb mbrtowc wcscoll]) + AC_FUNC_ALLOCA])]) AM_CONDITIONAL([USE_BUNDLED_REGEX], [test "xno" = "x$have_regcomp"]) AC_CHECK_FUNC([fnmatch], [have_fnmatch=yes], [have_fnmatch=no]) AM_CONDITIONAL([USE_BUNDLED_FNMATCH], [test "xno" = "x$have_fnmatch"]) Modified: meson.build 6 lines changed, 5 insertions(+), 1 deletions(-) =================================================================== @@ -71,7 +71,6 @@ check_functions = [ ['memcpy', '#include <string.h>'], ['mkstemp', '#include <stdlib.h>'], ['realpath', '#include <limits.h>\n#include <stdlib.h>'], - ['regcomp', '#include <regex.h>'], ['socket', '#include <sys/socket.h>'], # man page says strings.h but we include only string.h and it works ['strcasecmp', '#include <string.h>'], @@ -87,6 +86,11 @@ check_functions = [ ['g_strv_equal', '#include <glib.h>'] ] +# Using builtin regex on macOS for performance reasons +if (host_machine.system() != 'darwin') + check_functions += [['regcomp', '#include <regex.h>']] +endif + foreach h : check_headers define = 'HAVE_' + h.underscorify().to_upper() if cc.has_header(h) -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
[geany/geany] c5e9d9: Use builtin regex on macOS for performance reasons
by Jiří Techet
05 Feb '25
05 Feb '25
Branch: refs/heads/master Author: Jiří Techet <techet(a)gmail.com> Committer: Jiří Techet <techet(a)gmail.com> Date: Wed, 05 Feb 2025 16:35:09 UTC Commit: c5e9d98a269475dc7b41222b744f14ca657630f2
https://github.com/geany/geany/commit/c5e9d98a269475dc7b41222b744f14ca65763…
Log Message: ----------- Use builtin regex on macOS for performance reasons Modified Paths: -------------- configure.ac meson.build Modified: configure.ac 18 lines changed, 11 insertions(+), 7 deletions(-) =================================================================== @@ -50,13 +50,17 @@ AC_CHECK_HEADERS([fcntl.h stdlib.h sys/time.h errno.h limits.h]) # Checks for dependencies needed by ctags AC_CHECK_HEADERS([dirent.h fnmatch.h direct.h io.h sys/dir.h]) AC_DEFINE([HAVE_STDBOOL_H], [1], [whether or not to use <stdbool.h>.]) -AC_CHECK_FUNC([regcomp], - [have_regcomp=yes], - [have_regcomp=no - dnl various stuff for ctags/gnu_regex/ - AC_CHECK_HEADERS([langinfo.h locale.h libintl.h wctype.h wchar.h]) - AC_CHECK_FUNCS([memcpy isblank wcrtomb mbrtowc wcscoll]) - AC_FUNC_ALLOCA]) +AC_CANONICAL_HOST +AS_CASE([${host_os}], + [darwin*], [dnl Using builtin regex on macOS for performance reasons + have_regcomp=no], + [AC_CHECK_FUNC([regcomp], + [have_regcomp=yes], + [have_regcomp=no + dnl various stuff for ctags/gnu_regex/ + AC_CHECK_HEADERS([langinfo.h locale.h libintl.h wctype.h wchar.h]) + AC_CHECK_FUNCS([memcpy isblank wcrtomb mbrtowc wcscoll]) + AC_FUNC_ALLOCA])]) AM_CONDITIONAL([USE_BUNDLED_REGEX], [test "xno" = "x$have_regcomp"]) AC_CHECK_FUNC([fnmatch], [have_fnmatch=yes], [have_fnmatch=no]) AM_CONDITIONAL([USE_BUNDLED_FNMATCH], [test "xno" = "x$have_fnmatch"]) Modified: meson.build 6 lines changed, 5 insertions(+), 1 deletions(-) =================================================================== @@ -71,7 +71,6 @@ check_functions = [ ['memcpy', '#include <string.h>'], ['mkstemp', '#include <stdlib.h>'], ['realpath', '#include <limits.h>\n#include <stdlib.h>'], - ['regcomp', '#include <regex.h>'], ['socket', '#include <sys/socket.h>'], # man page says strings.h but we include only string.h and it works ['strcasecmp', '#include <string.h>'], @@ -87,6 +86,11 @@ check_functions = [ ['g_strv_equal', '#include <glib.h>'] ] +# Using builtin regex on macOS for performance reasons +if (host_machine.system() != 'darwin') + check_functions += [['regcomp', '#include <regex.h>']] +endif + foreach h : check_headers define = 'HAVE_' + h.underscorify().to_upper() if cc.has_header(h) -------------- This E-Mail was brought to you by github_commit_mail.py (Source:
https://github.com/geany/infrastructure
).
1
0
0
0
← Newer
1
2
3
4
5
Older →
Jump to page:
1
2
3
4
5
Results per page:
10
25
50
100
200