Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Murray Cumming
On Sat, 2008-07-12 at 19:15 -0700, Sohail Somani wrote: Yes, you are right. Copying the ustring to a std::string gets rid of the error but still doesn't work right because it is interpreted as ASCII in the console. std::cout does not understand UTF-8. That's why glibmm tries to do a

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Sohail Somani
Murray Cumming wrote: On Sat, 2008-07-12 at 19:15 -0700, Sohail Somani wrote: Yes, you are right. Copying the ustring to a std::string gets rid of the error but still doesn't work right because it is interpreted as ASCII in the console. std::cout does not understand UTF-8. That's why glibmm

Re: problem with FileChooserButton in save mode

2008-07-13 Thread [EMAIL PROTECTED]
On 13.07.2008 at 09:49, Murray Cumming [EMAIL PROTECTED] wrote: On Thu, 2008-07-10 at 11:08 +0200, [EMAIL PROTECTED] wrote: Hy guys! I am interested in using a Gtk::FileChooserButton with Gtk::FILE_CHOOSER_ACTION_SAVE or FILE_CHOOSER_ACTION_CREATE_FOLDER action. But when try to switch the

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Murray Cumming
On Sun, 2008-07-13 at 00:48 -0700, Sohail Somani wrote: Murray Cumming wrote: On Sat, 2008-07-12 at 19:15 -0700, Sohail Somani wrote: Yes, you are right. Copying the ustring to a std::string gets rid of the error but still doesn't work right because it is interpreted as ASCII in the

Re: problem with FileChooserButton in save mode

2008-07-13 Thread [EMAIL PROTECTED]
On 13.07.2008 at 11:48 Uhr, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: On 13.07.2008 at 09:49, Murray Cumming [EMAIL PROTECTED] wrote: On Thu, 2008-07-10 at 11:08 +0200, [EMAIL PROTECTED] wrote: Hy guys! I am interested in using a Gtk::FileChooserButton with Gtk::FILE_CHOOSER_ACTION_SAVE

[giomm] Why most methods are non virtual ?

2008-07-13 Thread Yann Cointepas
Hi, I am trying to find a way to extend GIO to support my own non standard directory-like and file-like C++ objects. I would like to create specialized implementations of Gio::File and corresponding classes (such as streams) for my objects. My own factory would return either a standard Gio::File

Re: [giomm] Why most methods are non virtual ?

2008-07-13 Thread Murray Cumming
On Sun, 2008-07-13 at 15:44 +0200, Yann Cointepas wrote: Hi, I am trying to find a way to extend GIO to support my own non standard directory-like and file-like C++ objects. I would like to create specialized implementations of Gio::File and corresponding classes (such as streams) for my

Gtkmm Windows Maintainership

2008-07-13 Thread Armin Burgmeier
Hi Cedric, I would like to experiment with building gtkmm and companion libraries on Windows with mingw and MSVC, to eventually take over maintainership of the Windows installer at least temporarily and/or partially. In a mail from April 2008 [1], you proposed to put the installer script into

Re: D-Bus C++ bindings dbus-c++

2008-07-13 Thread Andreas Volz
Am Mon, 7 Jul 2008 15:41:40 +0200 schrieb Christopher Lang: Hi, sorry, this is a bit off topic on gtkmm-list, but maybe some of you ran into a similar issue: I was looking for dbusmm C++ binding, and found this: http://www.freedesktop.org/wiki/Software/dbus-c%2B%2B Hello, I added

Re: D-Bus C++ bindings dbus-c++

2008-07-13 Thread Marko Anastasov
On Sun, Jul 13, 2008 at 6:14 PM, Andreas Volz [EMAIL PROTECTED] wrote: One problem is that nobody helped me to get a GIT access on freedesktop.org. This is really annoying! I thought about forking it for that reason. At the moment I deivelop my own version without commiting anything. It's

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Sohail Somani
Murray Cumming wrote: On Sat, 2008-07-12 at 19:15 -0700, Sohail Somani wrote: Yes, you are right. Copying the ustring to a std::string gets rid of the error but still doesn't work right because it is interpreted as ASCII in the console. std::cout does not understand UTF-8. That's why glibmm

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Chris Vine
On Sun, 13 Jul 2008 10:01:02 -0700 Sohail Somani [EMAIL PROTECTED] wrote: But yes, I need to figure out why the conversion is failing in the first place rather than trying these hacks (ustring - std::string). Conversions can fail for various reasons, but to start from the beginning have you set

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Sohail Somani
Chris Vine wrote: On Sun, 13 Jul 2008 10:01:02 -0700 Sohail Somani [EMAIL PROTECTED] wrote: But yes, I need to figure out why the conversion is failing in the first place rather than trying these hacks (ustring - std::string). Conversions can fail for various reasons, but to start from the

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Milosz Derezynski
I havevery little experience with charset conversion, but maybe Glib::IConv can help: http://gtkmm.org/docs/glibmm-2.4/docs/reference/html/classGlib_1_1IConv.html! 2008/7/13 Sohail Somani [EMAIL PROTECTED]: Murray Cumming wrote: On Sat, 2008-07-12 at 19:15 -0700, Sohail Somani wrote: Yes,

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Chris Vine
On Sun, 13 Jul 2008 14:54:38 -0700 Sohail Somani [EMAIL PROTECTED] wrote: Chris Vine wrote: Conversions can fail for various reasons, but to start from the beginning have you set a locale of any kind which handles non-ascii characters? In particular, have you called setlocale(LC_ALL,),

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Sohail Somani
Chris Vine wrote: On Sun, 13 Jul 2008 14:54:38 -0700 Sohail Somani [EMAIL PROTECTED] wrote: Chris Vine wrote: Conversions can fail for various reasons, but to start from the beginning have you set a locale of any kind which handles non-ascii characters? In particular, have you called

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Sohail Somani
Milosz Derezynski wrote: I havevery little experience with charset conversion, but maybe Glib::IConv can help: http://gtkmm.org/docs/glibmm-2.4/docs/reference/html/classGlib_1_1IConv.html Same here, but the code is actually dying in the same internal functions :-)

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Chris Vine
On Sun, 13 Jul 2008 15:17:31 -0700 Sohail Somani [EMAIL PROTECTED] wrote: Great, I thought this was exactly the problem as well! Now, do you know how I can set Windows XP to have a locale of UTF-8? I can't figure it out nor can I convince Professor Google to let me cheat on the test :-( Ah,

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Sohail Somani
Indeed. The magic for setlocale on Windows escapes me (btw, it was supposed to be setlocale(LC_ALL,), not setlocale(LC_ALL,0)). According to MSDN the *only* things you can't set through setlocale are UTF-8 and UTF-7. Wonderful... Milosz Derezynski wrote: Then i guess you would somehow need to

Re: std::cout Glib::ustring(utf8_literal) throws exception

2008-07-13 Thread Sohail Somani
Chris Vine wrote: On Sun, 13 Jul 2008 15:17:31 -0700 However, why not convert your string to UTF-16 and output it that way (using wcout)? I know very little about windows consoles (except of course that UTF-16 is the worst of all possible choices), but I assume wcout will handle a non-fixed