Re: Standardizing file open etc
- From: Michael Cronenworth <mike cchtml com>
- To: gtk-app-devel-list gnome org
- Subject: Re: Standardizing file open etc
- Date: Mon, 23 Jan 2012 09:01:58 -0600
Mixbus JohnE wrote:
Our 'C' program uses 'open()' and the like for dealing with disk files. This seems to work okay on Linux but
not so well on Windows if there are (say) Greek or Russian characters in the file path. I'm not a Linux
programmer so I assume that 'open()' on Linux must be UTF-8 aware maybe??
g_filename_from_utf8()
On Windows I'd need to use '_wopen()' in this context but that would mean having different code for Windows
and Linux. Is there anything built into Glib that could help with this? e.g. a function which can take a
UTF-8 encoded file path and open the file successfully, whether on Windows or Linux? Thanks.
g_open()
Read the documentation pages surrounding the two functions I suggested
to understand how they work on Windows.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]