Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Launching a URL with multibyte characters problem
Launching a URL with multibyte characters problem [message #452276] Wed, 16 March 2005 17:36 Go to next message
Mike Boyersmith is currently offline Mike BoyersmithFriend
Messages: 143
Registered: July 2009
Senior Member
Question:

What is the proper way to construct a file: protocol URL with multibyte
characters as part of the path to the file? (its file: because it points
to a file on the local system and the path may have folders with
multibyte characters).

Problem Description:

So I try to launch a browser using
org.eclipse.swt.program.Program.launch(urlStr);
where urlstr is constructed as "file:////root/???/mypage.html"

On Linux if I pass file:////root/???/mypage.html where ??? are extended
characters from a language like chinese or german, the browser fails to
load the file and gives a manged error message (the URL is mangled
badly). something like "file:// /root/????/ mypage.html". Owch.... where
??? are other extended characters, and the slashes and spaces are
screwed up.

so I have tried doing my own encoding using URLEncoder but have ran into
a whole other set of issues.

anyone ever see this problem, any solutions to this?
Re: Launching a URL with multibyte characters problem [message #452285 is a reply to message #452276] Wed, 16 March 2005 22:06 Go to previous message
Mike Boyersmith is currently offline Mike BoyersmithFriend
Messages: 143
Registered: July 2009
Senior Member
Mike Boyersmith wrote:
> Question:
>
> What is the proper way to construct a file: protocol URL with multibyte
> characters as part of the path to the file? (its file: because it points
> to a file on the local system and the path may have folders with
> multibyte characters).
>
> Problem Description:
>
> So I try to launch a browser using
> org.eclipse.swt.program.Program.launch(urlStr);
> where urlstr is constructed as "file:////root/???/mypage.html"
>
> On Linux if I pass file:////root/???/mypage.html where ??? are extended
> characters from a language like chinese or german, the browser fails to
> load the file and gives a manged error message (the URL is mangled
> badly). something like "file:// /root/????/ mypage.html". Owch.... where
> ??? are other extended characters, and the slashes and spaces are
> screwed up.
>
> so I have tried doing my own encoding using URLEncoder but have ran into
> a whole other set of issues.
>
> anyone ever see this problem, any solutions to this?


follow up to self, I found this problem is documented as a bug in
bugzilla see defect 263570
Previous Topic:CTabItem doesn't show in SashForm until clicked
Next Topic:getSize() always returns Point{0,0} on Button in GridLayout
Goto Forum:
  


Current Time: Thu Apr 25 01:15:15 GMT 2024

Powered by FUDForum. Page generated in 0.03894 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top