Vadim,
Thank you for your reply.
On Thu, Feb 7, 2013 at 2:40 PM, Vadim Zeitlin <
va...@wxwidgets.org> wrote:
> - Please use "--cxxflags", these are C++ compiler flags
Yes, thank you for the correction.
> - I assume that you built wxWidgets in Unicode mode
I fell short in my attempt to be explicit. For my step (3) I said:
> > Install wxWidgets-2.8 and GCC 4.6
But I should have said:
sudo apt-get installbuild-essential libwxgtk2.8-dev
This does indeed install a unicode version.
> This depends entirely on the encoding of the string "StlString".
I do not know how to select an encoding when using std::string. Even
if I knew how I would not know which encoding I would even want to
select! Lucky for me I could describe my process from "purchase
computer" to "compile wx-dependent code" and you were able to deduce
this for me (thank you!):
> In your
> example above it consists of 7 bit ASCII characters
Okay good to know! :)
> CS> a) wxConvLibc
> CS> b) wxConvLocal
> CS> c) wxConvUI
> CS> d) wxConvISO8859_1
> CS> e) wxConvUTF8
> CS> f) wxConvFile
> CS> g) none of the above
>
> ... any of the above except (g) which won't compile.
Wow... what a surprise. I definitely was not expecting "any of the
above". This whole string thing is simultaneously complicated and
simple!
> Because it absolutely doesn't matter which conversion you use for ASCII
> characters. As soon as you have anything else, you do need to choose the
> conversion carefully.
Vadim:
I will summarize the first half of your post like this: "Chris, it
looks like you are using std::string. Therefore you are using ASCII.
Therefore you do not need to worry about any of this. Select any
wxMBConv randomly (because you are using ASCII) and you will be fine.
When you are not using ASCII you need to be careful".
Not only did I now know that I was using "ASCII encoding"... I did not
know I could even select a different kind of encoding. I have no idea
how, when or why I would ever switch from ASCII (which I did not even
know I was using) to something else.
I've used std::string (ASCII) to hold filenames and never needed to
know/understand/contemplate "filename encoding".
I've passed strings to other 3rd party libraries without ever asking
them which encoding they use.
I've even written windows programs, where the locale is apparently not
UTF-8 (which I never knew about until just now) and not been aware of
any of these issues.
So I guess I'm kind of curious how it is I have gone through c++ life
for 10 years, calling third party libraries, making system calls, and
reading/writing files without being aware of what my encoding is. It
was sort of "shoved in my face" when I use wx28 that I need to be
aware of my encoding... and comically apparently the answer is "don't
care" due to my use of ASCII-based std::string.
Anyhow, thank you very much for helping me. And especially thank you
for your work on wx29 where this mysterious string handling once again
goes below my radar!
Chris