The slow loading of projects in geany 1.37.1 and the missing plugins installer for 1.37.1 has prevented me from upgrading, and a bug that may be related to file dialogs, has prompted me to try building geany from source.
I have been following the instructions on the wiki page "Build Geany on Windows (using MSYS2)" at https://wiki.geany.org/howtos/win32/msys2 to set up and build on a Windows 10 Pro laptop with Msys2 and Mingw64 installed. I have used msys2/mingw64 for several years and cygwin for many years, as well as several *nix systems in the past.
In the "GTK+3 compilation" section, it appears that the required msys2 package list has evolved since the wiki page was last updated about 6 years ago. When I try to run "autoconfig.sh" to build ./configure, the following lines in "configure.ac":
# GTK/GLib/GIO checks gtk_modules="gtk+-3.0 >= 3.0 glib-2.0 >= 2.32" gtk_modules_private="gio-2.0 >= 2.32 gmodule-no-export-2.0" PKG_CHECK_MODULES([GTK], [$gtk_modules $gtk_modules_private])
appear to cause a failure about missing packages. I could not find a "gmodule-no-export" package.
Can someone suggest how to correct this snippet of code in the wiki page to work now, or how to make a modified version of "cross-build-mingw.sh" which will work for buildinig on mingw on a Windows machine.
Thanks, Doug
Not sure who posted the wiki or how relevant it is (its a wiki after all :), for example Geany now only supports GTK3, not GTK2.
The official Windows build processes are currently under upgrade as a result, see https://github.com/geany/geany/pull/2590 and https://github.com/geany/geany-plugins/pull/1107. Not sure the status and if they are usable yet, but you might find the updated packages used there.
IIUC after this is complete it might be possible to make a docker container available to build Geany for windows with all the necessary dependencies, no guarantees though.
Cheers Lex
On Thu, 9 Sept 2021 at 14:05, Doug Henderson djndnbvg@gmail.com wrote:
The slow loading of projects in geany 1.37.1 and the missing plugins installer for 1.37.1 has prevented me from upgrading, and a bug that may be related to file dialogs, has prompted me to try building geany from source.
I have been following the instructions on the wiki page "Build Geany on Windows (using MSYS2)" at https://wiki.geany.org/howtos/win32/msys2 to set up and build on a Windows 10 Pro laptop with Msys2 and Mingw64 installed. I have used msys2/mingw64 for several years and cygwin for many years, as well as several *nix systems in the past.
In the "GTK+3 compilation" section, it appears that the required msys2 package list has evolved since the wiki page was last updated about 6 years ago. When I try to run "autoconfig.sh" to build ./configure, the following lines in "configure.ac":
# GTK/GLib/GIO checks gtk_modules="gtk+-3.0 >= 3.0 glib-2.0 >= 2.32" gtk_modules_private="gio-2.0 >= 2.32 gmodule-no-export-2.0" PKG_CHECK_MODULES([GTK], [$gtk_modules $gtk_modules_private])
appear to cause a failure about missing packages. I could not find a "gmodule-no-export" package.
Can someone suggest how to correct this snippet of code in the wiki page to work now, or how to make a modified version of "cross-build-mingw.sh" which will work for buildinig on mingw on a Windows machine.
Thanks, Doug
-- Doug Henderson, Calgary, Alberta, Canada - from gmail.com _______________________________________________ Devel mailing list Devel@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/devel
Hi,
On Thu, 9 Sept 2021 at 14:05, Doug Henderson djndnbvg@gmail.com wrote:
Can someone suggest how to correct this snippet of code in the wiki page to work now, or how to make a modified version of "cross-build-mingw.sh" which will work for buildinig on mingw on a Windows machine.
On 09.09.21 06:31, Lex Trotman wrote:
Not sure who posted the wiki or how relevant it is (its a wiki after all :), for example Geany now only supports GTK3, not GTK2.
I think Thomas wrote the page initially and I edited it later on. So now you know who to blame :).
The official Windows build processes are currently under upgrade as a result, see https://github.com/geany/geany/pull/2590 and https://github.com/geany/geany-plugins/pull/1107. Not sure the status and if they are usable yet, but you might find the updated packages used there.
They are usable and just need review. With both PRs I built full Geany and Geany-Plugins on native Windows as well as a cross built using Docker images.
IIUC after this is complete it might be possible to make a docker container available to build Geany for windows with all the necessary dependencies, no guarantees though.
That's the plan and it already works quite well. Still need to be polished and published and integrated in CI.
Anyway, to get back to Doug's question: I'm going to prepare Windows installers for the current master on the weekend and so have some 1.38 beta or preview.
I'll also try to update the wiki page to reflect the current state, much has changed due to the switch to GTK3 and x86_64. But it might take a little more time to finish.
Regards, Enrico
Hi,
I do not know the Windows compiler environment, but on Linux I switched back the Gtk3 to Gtk2 successfully. Just change the 'configure.ac' at line 79 to `[enable_gtk2=yes])`. And of course install the Gtk2-dev packages.
You can see it (and my CI solution) here: https://gitlab.com/attila_v/geany
regards, Attila
PGP-PK: https://avesoft.hu/veghelyiattila.pk.gpg-key
---------------------------------------------------------------
<Hi, < <On Thu, 9 Sept 2021 at 14:05, Doug Henderson djndnbvg@gmail.com wrote: <>> Can someone suggest how to correct this snippet of code in the wiki <>> page to work now, or how to make a modified version of <>> "cross-build-mingw.sh" which will work for buildinig on mingw on a <>> Windows machine. < <On 09.09.21 06:31, Lex Trotman wrote: <> Not sure who posted the wiki or how relevant it is (its a wiki after <> all :), for example Geany now only supports GTK3, not GTK2. < <I think Thomas wrote the page initially and I edited it later on. So now <you know who to blame :). < < <> The official Windows build processes are currently under upgrade as a <> result, see https://github.com/geany/geany/pull/2590 and <> https://github.com/geany/geany-plugins/pull/1107. Not sure the status <> and if they are usable yet, but you might find the updated packages <> used there. < <They are usable and just need review. <With both PRs I built full Geany and Geany-Plugins on native Windows as <well as a cross built using Docker images. < < <> IIUC after this is complete it might be possible to make a docker <> container available to build Geany for windows with all the necessary <> dependencies, no guarantees though. <That's the plan and it already works quite well. Still need to be <polished and published and integrated in CI. < <Anyway, to get back to Doug's question: <I'm going to prepare Windows installers for the current master on the <weekend and so have some 1.38 beta or preview. < <I'll also try to update the wiki page to reflect the current state, much <has changed due to the switch to GTK3 and x86_64. But it might take a <little more time to finish. < <Regards, <Enrico <_______________________________________________ <Devel mailing list <Devel@lists.geany.org <https://lists.geany.org/cgi-bin/mailman/listinfo/devel
Attila, the windows build environment is completely different to the Linux one so your comment is irrelevant. Setting up the environment is the difficult part for most people.
Also you can just give configure an argument --enable-gtk3 rather than editing configure.ac, also on the current Geany master only gtk3 is supported so you don't even need that.
Cheers Lex
On Sat, 11 Sept 2021 at 03:18, Attila works@veghelyiattila.hu wrote:
Hi,
I do not know the Windows compiler environment, but on Linux I switched back the Gtk3 to Gtk2 successfully. Just change the 'configure.ac' at line 79 to `[enable_gtk2=yes])`. And of course install the Gtk2-dev packages.
You can see it (and my CI solution) here: https://gitlab.com/attila_v/geany
regards, Attila
PGP-PK: https://avesoft.hu/veghelyiattila.pk.gpg-key
<Hi, < <On Thu, 9 Sept 2021 at 14:05, Doug Henderson djndnbvg@gmail.com wrote: <>> Can someone suggest how to correct this snippet of code in the wiki <>> page to work now, or how to make a modified version of <>> "cross-build-mingw.sh" which will work for buildinig on mingw on a <>> Windows machine. < <On 09.09.21 06:31, Lex Trotman wrote: <> Not sure who posted the wiki or how relevant it is (its a wiki after <> all :), for example Geany now only supports GTK3, not GTK2. < <I think Thomas wrote the page initially and I edited it later on. So now <you know who to blame :). < < <> The official Windows build processes are currently under upgrade as a <> result, see https://github.com/geany/geany/pull/2590 and <> https://github.com/geany/geany-plugins/pull/1107. Not sure the status <> and if they are usable yet, but you might find the updated packages <> used there. < <They are usable and just need review. <With both PRs I built full Geany and Geany-Plugins on native Windows as <well as a cross built using Docker images. < < <> IIUC after this is complete it might be possible to make a docker <> container available to build Geany for windows with all the necessary <> dependencies, no guarantees though. <That's the plan and it already works quite well. Still need to be <polished and published and integrated in CI. < <Anyway, to get back to Doug's question: <I'm going to prepare Windows installers for the current master on the <weekend and so have some 1.38 beta or preview. < <I'll also try to update the wiki page to reflect the current state, much <has changed due to the switch to GTK3 and x86_64. But it might take a <little more time to finish. < <Regards, <Enrico <_______________________________________________ <Devel mailing list <Devel@lists.geany.org <https://lists.geany.org/cgi-bin/mailman/listinfo/devel _______________________________________________ Devel mailing list Devel@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/devel
On 10.09.21 00:05, Enrico Tröger wrote:
Hi,
On Thu, 9 Sept 2021 at 14:05, Doug Henderson djndnbvg@gmail.com wrote:
Can someone suggest how to correct this snippet of code in the wiki page to work now, or how to make a modified version of "cross-build-mingw.sh" which will work for buildinig on mingw on a Windows machine.
On 09.09.21 06:31, Lex Trotman wrote:
Not sure who posted the wiki or how relevant it is (its a wiki after all :), for example Geany now only supports GTK3, not GTK2.
I think Thomas wrote the page initially and I edited it later on. So now you know who to blame :).
The official Windows build processes are currently under upgrade as a result, see https://github.com/geany/geany/pull/2590 and https://github.com/geany/geany-plugins/pull/1107. Not sure the status and if they are usable yet, but you might find the updated packages used there.
They are usable and just need review. With both PRs I built full Geany and Geany-Plugins on native Windows as well as a cross built using Docker images.
IIUC after this is complete it might be possible to make a docker container available to build Geany for windows with all the necessary dependencies, no guarantees though.
That's the plan and it already works quite well. Still need to be polished and published and integrated in CI.
Anyway, to get back to Doug's question: I'm going to prepare Windows installers for the current master on the weekend and so have some 1.38 beta or preview.
The test installers are ready:
https://download.geany.org/snapshots/geany-1.38beta1_setup.exe https://download.geany.org/snapshots/geany-plugins-1.38beta1_setup.exe
They are built from current GIT master, with the following unmerged PRs included: https://github.com/geany/geany/pull/2892 https://github.com/geany/geany/pull/2590 https://github.com/geany/geany-plugins/pull/1107
Regards, Enrico
On Sat, 11 Sept 2021 at 07:08, Enrico Tröger enrico.troeger@uvena.de wrote:
On 10.09.21 00:05, Enrico Tröger wrote:
Hi,
On Thu, 9 Sept 2021 at 14:05, Doug Henderson djndnbvg@gmail.com wrote:
Can someone suggest how to correct this snippet of code in the wiki
On 09.09.21 06:31, Lex Trotman wrote:
Not sure who posted the wiki or how relevant it is (its a wiki after
Anyway, to get back to Doug's question: I'm going to prepare Windows installers for the current master on the weekend and so have some 1.38 beta or preview.
The test installers are ready:
https://download.geany.org/snapshots/geany-1.38beta1_setup.exe https://download.geany.org/snapshots/geany-plugins-1.38beta1_setup.exe
Regards, Enrico
Thanks. I downloaded and installed both of these. So far they have worked flawlessly, although I have not done much actual work, instead, just re-exploring the interface and preferences. I have a few observations, questions and suggestions.
- the slow project loading of 1.37.1 is corrected.
- the visual style of scrollbars on the edit window is different. The scrollbars are now about half the width as formerly. The previous scrollbars were about twice as wide, making it much easier to grab the thumb. The Win10 style is a narrow scrollbar that gets wider when you hover over them. Is it possible to have a choice, or at least an OS style scrollbar?
- The help button does not work on any preference page. It reports, e.g.: 21:16:09: Failed to open URI "C:/Program Files/Geany/share/doc/geany/html/index.html#various-preferences": The system cannot find the file specified. And in the Debug Messages: 21:16:14: Geany WARNING : ShellExecute failed opening "C:/Program Files/Geany/share/doc/geany/html/index.html#various-preferences" (code 2): The system cannot find the file specified. The menu item "Help->help" and pressing "F1" correctly open the help file in Firefox Nightly at "file:///C:/Program%20Files/Geany/share/doc/geany/html/index.html"
- The help file does not declare its character encoding so the 3rd non-blank line contains "Authors: Enrico Tröger".
- The menu item "Tools->Load Tags File..." uses a non-windows style file search dialog.
- The menu item "Help->Debug Messages" opens a very small window. Opening the window with a size of relative to the main geany window, or perhaps safer, relative to the screen size would be nice. Some messages do not have the timestamp prefix. Many debug messages have the same time stamp, so adding the milliseconds value would be helpful.
- The keybinding for entering unicode characters is documented, but the key combo Ctrl-Shift-u does not seem to work at all in 1.38beta1. The ability to enter unicode characters is almost a requirement for me.
- Geany on Win10 can be crashed every time by opening the open file dialog, shift-right-click on a filename and selecting "Copy as path". Shortly after canceling the open file dialog, geany will crash. There are two entries in the Event Viewer -> Windows Logs -> Application. The following info from the Error entry (incomplete):
Faulting application name: geany.exe, version: 1.38.0.0, time stamp: 0x00000000 Faulting module name: libcairo-2.dll, version: 0.0.0.0, time stamp: 0x00000000 Exception code: 0xc0000005 Fault offset: 0x0000000000050f63 Faulting application name: geany.exe, version: 1.38.0.0, time stamp: 0x00000000 Faulting module name: libcairo-2.dll, version: 0.0.0.0, time stamp: 0x00000000 Exception code: 0xc0000005 Fault offset: 0x0000000000050f63
indicates the fault occured in libcairo-2.dll. The circumstances suggest that the clipboard buffer for the copied file path is incorrectly allocated or incorrectly identified as shared public or some such thing, so that cairo attempts to free a memory block owned by the clipboard. Does geany provide a callback to libcairo which allocates memory? If this is a libcairo error, it should be occurring for every GTK3 app on windows with a file opener dialog. In 2018,I opened the issue "Win10 crash after "Copy as Path" from open file dialog #1942" for geany 1.33 https://github.com/geany/geany/issues/1942 which seems to be the same problem.
I plan to continue to use this version of geany as my main editor/IDE.
Thanks, Doug
On Sun, 12 Sept 2021 at 15:11, Doug Henderson djndnbvg@gmail.com wrote:
On Sat, 11 Sept 2021 at 07:08, Enrico Tröger enrico.troeger@uvena.de wrote:
On 10.09.21 00:05, Enrico Tröger wrote:
Hi,
On Thu, 9 Sept 2021 at 14:05, Doug Henderson djndnbvg@gmail.com wrote:
Can someone suggest how to correct this snippet of code in the wiki
On 09.09.21 06:31, Lex Trotman wrote:
Not sure who posted the wiki or how relevant it is (its a wiki after
Anyway, to get back to Doug's question: I'm going to prepare Windows installers for the current master on the weekend and so have some 1.38 beta or preview.
The test installers are ready:
https://download.geany.org/snapshots/geany-1.38beta1_setup.exe https://download.geany.org/snapshots/geany-plugins-1.38beta1_setup.exe
Regards, Enrico
Thanks. I downloaded and installed both of these. So far they have worked flawlessly, although I have not done much actual work, instead, just re-exploring the interface and preferences. I have a few observations, questions and suggestions.
the slow project loading of 1.37.1 is corrected.
the visual style of scrollbars on the edit window is different. The
scrollbars are now about half the width as formerly. The previous scrollbars were about twice as wide, making it much easier to grab the thumb. The Win10 style is a narrow scrollbar that gets wider when you hover over them. Is it possible to have a choice, or at least an OS style scrollbar?
I assume you mean the scrollbars on the edit window, those are drawn by the Scintilla editing widget Geany uses, and AFAICT its API gives no way of setting that width.
- The help button does not work on any preference page. It reports, e.g.: 21:16:09: Failed to open URI "C:/Program
Files/Geany/share/doc/geany/html/index.html#various-preferences": The system cannot find the file specified. And in the Debug Messages: 21:16:14: Geany WARNING : ShellExecute failed opening "C:/Program Files/Geany/share/doc/geany/html/index.html#various-preferences" (code 2): The system cannot find the file specified.
Did you check if the file exists? Or has been installed to a different location?
The menu item "Help->help" and pressing "F1" correctly open the help file in Firefox Nightly at "file:///C:/Program%20Files/Geany/share/doc/geany/html/index.html"
Not sure why this uses a different method to the other help, although technically the other is better as it uses the native open that will choose the default browser without having to have the Preferences->Tools->Browser (default "firefox" as you found) setting configured.
- The help file does not declare its character encoding so the 3rd
non-blank line contains "Authors: Enrico Tröger".
The 4 th line of the help file should be:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
so it should open as UTF-8, maybe something went wrong in the building?
- The menu item "Tools->Load Tags File..." uses a non-windows style
file search dialog.
You can make an issue for that, but probably somebody will have to contribute the code for it.
- The menu item "Help->Debug Messages" opens a very small window.
Opening the window with a size of relative to the main geany window, or perhaps safer, relative to the screen size would be nice. Some messages do not have the timestamp prefix. Many debug messages have the same time stamp, so adding the milliseconds value would be helpful.
Request a feature addition, although I think the timestamp is added by Glib, so we might not be able to control it.
- The keybinding for entering unicode characters is documented, but
the key combo Ctrl-Shift-u does not seem to work at all in 1.38beta1. The ability to enter unicode characters is almost a requirement for me.
- Geany on Win10 can be crashed every time by opening the open file
dialog, shift-right-click on a filename and selecting "Copy as path".
Not sure what "copy as path" is, but its not something Geany supplies or uses, presumably its part of the native dialog, so Geany has no control over it.
Shortly after canceling the open file dialog, geany will crash. There are two entries in the Event Viewer -> Windows Logs -> Application. The following info from the Error entry (incomplete):
Faulting application name: geany.exe, version: 1.38.0.0, time stamp: 0x00000000 Faulting module name: libcairo-2.dll, version: 0.0.0.0, time stamp: 0x00000000 Exception code: 0xc0000005 Fault offset: 0x0000000000050f63 Faulting application name: geany.exe, version: 1.38.0.0, time stamp: 0x00000000 Faulting module name: libcairo-2.dll, version: 0.0.0.0, time stamp: 0x00000000 Exception code: 0xc0000005 Fault offset: 0x0000000000050f63
indicates the fault occured in libcairo-2.dll. The circumstances suggest that the clipboard buffer for the copied file path is incorrectly allocated or incorrectly identified as shared public or some such thing, so that cairo attempts to free a memory block owned by the clipboard. Does geany provide a callback to libcairo which allocates memory?
There does not appear to be any Geany code, its in Cairo dll.
But if it is a callback while a dialog is in progress that calls Geany then its potentially a problem, Geany is not reentrant, its expecting to wait for the dialog reply, not do anything else until thats complete.
If this is a libcairo error, it should be occurring for every GTK3 app on windows with a file opener dialog.
Its possible that happens :-) did you google?
In 2018,I opened the issue "Win10 crash after "Copy as Path" from open file dialog #1942" for geany 1.33 https://github.com/geany/geany/issues/1942 which seems to be the same problem.
I plan to continue to use this version of geany as my main editor/IDE.
Thanks, Doug
Cheers Lex
-- Doug Henderson, Calgary, Alberta, Canada - from gmail.com _______________________________________________ Devel mailing list Devel@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/devel
Some messages do not have the timestamp prefix. Many debug messages have the same time stamp, so adding the milliseconds value would be helpful.
Request a feature addition, although I think the timestamp is added by Glib, so we might not be able to control it.
And here is one Enrico prepared beforehand https://github.com/geany/geany/pull/2659
(I have been watching too many cooking shows I think :-)
Cheers Lex
Hi,
The test installers are ready:
https://download.geany.org/snapshots/geany-1.38beta1_setup.exe https://download.geany.org/snapshots/geany-plugins-1.38beta1_setup.exe
Thanks. I downloaded and installed both of these. So far they have worked flawlessly, although I have not done much actual work, instead, just re-exploring the interface and preferences. I have a few observations, questions and suggestions.
Thanks for testing and your feedback!
- the slow project loading of 1.37.1 is corrected.
Great!
- the visual style of scrollbars on the edit window is different. The
scrollbars are now about half the width as formerly. The previous scrollbars were about twice as wide, making it much easier to grab the thumb. The Win10 style is a narrow scrollbar that gets wider when you hover over them. Is it possible to have a choice, or at least an OS style scrollbar?
I assume you mean the scrollbars on the edit window, those are drawn by the Scintilla editing widget Geany uses, and AFAICT its API gives no way of setting that width.
I think this is rather the GTK3 default theme. Attached are three screenshots of Geany with: - the default theme (I assume it's Adwaita) - the native "win32" theme - a theme from https://www.gnome-look.org/p/1013580/ called "Windows10", it's more compact than the default theme
Doug, might you share a screenshot of "your" Geany? :)
- The help button does not work on any preference page. It reports, e.g.: 21:16:09: Failed to open URI "C:/Program
Files/Geany/share/doc/geany/html/index.html#various-preferences": The system cannot find the file specified. And in the Debug Messages: 21:16:14: Geany WARNING : ShellExecute failed opening "C:/Program Files/Geany/share/doc/geany/html/index.html#various-preferences" (code 2): The system cannot find the file specified.
Did you check if the file exists? Or has been installed to a different location?
The menu item "Help->help" and pressing "F1" correctly open the help file in Firefox Nightly at "file:///C:/Program%20Files/Geany/share/doc/geany/html/index.html"
Not sure why this uses a different method to the other help, although
It's the same method and that's part of the problem. Opening URIs works pretty fine from within Geany except they contain anchors. There is already an issue for it with all the boring details: https://github.com/geany/geany/issues/2405
- The help file does not declare its character encoding so the 3rd
non-blank line contains "Authors: Enrico Tröger".
The 4 th line of the help file should be:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
so it should open as UTF-8, maybe something went wrong in the building?
Yes, the charset header is fine the broken characters are already wrongly written into the generated HTML. I will have a look at it.
- The menu item "Tools->Load Tags File..." uses a non-windows style
file search dialog.
You can make an issue for that, but probably somebody will have to contribute the code for it.
As said in https://github.com/geany/geany/issues/1942, I'd rather vote for removing the native dialogs.
- The menu item "Help->Debug Messages" opens a very small window.
Opening the window with a size of relative to the main geany window, or perhaps safer, relative to the screen size would be nice. Some
Agreed. Not sure whether it's worth the efforts. This dialog is usually not opened regularly. Btw, this is not Windows specific, it's the same behavior on all platforms.
messages do not have the timestamp prefix. Many debug messages have the same time stamp, so adding the milliseconds value would be helpful.
Request a feature addition, although I think the timestamp is added by Glib, so we might not be able to control it.
We are and we had https://github.com/geany/geany/pull/2659 for it. It's now merged and will be included in the next build.
Do you have examples of messages without timestamps? I see messages like: 10:58:28: GLib-GIO DEBUG : Collecting capable appnames: 0ms Allocating hashtables:...... 0ms Reading capable apps: 32ms Reading URL associations:... 0ms Reading extension assocs: 78ms Reading exe-only apps:...... 46ms Reading classes: 266ms Reading UWP apps: 0ms Postprocessing:..............0ms TOTAL: 422ms
But this seems to be one single message just with line breaks.
- The keybinding for entering unicode characters is documented, but
the key combo Ctrl-Shift-u does not seem to work at all in 1.38beta1. The ability to enter unicode characters is almost a requirement for me.
It's just different on Windows.
https://en.wikipedia.org/wiki/Unicode_input#In_Microsoft_Windows
https://support.microsoft.com/en-us/topic/insert-ascii-or-unicode-latin-base...
I guess one those methods might work. I wasn't able to get it working even in Notepad but I might not have tried hard enough (and I didn't logged out after adding the registry key). If you find a working way, we could update the documentation.
- Geany on Win10 can be crashed every time by opening the open file
dialog, shift-right-click on a filename and selecting "Copy as path".
Let's discuss this in https://github.com/geany/geany/issues/1942
Regards, Enrico
On Sun, 12 Sept 2021 at 06:13, Enrico Tröger enrico.troeger@uvena.de wrote:
Doug, might you share a screenshot of "your" Geany? :)
Here's a screenshot, down converted to 8 bit color for size.
On Sun, 12 Sept 2021 at 06:13, Enrico Tröger enrico.troeger@uvena.de wrote:
I think this is rather the GTK3 default theme. Attached are three screenshots of Geany with:
- the default theme (I assume it's Adwaita)
- the native "win32" theme
- a theme from https://www.gnome-look.org/p/1013580/ called "Windows10",
it's more compact than the default theme
From your screen shots, it is clear that you have the win32 and
Windows10 themes installed.
The win32 theme works, but does not look as nice as the Windows10 theme.
How do you install a GTK3 theme on Windows? The linked page only describes the install for *nix.
Google yields a confusing number of results that are full of alternatives for the developer, but without much guidance for the post installation user.
Thanks, Doug.
On 12.09.21 18:51, Doug Henderson wrote:
On Sun, 12 Sept 2021 at 06:13, Enrico Tröger enrico.troeger@uvena.de wrote:
I think this is rather the GTK3 default theme. Attached are three screenshots of Geany with:
- the default theme (I assume it's Adwaita)
- the native "win32" theme
- a theme from https://www.gnome-look.org/p/1013580/ called "Windows10",
it's more compact than the default theme
From your screen shots, it is clear that you have the win32 and Windows10 themes installed.
The win32 theme works, but does not look as nice as the Windows10 theme.
How do you install a GTK3 theme on Windows? The linked page only describes the install for *nix.
Google yields a confusing number of results that are full of alternatives for the developer, but without much guidance for the post installation user.
I know :(.
Here we go: Create or edit the file `C:\Users<username>AppData\Local\gtk-3.0\settings.ini` with the following content: ```ini [Settings] gtk-theme-name=Windows10 ```
And your theme files should be located in `C:\Users<username>\AppData\Local\themes\Windows10`.
Interestingly, even the GTK docs[1] suggest to *not* use Adwaita but rather https://github.com/B00merang-Project/Windows-10.
And yes, I'll put the steps above into the wiki.
Regards, Enrico
[1] https://www.gtk.org/docs/installations/windows/#building-and-distributing-yo...
The menu item "Help->help" and pressing "F1" correctly open the help file in Firefox Nightly at "file:///C:/Program%20Files/Geany/share/doc/geany/html/index.html"
Not sure why this uses a different method to the other help, although
It's the same method and that's part of the problem.
Oh, I hadn't though a Windowsist would have set Friedfox as the default browser, does that mean on windows the Preferences->Tools->Browser setting is ignored totally?
Opening URIs works pretty fine from within Geany except they contain anchors. There is already an issue for it with all the boring details: https://github.com/geany/geany/issues/2405
- The help file does not declare its character encoding so the 3rd
non-blank line contains "Authors: Enrico Tröger".
The 4 th line of the help file should be:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
so it should open as UTF-8, maybe something went wrong in the building?
Yes, the charset header is fine the broken characters are already wrongly written into the generated HTML. I will have a look at it.
I don't generate HTML docs so I can't check here, but the HTML in the 1.37.1 tarball and the nightly .deb seems to have Enrico correct (or at least it shows correctly on both Chrome and Firefox), maybe docutils or the browser does something silly if it runs on windows?
Doug, I'm assuming you mean the Enrico in the little Authors table at the top of the help manual?
...
- The menu item "Help->Debug Messages" opens a very small window.
Opening the window with a size of relative to the main geany window, or perhaps safer, relative to the screen size would be nice. Some
Agreed. Not sure whether it's worth the efforts. This dialog is usually not opened regularly. Btw, this is not Windows specific, it's the same behavior on all platforms.
Unless its extra small on Windows then its still usable, so agree low priority.
Cheers Lex
On 13.09.21 01:03, Lex Trotman wrote:
The menu item "Help->help" and pressing "F1" correctly open the help file in Firefox Nightly at "file:///C:/Program%20Files/Geany/share/doc/geany/html/index.html"
Not sure why this uses a different method to the other help, although
It's the same method and that's part of the problem.
Oh, I hadn't though a Windowsist would have set Friedfox as the default browser, does that mean on windows the Preferences->Tools->Browser setting is ignored totally?
Yes.
- The help file does not declare its character encoding so the 3rd
non-blank line contains "Authors: Enrico Tröger".
The 4 th line of the help file should be:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
so it should open as UTF-8, maybe something went wrong in the building?
Yes, the charset header is fine the broken characters are already wrongly written into the generated HTML. I will have a look at it.
I don't generate HTML docs so I can't check here, but the HTML in the 1.37.1 tarball and the nightly .deb seems to have Enrico correct (or at least it shows correctly on both Chrome and Firefox), maybe docutils or the browser does something silly if it runs on windows?
It's Python and not generally on Windows but on my box. On my Windows box, Python detects de-DE with cp1252 charset as locale and rst2html (which is written in Python) then seems to read the UTF-8 encoded geany.txt with cp1252 and this fails, obviously.
I didn't find a way yet to change the locale used by Python, the usual LANG, LANGUAGE, LC_ALL and friends environment variables do not work. It seems Python uses some Windows API to get the locale. But it's mainly a local issue on my end, so no worries. I'll take care to pass "--input-encoding=utf-8" to rst2html when building the docs for the next release and after the release, I'm going to blow up my Windows box anyways.
Doug, I'm assuming you mean the Enrico in the little Authors table at the top of the help manual?
I guess yes because my name is broken there.
Regards, Enrico
It's Python and not generally on Windows but on my box. On my Windows box, Python detects de-DE with cp1252 charset as locale and rst2html (which is written in Python) then seems to read the UTF-8 encoded geany.txt with cp1252 and this fails, obviously.
I didn't find a way yet to change the locale used by Python, the usual LANG, LANGUAGE, LC_ALL and friends environment variables do not work. It seems Python uses some Windows API to get the locale. But it's mainly a local issue on my end, so no worries. I'll take care to pass "--input-encoding=utf-8" to rst2html when building the docs for the next release and after the release, I'm going to blow up my Windows box anyways.
Locales are an evil and dangerous thing from the past!!! Why should non-interactive programs run differently on different machines? [stop before I start ranting]
Ok, so its the Geany build makefile that needs to have the specification of input encoding added so it works everywhere and no risk of non-UTF-8 locales breaking it.
Cheers Lex
On 14.09.21 00:34, Lex Trotman wrote:
It's Python and not generally on Windows but on my box. On my Windows box, Python detects de-DE with cp1252 charset as locale and rst2html (which is written in Python) then seems to read the UTF-8 encoded geany.txt with cp1252 and this fails, obviously.
I didn't find a way yet to change the locale used by Python, the usual LANG, LANGUAGE, LC_ALL and friends environment variables do not work. It seems Python uses some Windows API to get the locale. But it's mainly a local issue on my end, so no worries. I'll take care to pass "--input-encoding=utf-8" to rst2html when building the docs for the next release and after the release, I'm going to blow up my Windows box anyways.
Locales are an evil and dangerous thing from the past!!! Why should non-interactive programs run differently on different machines? [stop before I start ranting]
Ok, so its the Geany build makefile that needs to have the specification of input encoding added so it works everywhere and no risk of non-UTF-8 locales breaking it.
Not sure if it is necessary. The concrete problem with the wrongly encoded characters is rather a configuration problem on my system, I'd say. Anyway, generally enforcing UTF-8 on rst2html for geany.txt should be fine as we have full control over the file and it probably will stay UTF-8 encoded for the next 20 years.
Regards, Enrico
On Mon, 13 Sept 2021 at 15:55, Enrico Tröger enrico.troeger@uvena.de wrote:
Doug, I'm assuming you mean the Enrico in the little Authors table at the top of the help manual?
I guess yes because my name is broken there.
Attached is an image of what I see:
And here is the offending line from file:///C:/Program%20Files/Geany/share/doc/geany/html/index.html:for 1.38beta1 on win10.
<meta name="authors" content="Enrico Tröger Nick Treleaven Frank Lanitz Colomban Wendling Matthew Brush" />
And a dump of that line:
$ head -8 index.html | tail -1 | od -c 0000000 < m e t a n a m e = " a u t h 0000020 o r s " c o n t e n t = " E n 0000040 r i c o T r 303 203 302 266 g e r 0000060 N i c k T r e l e a v e n 0000100 F r a n k L a n i t z C o 0000120 l o m b a n W e n d l i n g 0000140 M a t t h e w B r u s h " 0000160 / > \r \n 0000164
This tells me that at some point the UTF8 content was loaded as ISO-8859-?
So looking at https://nightly.geany.org/win32/build_win32_geany.log, the problem is clear: the build is using Python 2.7. Python2 will read the file as ASCII by default, while Python3 will try to detect the encoding and fall back to UTF-8. Plus Python2 is now unsupported.
When I tried to recreate the problem on msys and cygwin for 1.31.1, 1.36, and 1.37.1 , I could not reproduce it because I have Python3 installed as the only Python on both systems. I spent more time than I should have on this, and I think you may have found a solution yourself.
Also this the results from the locale command:
Doug@mars MINGW64 ~/src/MINGW-packages/mingw-w64-geany $ locale LANG=en_CA.UTF-8 LC_CTYPE="en_CA.UTF-8" LC_NUMERIC="en_CA.UTF-8" LC_TIME="en_CA.UTF-8" LC_COLLATE="en_CA.UTF-8" LC_MONETARY="en_CA.UTF-8" LC_MESSAGES="en_CA.UTF-8" LC_ALL=
On cygwin, I get the same, but with LC_ALL having the same value.
Also:
Microsoft Windows [Version 10.0.19043.1165] (c) Microsoft Corporation. All rights reserved.
Doug@MARS C:\Users\Doug
chcp
Active code page: 65001
Code page 65001 specifies UTF-8
MINGW64_NT-10.0-19043 mars 3.2.0-340.x86_64 2021-08-02 16:30 UTC x86_64 Msys CYGWIN_NT-10.0 mars 3.2.0(0.340/5/3) 2021-03-29 08:42 x86_64 Cygwin
Doug
-- Doug Henderson, Calgary, Alberta, Canada - from gmail.com
So looking at https://nightly.geany.org/win32/build_win32_geany.log, the problem is clear: the build is using Python 2.7. Python2 will read the file as ASCII by default, while Python3 will try to detect the encoding and fall back to UTF-8. Plus Python2 is now unsupported.
When I tried to recreate the problem on msys and cygwin for 1.31.1, 1.36, and 1.37.1 , I could not reproduce it because I have Python3 installed as the only Python on both systems. I spent more time than I should have on this, and I think you may have found a solution yourself.
Thanks for pointing this out, in fact the configure script needs fixing on Linux as well, it checks for "python" not "python3" (AFAICT I'm crap at autofools). Explains why HTML fails to build here because there is no "python" command anymore so the configure fails even though "python3" is available and "rst2html" specifies #!/usr/bin/python3. It also does some weirdness using "py" for the python command on windows which according to the Python docs should find the latest version installed or the version in the script, ie what rst2html explicitly specifies, even if its in Unix form /usr/bin/python3.
Cheers Lex
On Wed, 15 Sept 2021 at 08:57, Lex Trotman elextr@gmail.com wrote:
So looking at https://nightly.geany.org/win32/build_win32_geany.log, the problem is clear: the build is using Python 2.7. Python2 will read the file as ASCII by default, while Python3 will try to detect the encoding and fall back to UTF-8. Plus Python2 is now unsupported.
When I tried to recreate the problem on msys and cygwin for 1.31.1, 1.36, and 1.37.1 , I could not reproduce it because I have Python3 installed as the only Python on both systems. I spent more time than I should have on this, and I think you may have found a solution yourself.
Thanks for pointing this out, in fact the configure script needs fixing on Linux as well, it checks for "python" not "python3" (AFAICT I'm crap at autofools). Explains why HTML fails to build here because there is no "python" command anymore so the configure fails even though "python3" is available and "rst2html" specifies #!/usr/bin/python3. It also does some weirdness using "py" for the python command on windows which according to the Python docs should find the latest version installed or the version in the script, ie what rst2html explicitly specifies, even if its in Unix form /usr/bin/python3.
#2896 raised.
Cheers Lex
On 14.09.21 15:36, Doug Henderson wrote:
On Mon, 13 Sept 2021 at 15:55, Enrico Tröger enrico.troeger@uvena.de wrote:
Doug, I'm assuming you mean the Enrico in the little Authors table at the top of the help manual?
I guess yes because my name is broken there.
Attached is an image of what I see:
And here is the offending line from file:///C:/Program%20Files/Geany/share/doc/geany/html/index.html:for 1.38beta1 on win10.
<meta name="authors" content="Enrico Tröger Nick Treleaven Frank Lanitz Colomban Wendling Matthew Brush" />
[...]
This tells me that at some point the UTF8 content was loaded as ISO-8859-?
Yes, because of my misconfigured Windows machine.
So looking at https://nightly.geany.org/win32/build_win32_geany.log, the problem is clear: the build is using Python 2.7. Python2 will read
Not really. First, the nightly builds are created in a very old setup (no MSYS2, old, manually installed Win32 libraries). I won't update it anymore and so it's stuck to its Python2. I'm working on a replacement to cross-compile Geany with MSYS2 packages from a GIT clone to fully working installer binary.
Then, the mentioned nightly builds are not used for anything, they are just used as CI to ensure the code still compiles. The installers I posted were created manually by me on a real Windows machine.
When I tried to recreate the problem on msys and cygwin for 1.31.1, 1.36, and 1.37.1 , I could not reproduce it because I have Python3 installed as the only Python on both systems. I spent more time than I should have on this, and I think you may have found a solution yourself.
Yes, as I said before on the other mail in the thread, it's only a problem with the setup of my Windows system. It's not a general issue in Geany. Thanks anyway for the detailed analysis!
Regards, Enrico