Hello Richard,

Sorry for the late answer: I was very busy on the next AGNoStep release... not 
yet finished.

On 2026-01-09 16:49:30 +0100 R Frith-Macdonald <[email protected]> 
wrote:


(...)

> 
> While it's true that GNUstep app wrapper support does not provide any 
> mechanism for the wrapped non-gnustep apps to open URLs on behalf of the 
> GNUstep workspace (so you currently have to write a service to invoke the 
> appropriate binary to open a URL), that's mostly because the wrapper support 
> in GNUstep pre-dates the Cocoa/Apple APIs for opening URLs, rather than any 
> technical problem.
> 
> So I have created a branch of the gui library (named app-wrapper-open-url) 
> with code to implement opening a URL using an app wrapper, so you can try 
> that out if you like.  Basically, when opening a URL rather than a file, the 
> script in thew wrapper is invoked with -GSOpenURL rather than -GSFilePath,  
> and the info plist needs to contain the information about the URL schemes 
> supported (example in the NSWorkspace class documentation after the example 
> ofusing an app wrapper to open a file).
> 

Again thank you for your kind attention, patience and expertise. So I built the 
new branch 'app-wrapper-open-url' and tested. Also, following your 
recommendations, I improved my 'Firefox.app' wrapper and my 'openURLService' to 
avoid bad firefox arguments.

Three tests were successfull:

- s1) Within a GNUMail message, clicking a link opens the expected URL in a new 
window of the Web browser: waiting time is also now a few seconds: great 
enhancement!

- s2) In a RTF file, selecting an URL and using the service 'Open URL' opens 
the expected URL.

- s3) Creating a link whom the text is the same as the URL allows us to click 
and to open the expected URL.

One test failed:

- f1) Creating a link whom the text is not the same as the URL (i.e.: text 
"GNUstep" and URL "https://www.gnustep.org/";) fails to open the expected URL by 
a click. Maybe more related to TextEdit or link format within a RTF file.

So things are in progress thank to your help.

I joined my wrapper and my openURLService to help everybody needing to work on 
this study case. Also a output of 'make_services'with the args '--schemes' and 
--service='Open URL'.

I also noted with 'Zipper' a kind of Delay issue: when selecting a folder to 
create a tarball, it complains: 
> Failed to contact service provider for 'Zipper/Create tar.gz archive': timed 
> out waiting for reply 15 (createZippedTarArchive:userData:error:) [Continue]
Althouh it shows the expected Open Panel to name the tarball and then the 
process is successful: the expected tarball is created.


<Logs_make_services.txt>


<openURLService.tar.gz>


<Wrapper_Firefox.app.tar.gz>

Cheers,
Patrick

-- 
Patrick Cardona - Pi400 - GNU/Linux aarch64 (Debian 13.3) 
Xorg (1:7.7+24) - libcairo2 (1.18.4-1+rpt1 arm64)
Window Maker (0.96.0-4) - GWorkspace (1.1.0 - 02 2025) - Theme: AGNOSTEP - MUA: 
GNUMail (Rev. 947)
Logs of make_services
=====================

patrick@pi400:~ $ make_services --schemes
URL Scheme      Applications
dict            Dictionary.app
http            Firefox.app
                NetSurf.app
https           Firefox.app
                NetSurf.app

patrick@pi400:~ $ make_services --service='Open URL'
Service named 'Open URL' is {NSKeyEquivalent = {English = O; default = O; }; 
NSMenuItem = {English = "Open URL"; French = "Ouvrir URL"; default = "Open 
URL"; }; NSMessage = openURLSelected; NSPortName = openURLService; NSSendTypes 
= (NSStringPboardType); ServicePath = 
"/Local/Library/Services/openURLService.service"; }.

Attachment: openURLService.tar.gz
Description: GNU Zip compressed data

Attachment: Wrapper_Firefox.app.tar.gz
Description: GNU Zip compressed data

Reply via email to